May 22nd, 2002

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Wed May 22 08:18:34 UTC 2002

Modified Files:
---------------
livejournal/bin/upgrading: base-data.sql update-db-general.pl
livejournal/cgi-bin: ljlib.pl
livejournal/cgi-bin/Apache: LiveJournal.pm
livejournal/htdocs: interests.bml modify_do.bml

Log Message:
------------
* domain aliasing (users can point their domains at us and we'll
show their journals (cap: 'userdomain'))

* remove one use of $LJ::DOMAIN_RE in interests.bml ... ugly.
want web-based config of LJ server in future... don't want
admins to need to know regexps.

* fix canonical domain redirection lj.com to www.lj.com for GETs
changed some $LJ:: config options in process. need to document
all these.


To generate a diff of this commit:
cvs rdiff -r1.15 -r1.16 livejournal/bin/upgrading/base-data.sql
http://cvs.livejournal.org/browse.cgi/livejournal/bin/upgrading/base-data.sql.diff?r1=1.15&r2=1.16
cvs rdiff -r1.67 -r1.68 livejournal/bin/upgrading/update-db-general.pl
http://cvs.livejournal.org/browse.cgi/livejournal/bin/upgrading/update-db-general.pl.diff?r1=1.67&r2=1.68
cvs rdiff -r1.192 -r1.193 livejournal/cgi-bin/ljlib.pl
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/ljlib.pl.diff?r1=1.192&r2=1.193
cvs rdiff -r1.16 -r1.17 livejournal/cgi-bin/Apache/LiveJournal.pm
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/Apache/LiveJournal.pm.diff?r1=1.16&r2=1.17
cvs rdiff -r1.21 -r1.22 livejournal/htdocs/interests.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/interests.bml.diff?r1=1.21&r2=1.22
cvs rdiff -r1.18 -r1.19 livejournal/htdocs/modify_do.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/modify_do.bml.diff?r1=1.18&r2=1.19

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Wed May 22 09:25:33 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin/Apache: LiveJournal.pm

Log Message:
------------
ack! allow http/1.0 still without Host: request header.


To generate a diff of this commit:
cvs rdiff -r1.17 -r1.18 livejournal/cgi-bin/Apache/LiveJournal.pm
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/Apache/LiveJournal.pm.diff?r1=1.17&r2=1.18

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Wed May 22 18:37:19 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin/Apache: LiveJournal.pm

Log Message:
------------
require dots in custom vhost (so "Host: stan" from netsaint works)

require non-IP addresses (so "Host: 66.150.15.150" still goes to LJ,
and "Host: 10.0.0.4" still works from netsaint, etc)


To generate a diff of this commit:
cvs rdiff -r1.18 -r1.19 livejournal/cgi-bin/Apache/LiveJournal.pm
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/Apache/LiveJournal.pm.diff?r1=1.18&r2=1.19

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Wed May 22 22:35:32 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin: ljprotocol.pl

Log Message:
------------
this is what i meant to do the other day.

amazing how a little fuck-up can cause so many people to get in an uproar.
chill, yos. it be fixed.


To generate a diff of this commit:
cvs rdiff -r1.99 -r1.100 livejournal/cgi-bin/ljprotocol.pl
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/ljprotocol.pl.diff?r1=1.99&r2=1.100

ljcom

Module Name: ljcom
Committed By: bradfitz
Date: Wed May 22 23:54:41 UTC 2002

Modified Files:
---------------
ljcom/bin/upgrading: en_LJ.dat
ljcom/htdocs/paidaccounts: index.bml

Log Message:
------------
This patch removes more hardcoded English strings.
All strings go into language 'en', except for strings in
/paidaccounts/, which go into 'en_LJ'.
Tested.

tydel: /friends/add.bml
opiummmm: /paidaccounts/index.bml
anton: all 5 files in /community/ (index.bml,create.bml,
join.bml,leave.bml,search.bml) .
avva: reviewed, fixed a few bugs, unified some names.


To generate a diff of this commit:
cvs rdiff -r1.17 -r1.18 ljcom/bin/upgrading/en_LJ.dat
http://cvs.livejournal.org/browse.cgi/ljcom/bin/upgrading/en_LJ.dat.diff?r1=1.17&r2=1.18
cvs rdiff -r1.8 -r1.9 ljcom/htdocs/paidaccounts/index.bml
http://cvs.livejournal.org/browse.cgi/ljcom/htdocs/paidaccounts/index.bml.diff?r1=1.8&r2=1.9

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Wed May 22 23:54:57 UTC 2002

Modified Files:
---------------
livejournal/bin/upgrading: en.dat
livejournal/htdocs/community: create.bml index.bml join.bml leave.bml
search.bml
livejournal/htdocs/friends: add.bml

Log Message:
------------
This patch removes more hardcoded English strings.
All strings go into language 'en', except for strings in
/paidaccounts/, which go into 'en_LJ'.
Tested.

tydel: /friends/add.bml
opiummmm: /paidaccounts/index.bml
anton: all 5 files in /community/ (index.bml,create.bml,
join.bml,leave.bml,search.bml) .
avva: reviewed, fixed a few bugs, unified some names.


To generate a diff of this commit:
cvs rdiff -r1.12 -r1.13 livejournal/bin/upgrading/en.dat
http://cvs.livejournal.org/browse.cgi/livejournal/bin/upgrading/en.dat.diff?r1=1.12&r2=1.13
cvs rdiff -r1.8 -r1.9 livejournal/htdocs/community/create.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/community/create.bml.diff?r1=1.8&r2=1.9
cvs rdiff -r1.2 -r1.3 livejournal/htdocs/community/index.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/community/index.bml.diff?r1=1.2&r2=1.3
cvs rdiff -r1.13 -r1.14 livejournal/htdocs/community/join.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/community/join.bml.diff?r1=1.13&r2=1.14
cvs rdiff -r1.5 -r1.6 livejournal/htdocs/community/leave.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/community/leave.bml.diff?r1=1.5&r2=1.6
cvs rdiff -r1.4 -r1.5 livejournal/htdocs/community/search.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/community/search.bml.diff?r1=1.4&r2=1.5
cvs rdiff -r1.13 -r1.14 livejournal/htdocs/friends/add.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/friends/add.bml.diff?r1=1.13&r2=1.14

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Thu May 23 00:07:48 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin: ljprotocol.pl
livejournal/htdocs: userinfo.bml

Log Message:
------------
avva: Hey,

Here's the patch. If you see no problems with it and commit it, I'll
send a protocol doc patch pronto, too.
I include the _status info both with friends and friendsof, except
with friendsof it'll never get included now, given your last commit.
But in case we ever change it back, let the protocol be consistent.

What it does:
- add 'status' attribute for friends and friendsof, which gets output
only if u.statuvis is not 'V';
- add the same in the flat wrapper;
- change code in userinfo.bml to strikethrough such friends.

Tested.

bradfitz: speed tweaks. :P


To generate a diff of this commit:
cvs rdiff -r1.100 -r1.101 livejournal/cgi-bin/ljprotocol.pl
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/ljprotocol.pl.diff?r1=1.100&r2=1.101
cvs rdiff -r1.46 -r1.47 livejournal/htdocs/userinfo.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/userinfo.bml.diff?r1=1.46&r2=1.47

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Thu May 23 00:24:23 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin: lj-bml-init.pl
livejournal/cgi-bin/Apache: BML.pm

Log Message:
------------
avva: The current BML::decide_language() logic is wrong. The problem is that
BML::Lang is isocode=>lancode, which is good for Accept-Language
guesstimates, but bad for 'uselang' and the 'langpref' cookie. Those
two contain the actual langcode, not the castrated isocode, but
they're compared against isocode in decide_language().

So for example you cannot use ?uselang=en_GB anywhere, it won't do
anything. Or if you set en_GB on /setlang.bml, it doesn't actually
work. The problem now is only with en_GB, but it'll grow.

My solution is to register isocodes and languages separately, and use
separates hashes to hold them. isocodes are only ever used for
Accept-Language crap. All other methods of specifying languages use
our langcodes directly.

Maybe you'll think of a better way of doing this, I'm not sure.

Separating isocodes from langcodes also allows me to implement the
'debug' language trick, so this also goes into this patch.
?uselang=debug now will work everywhere.

Everything was tested.


To generate a diff of this commit:
cvs rdiff -r1.26 -r1.27 livejournal/cgi-bin/lj-bml-init.pl
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/lj-bml-init.pl.diff?r1=1.26&r2=1.27
cvs rdiff -r1.25 -r1.26 livejournal/cgi-bin/Apache/BML.pm
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/Apache/BML.pm.diff?r1=1.25&r2=1.26

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Thu May 23 02:01:31 UTC 2002

Modified Files:
---------------
livejournal/doc/raw/entities: lj.book.ent
livejournal/doc/raw/lj.book/install: ljconfig.xml
Added Files:
------------
livejournal/doc/raw/lj.book/install: ljconfig.vars.xml

Log Message:
------------
jproulx: start of $LJ:: var docs


To generate a diff of this commit:
cvs rdiff -r1.1 -r1.2 livejournal/doc/raw/entities/lj.book.ent
http://cvs.livejournal.org/browse.cgi/livejournal/doc/raw/entities/lj.book.ent.diff?r1=1.1&r2=1.2
cvs rdiff -r0 -r1.1 livejournal/doc/raw/lj.book/install/ljconfig.vars.xml
http://cvs.livejournal.org/browse.cgi/livejournal/doc/raw/lj.book/install/ljconfig.vars.xml.diff?r1=0&r2=1.1
cvs rdiff -r1.1 -r1.2 livejournal/doc/raw/lj.book/install/ljconfig.xml
http://cvs.livejournal.org/browse.cgi/livejournal/doc/raw/lj.book/install/ljconfig.xml.diff?r1=1.1&r2=1.2

livejournal

Module Name: livejournal
Committed By: bradfitz
Date: Thu May 23 06:56:13 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin/Apache: BML.pm

Log Message:
------------
whenever BML::set_language is called (either once or twice per
request), install specialized subroutines for BML::ml and
BML::ML::FETCH that have less conditionals.


To generate a diff of this commit:
cvs rdiff -r1.26 -r1.27 livejournal/cgi-bin/Apache/BML.pm
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/Apache/BML.pm.diff?r1=1.26&r2=1.27