aboutsummaryrefslogtreecommitdiffstats
path: root/include/datetime.php
Commit message (Collapse)AuthorAgeFilesLines
* cleanup event form and various required indicators on inputsfriendica2015-01-291-1/+2
|
* Use grouped select field for timezone selectionStefan Parviainen2015-01-011-38/+9
|
* Switch to a better datetime picker widgetStefan Parviainen2014-11-161-17/+28
|
* Merge remote-tracking branch 'upstream/master'Habeas Codice2014-11-131-3/+10
|\ | | | | | | | | | | | | | | | | | | | | | | Conflicts: boot.php include/dba/dba_driver.php include/diaspora.php include/follow.php include/session.php include/zot.php mod/photos.php mod/ping.php
| * the code is a bit crufty, but this should fix issue #687friendica2014-11-111-3/+10
| |
* | PostgreSQL support initial commitHabeas Codice2014-11-131-2/+5
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were 11 main types of changes: - UPDATE's and DELETE's sometimes had LIMIT 1 at the end of them. This is not only non-compliant but it would certainly not do what whoever wrote it thought it would. It is likely this mistake was just copied from Friendica. All of these instances, the LIMIT 1 was simply removed. - Bitwise operations (and even some non-zero int checks) erroneously rely on MySQL implicit integer-boolean conversion in the WHERE clauses. This is non-compliant (and bad programming practice to boot). Proper explicit boolean conversions were added. New queries should use proper conventions. - MySQL has a different operator for bitwise XOR than postgres. Rather than add yet another dba_ func, I converted them to "& ~" ("AND NOT") when turning off, and "|" ("OR") when turning on. There were no true toggles (XOR). New queries should refrain from using XOR when not necessary. - There are several fields which the schema has marked as NOT NULL, but the inserts don't specify them. The reason this works is because mysql totally ignores the constraint and adds an empty text default automatically. Again, non-compliant, obviously. In these cases a default of empty text was added. - Several statements rely on a non-standard MySQL feature (http://dev.mysql.com/doc/refman/5.5/en/group-by-handling.html). These queries can all be rewritten to be standards compliant. Interestingly enough, the newly rewritten standards compliant queries run a zillion times faster, even on MySQL. - A couple of function/operator name translations were needed (RAND/RANDOM, GROUP_CONCAT/STRING_AGG, UTC_NOW, REGEXP/~, ^/#) -- assist functions added in the dba_ - INTERVALs: postgres requires quotes around the value, mysql requires that there are not quotes around the value -- assist functions added in the dba_ - NULL_DATE's -- Postgres does not allow the invalid date '0000-00-00 00:00:00' (there is no such thing as year 0 or month 0 or day 0). We use '0001-01-01 00:00:00' for postgres. Conversions are handled in Zot/item packets automagically by quoting all dates with dbescdate(). - char(##) specifications in the schema creates fields with blank spaces that aren't trimmed in the code. MySQL apparently treats char(##) as varchar(##), again, non-compliant. Since postgres works better with text fields anyway, this ball of bugs was simply side-stepped by using 'text' datatype for all text fields in the postgres schema. varchar was used in a couple of places where it actually seemed appropriate (size constraint), but without rigorously vetting that all of the PHP code actually validates data, new bugs might come out from under the rug. - postgres doesn't store nul bytes and a few other non-printables in text fields, even when quoted. bytea fields were used when storing binary data (photo.data, attach.data). A new dbescbin() function was added to handle this transparently. - postgres does not support LIMIT #,# syntax. All databases support LIMIT # OFFSET # syntax. Statements were updated to be standard. These changes require corresponding changes in the coding standards. Please review those before adding any code going forward. Still on my TODO list: - remove quotes from non-reserved identifiers and make reserved identifiers use dba func for quoting - Rewrite search queries for better results (both MySQL and Postgres)
* Fix problem with default birth dateStefan Parviainen2014-10-311-1/+4
|
* Don't display date format, it's already in the placeholder textStefan Parviainen2014-10-191-30/+0
|
* Changes in the datetimesel api, prevent user from picking event end date ↵Stefan Parviainen2014-10-191-70/+51
| | | | earlier than start date
* Oops, forgot one fileStefan Parviainen2014-10-181-73/+85
|
* This is long overdue - use a symblic constant NULL_DATE instead of the ↵friendica2014-09-081-1/+1
| | | | easily mis-typed sequence '0000-00-00 00:00:00'
* don't add a birthday event if the birthday channel doesn't have permission ↵friendica2014-06-031-0/+5
| | | | to send you posts.
* bring back birthdaysfriendica2014-06-021-1/+49
|
* reorganise a few included functions - notably identity related functionsfriendica2013-12-031-0/+21
|
* start formatting for Doxygenfriendica2013-02-251-22/+20
|
* progress however tediousMike Macgirvin2012-10-231-55/+0
|
* more work on json notifications, now working except for notify popupfriendica2012-07-151-1/+1
|
* gracefully recover from datetime constructor issuesfriendica2012-07-111-2/+23
|
* typosfriendica2012-06-251-1/+1
|
* add event titles to discovered birthday eventsfriendica2012-06-251-3/+6
|
* add missing bracketErkan Yilmaz2012-06-131-1/+1
|
* survive bad/un-parseable input to datetime_convertfriendica2012-06-121-1/+1
|
* "howlong" added to marital status.friendica2012-06-021-2/+4
|
* more sane defaults datetime_convertfriendica2012-04-081-3/+6
|
* fix empty string timezonefriendica2012-04-081-0/+7
|
* Merge branch 'master' of https://github.com/friendica/friendicaAlexander Kampmann2012-04-051-0/+0
| | | | | | Conflicts: include/config.php update.php
* make 'x minutes ago' fully translateable with argument ordering. string update.friendica2012-02-121-4/+5
|
* add remove_user hook (it looks like dreamhost changed all my file ↵friendica2012-01-181-0/+0
| | | | permissions, this will make a nasty commit)
* datetime: new field_timezone() function, new template field_select_raw.tplFabio Comuni2012-01-021-2/+18
| | | | | returns a timezone select like select_timezone() but using template field_select_raw.tpl. field_select_raw get options html as forth argument, instead of array value=>label like field_select
* diaspora birthday notificationsFriendika2011-10-141-0/+54
|
* configurable format for date input selectorsFriendika2011-07-251-31/+78
|
* re-added last item date in admin user page. relative_date return 'never' if ↵Fabio Comuni2011-06-291-1/+1
| | | | null is passed
* very minor nit - if $abs is false, return before trying to use false in a ↵Friendika2011-06-291-10/+11
| | | | | | numeric calculation also return 'never' if we have an uninitialised date
* Fix bug #98, add "never" to relative_date(), fix batch operationsFabio Comuni2011-06-291-0/+4
|
* tinymce for event fieldsFriendika2011-06-061-2/+2
|
* event listingsFriendika2011-06-061-2/+2
|
* more events frameworkFriendika2011-06-061-3/+37
|
* push directory on register - if permittedFriendika2011-02-231-1/+1
|
* add some calendaring functionsFriendika2011-02-221-0/+111
|
* i18n string extraction utilMike Macgirvin2010-09-291-4/+4
|
* clarify birthday doco, Facebook really screwed this one up.Mike Macgirvin2010-09-271-4/+5
|
* docoMike Macgirvin2010-09-271-0/+34
|
* mistpark 2.0 infrasturcture landsMike Macgirvin2010-09-081-3/+14
|
* installer changes, pe syncMike Macgirvin2010-08-151-48/+28
|
* fix birthdayMike Macgirvin2010-07-111-1/+1
|
* profile additionsMike Macgirvin2010-07-101-10/+17
|
* more directory workMike Macgirvin2010-07-091-1/+21
|
* Initial checkinMike Macgirvin2010-07-011-0/+145