summaryrefslogtreecommitdiff
path: root/lib/util.php
AgeCommit message (Collapse)Author
2010-01-04Ticket 2141: bugs with weighted popularity lists across year boundary.Brion Vibber
Consolidated several separate implementations of the same weighting algorithm into common_sql_weight() and fixed some bugs... For MySQL, now using timestampdiff() instead of subtraction for the comparison, so we get sane results when the year doesn't match, and utc_timestamp() rather than now() so we don't get negative ages for recent items with local server timezone. Unknown whether the same problems affect PostgreSQL, but note that it lacks the timestampdiff() SQL function.
2010-01-02Make caching a plugin systemEvan Prodromou
2010-01-02fixup memcache functionsEvan Prodromou
2009-12-30Enable memcache automatic compression, starting at 20k and only if ↵Craig Andrews
compression gain is greater than 20%. Allows storage of larger objects (over 1mb in size uncompressed), such as huge LDAP schemas. Should also improve cache efficiency (allows more stuff to be stored in same memory) and reduce network latency (less data transfer)
2009-12-19Ignore user language settings that aren't listed in language config; we'll ↵Brion Vibber
then fall back to current autodetection. This prevents the surprises where your profile suddenly switches to Arabic because it was selected by default due to lack of a match in the drop-down box.
2009-12-16Add some doc comments and fixmes in util.phpBrion Vibber
2009-12-16PHP 5.3 closure-based implementation of curry(); old implementation used as ↵Brion Vibber
fallback for older PHP versions. Added unit tests to confirm they both work!
2009-12-05Add 2 new events to enable logger pluginization: StartLog and EndLogCraig Andrews
2009-12-03Code style cleanup: dropped some unnecessary =& reference assignments where ↵Brion Vibber
they're used only out of habit for PHP 4-style object semantics
2009-11-27Drop the username from the log id for now; seems to trigger an error loop in ↵Brion Vibber
some circumstances
2009-11-27request id on logs... pid + random id per web request + username + method + urlBrion Vibber
2009-11-25Drop error message on setlocale() failure; this is harmless, since we ↵Brion Vibber
actually have a working locale set up.
2009-11-18Added Authorization pluginCraig Andrews
Added LDAPAuthorization plugin
2009-11-12blasted, that should not be thereCraig Andrews
2009-11-12Added a User_username table that links the external username with a ↵Craig Andrews
StatusNet user_id Added EmailAuthenticationPlugin Added ReverseUsernameAuthenticationPlugin Changed the StartChangePassword and EndChangePassword events to take a user, instead of a nickname User::allowed_nickname was declared non-static, but used as if it was static, so I made the declaration static
2009-11-11Redid how URL shorteners work. This way is much more like how Evan wants ↵Craig Andrews
events to work (and more like how the rest of SN works).
2009-11-11Fix bug 1963: Web UI throws warnings during previously open login session ↵Brion Vibber
after user account is deleted common_logged_in() returned bogus results because it checks against null specifically, but common_current_user() was sticking 'false' into $_cur because that's what User::staticGet() returned from a failed lookup. Now we skip over a failed lookup here, so we keep null and all is well.
2009-11-10change credential check to work more like other eventsEvan Prodromou
2009-11-10Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.xEvan Prodromou
Conflicts: lib/util.php
2009-11-10fixup output of object attributes in db error codeEvan Prodromou
2009-11-09Revert "Remove more contractions"Brion Vibber
This reverts commit 5ab709b73977131813884558bf56d97172a7aa26. Missed this one yesterday...
2009-11-08Merge branch '0.9.x' of git://gitorious.org/statusnet/mainline into 0.9.xSiebrand Mazeland
2009-11-08Remove more contractionsSiebrand Mazeland
* doesn't * won't * isn't * don't
2009-11-08Revert "* [Cc]an't -> [Cc]annot"Brion Vibber
This reverts commit 0ab17f382b9993ada3d12d4cdace72cca53fb545.
2009-11-08* [Cc]an't -> [Cc]annotSiebrand Mazeland
* [Cc]ould't -> [Cc]ould not
2009-11-05Added an AutoRegister eventCraig Andrews
LDAP plugin can do autoregistration
2009-11-04Added a CheckPassword eventCraig Andrews
2009-11-02Merge commit 'refs/merge-requests/1900' of ↵Brion Vibber
git://gitorious.org/statusnet/mainline into integration
2009-11-02allow <> to surround the url (like () or [])Craig Andrews
2009-11-02do not allow " in URLs - they are not legal URL charactersCraig Andrews
2009-11-02do not allow [ and ] - they are not legal URL charactersCraig Andrews
2009-10-31merge from testingEvan Prodromou
2009-10-23Better license check.Stephen Paul Weber
Tokenise CC license parts and check for compatability. Fallback is old directly-equal test.
2009-10-23Remove automatic enqueuing for FacebookZach Copley
2009-10-23Fix three fatal errors when posting from 0.9.x:Brion Vibber
* OMB remote updates were trying to load nonexistent Laconica_OMB_Service_Consumer class -- fixed to StatusNet_OMB_Service_Consumer. Regression caused during libomb merge. * Twitter processing was still being queued from core when no twitter plugin was present, which triggered an exception from UnqueueHandler; leftover code from before the plugin extraction. * UnqueueHandler's exception caused a fatal error instead because it was missing the "new" keyword. Wouldn't have been seen when testing with the plugin enabled.
2009-10-19Better check if site,server is configured.Eric Helgeson
2009-10-19merge from testingEvan Prodromou
2009-10-19Utilize NICKNAME_FMT constant when creating at replies0.8.2rc1Eric Helgeson
2009-10-19Merge branch 'i18n-work' into i18n-0.9.xBrion Vibber
2009-10-16Drop a debug info line that isn't really neededBrion Vibber
2009-10-16Workaround for not fully natively set up locales with native gettext...Brion Vibber
Set "en_US" locale first, then the locale we want for our user. This seems to initialize gettext properly somehow, which I could see when the languages would come up briefly on settings save when changing from a supported language. Definitely works for ga_ES on my Ubuntu system (8.10 intrepid), hopefully reasonably consistent.
2009-10-11Merge remote branch 'statusnet/0.8.x' into 0.9.xCraig Andrews
Conflicts: lib/common.php
2009-10-07Fixed E_NOTICE when returnto isn't setJeffery To
2009-10-01Revert "Outputting UTF-8 charset in document header irrespective of mimetype."Sarven Capadisli
This reverts commit 353f58c23149159306131b0819de713da6b69464. Even though outputting UTF-8 by default at all times is a good thing, it shouldn't be forced in startHTML().
2009-09-30Merge branch '0.8.x' into 0.9.xSarven Capadisli
2009-09-30Outputting UTF-8 charset in document header irrespective of mimetype.Sarven Capadisli
2009-09-27Fix some bugs in the URL linkification, and fixed the unit test.Craig Andrews
2009-09-23Merge branch '0.8.x' into 0.9.xEvan Prodromou
Conflicts: actions/requesttoken.php classes/File.php install.php lib/noticeform.php
2009-09-23Revert "When viewing a page in https, all links to non-actions (links to ↵Evan Prodromou
CSS, JS, etc) should be https. Fixes the mixed content warnings that browsers display." This reverts commit 20997619b353faa94591800fbfc02bc19a4cdce3. The commit doesn't take into account having different servers (theme server, avatar server) and being able to set HTTPS for some but not all.
2009-09-22Allow some punctuation instead of just spaces before @user, !group, and #tagCraig Andrews