16 Commits

Author SHA1 Message Date
dgw
469763cd25
Ensure all statusCode/errorCode API values are strings (#3756)
PHPDoc comments about the API response format say that both `statusCode`
and `errorCode` are expected to be strings, but a lot of cases were
returning ints instead. This could cause problems for JSON clients.
2024-05-08 13:42:39 +02:00
྅༻ Ǭɀħ ༄༆ཉ
6da30dfab0
Add missing inline documentation (#3325) 2022-05-05 21:36:13 +02:00
྅༻ Ǭɀħ ༄༆ཉ
b347c36b33
Fix that fucking encoding problem (#2690)
This commit's changelog

- less encode/decode
- update jQuery & remove old ones
- No encoding in JS
- Also, 4 spaces in JS too, duh
- IDN domain functions
- Use mb_ functions to preverse IDN domains
- Support for UTF8MB4
- update install procedure
- update upgrade procedure. Note: The log table will be left untouched by the upgrade, it's impossible to make a convenient upgrade script for thousands of rows. The only problem will be if someone uses UTF8 short URLs (eg `http://sho.rt/éé💩`)
- Handle normalization of IDN domains & tests
- Fix warning on 7.2 and 7.3
- Deal with encoding in bookmarklets
- Enclose upgrade queries in a transaction
- Force no caching upon install or upgrade. Note: Strange behavior: if YOURLS hosted on an IDN domain, browser (FF at least) caches the redirection from admin/index.php to admin/install.php
- Support for IDN YOURLS hosting
- Tests for IDN YOURLS hosting
- Fix code (that will never get run again)
- Don't cache ajax requests
- Remove unnecessary function call
- Add comment doc block
- More IDN sanitizing tests
- IDN : Screw the "open dots". Who's going to type domain。com instead of domain.com anyway? Seriously. (although these do pass on my dev box)
- Deprecate yourls_lowercase_scheme_domain()
- Update doc to reflect DB change
2020-10-10 16:09:36 +02:00
྅༻ Ǭɀħ ༄༆ཉ
c1517f1f84
Smarter keyword sanitization (#2682)
* Smarter keyword sanitizing, based on context
* Deprecate yourls_sanitize_string()

Fixes #2646.
Fixes #2128.
2020-05-09 13:10:27 +02:00
྅༻ Ǭɀħ ༄༆ཉ
fd4b927808
Split functions.php in smaller files
New function files for:
* debug
* options
* links
* geo
* shorturls
Fixes #2654

* Regroup and always load auth functions
Fixes #2662
Fixes #2661 

Co-authored-by: paulgoodchild <paulgoodchild@users.noreply.github.com>
2020-05-01 12:05:15 +02:00
྅༻ Ǭɀħ ༄༆ཉ
602e7dfe6f
Always return trimmed (and filtered) YOURLS_SITE (#2653)
Closes #2651
2020-04-19 12:38:27 +02:00
ozh
db3c69b76f Update ydb->query() functions
[skip ci]
2017-09-02 19:09:56 +02:00
ozh
6dc180c198 Refactor function to be testable 2015-05-27 17:38:58 +02:00
ozh
ff14d7e152 Add title to API action "expand". Closes #1759
Thanks @digitaltoast, neat idea.
2014-10-25 20:34:25 +02:00
ozh
7dfbe54c4e Filterable charset in content-type headers.
Fixes #1533
2014-01-01 12:46:21 +01:00
LeoColomb
097170801d Tabify 2013-04-11 20:54:47 +02:00
LeoColomb
3daf6593d8 Fix end of line 2013-04-07 12:52:52 +02:00
Ozh
7fdd260912 PHPdoc-ish-ification of older functions. Fixes issue 1244.
git-svn-id: http://yourls.googlecode.com/svn/trunk@879 12232710-3e20-11de-b438-597f59cd7555
2013-02-13 09:45:33 +00:00
Ozh
870f90ff00 No translation readyness for API functions, but that's OK
git-svn-id: http://yourls.googlecode.com/svn/trunk@866 12232710-3e20-11de-b438-597f59cd7555
2013-02-10 13:19:09 +00:00
Ozh
369cdfefeb Status header in API results
git-svn-id: http://yourls.googlecode.com/svn/trunk@840 12232710-3e20-11de-b438-597f59cd7555
2013-01-31 21:27:59 +00:00
Ozh
df55e5b4f1 Smarter API (de/register methods) and a 'version' method. See Issue 1259.
git-svn-id: http://yourls.googlecode.com/svn/trunk@824 12232710-3e20-11de-b438-597f59cd7555
2012-12-14 14:20:32 +00:00