Commit graph

827 commits

Author SHA1 Message Date
Shish
07304861f3 log IDs of things 2013-08-30 00:19:46 +01:00
Shish
7c140680b7 log args 2013-08-30 00:19:46 +01:00
Shish
12bc4a90f7 core-image -> core_image, for elasticsearch's sake 2013-08-30 00:19:46 +01:00
Shish
44deff21a8 Merge branch 'master' of https://github.com/shish/shimmie2 2013-08-05 20:37:40 +01:00
Shish
4fc1f2f217 save cached config when saving database config, fixes #311 2013-08-05 20:21:57 +01:00
Shish
e50d9c4dbb only sanitise when saving tags - when searching, '*' is important 2013-08-04 18:21:52 +01:00
Shish
8b22652aa0 resolve negative aliases 2013-08-04 18:19:23 +01:00
Shish
2b628a395f resolve_list -> resolve_aliases, to better describe what it actually does 2013-08-04 18:13:50 +01:00
Shish
7e89481105 have Tag::resolve_list always take an array 2013-08-04 18:11:02 +01:00
Shish
00e297c7d4 Merge pull request #317 from HungryFeline/patch-1
Let the admin define how much space should be free
2013-07-07 03:28:44 -07:00
Shish
39753fe7a9 Finish the process of removing $query from thumb links. (Forgot to remove $query from the thumb links) 2013-07-07 10:34:19 +01:00
HungryFeline
9edbaf2ec7 Let the user define how much space should be free 2013-07-07 09:08:50 +02:00
Shish
47c1b5d094 move query-string-passing to JS rather than embedding in the HTML, so that the HTML can be commonised and cached better 2013-07-05 22:32:16 +01:00
Shish
30886b3a69 cache lookup debugging 2013-07-05 22:32:16 +01:00
HungryFeline
65fcbcb9ba Actually set the cookie prefix
When COOKIE_PREFIX was not shm (the default) the script tried to read cookies prefixed with the new prefix but the script was setting the old default prefix from before the constants were implemented.
2013-07-02 06:46:54 +02:00
HungryFeline
616aa3300a Don't check the certificate when transloading
This allows the download of images via https even if the cert is self-signed.
2013-07-02 04:44:27 +02:00
Shish
df2f90016f trim leading slashes more efficiently 2013-06-13 12:20:27 +01:00
Shish
19c0868b2c sqlite got case sensitive by default at some point - lowercase strings for comparing them 2013-06-13 10:34:47 +01:00
jgen
cc95eb5deb Some more small speed tweaks. 2013-05-13 20:40:01 -04:00
Shish
7701758959 log old source in event log when changing source 2013-05-07 09:13:03 +01:00
Shish
7ff0ae51a1 fixup wildcards 2013-03-03 18:34:27 +00:00
Shish
72a82c7487 saner wildcard handling, and only handle '*' 2013-03-03 18:26:47 +00:00
Shish
dbfd747dd3 remove more slashes 2013-02-06 08:36:30 +00:00
Shish
c9491ad714 Get SQLite:scoreql_to_sql to return something 2013-01-31 08:07:19 +00:00
Shish
78442e96c3 add daily cache breakage to gravatars 2012-12-30 18:08:58 +00:00
Shish
cebebcd975 Merge branch 'master' of https://github.com/shish/shimmie2 2012-12-10 21:28:44 +00:00
Shish
5a3b4dae49 normalise usernames 2012-12-10 21:28:41 +00:00
green-ponies
ef44d6ccf3 Fix for issue 263 - ReCAPTCHA private and public keys reversed. 2012-11-03 13:49:10 -04:00
Shish
d8c670eaa6 move yet more stuff out of index.php 2012-10-16 23:05:11 +01:00
Shish
b141632785 some mock objects, for testing (coming soon, maybe) 2012-10-16 22:58:47 +01:00
Shish
38fea60056 handle CLI_LOG_LEVEL not being set 2012-10-16 22:58:24 +01:00
Shish
073b21aaa1 split up event listener loading, so parts can be called individually 2012-10-16 22:31:50 +01:00
velocity37
52718b0590 util.inc: Default to static extension lookup
Magic can return invalid results for video files, breaking their playback. Default to the static extension lookup to avoid this problem but still return application/octet-stream if nothing works.
2012-10-16 18:56:39 +01:00
velocity37
0663bf54a0 Grr... 2012-10-16 18:55:43 +01:00
velocity37
1bd6f9f0ba Update core/util.inc.php 2012-10-16 18:55:38 +01:00
velocity37
fcdf784acc Update static thumb + bug fix
Add videos to static thumb and make Shimmie compare lowercase extensions.
2012-10-16 18:55:23 +01:00
velocity37
412dcd05af Add video MIME types 2012-10-16 18:55:00 +01:00
Shish
e3d385aee5 Merge branch 'master' of github.com:shish/shimmie2 2012-09-24 22:36:28 +01:00
Shish
ac812b4a2a danbooru api updates 2012-09-24 22:36:09 +01:00
Shish
65ce0ff4e4 check filename extension by lowercased version of itself 2012-09-22 23:24:19 +01:00
Shish
06426bdfe6 when checking mime types, use the filename.ext from the DB, not the (non-existent) .ext on disk 2012-09-22 23:15:25 +01:00
Shish
c57801bce7 wildcards aren't regular tags either 2012-09-03 11:13:08 +01:00
Shish
7dd929e5a8 remove a whole load of event->user variables that weren't used -- things should be using global user 2012-08-18 19:45:39 +01:00
Shish
6fcdf4717e Merge branch 'js-classes' 2012-08-15 21:26:56 +01:00
Shish
6394cd8100 make shm-thumb use consistent across themes, with data-tags and data-post-id 2012-08-15 20:42:56 +01:00
Shish
61e9909327 hardcoded config too (unrelated) 2012-08-15 18:31:28 +01:00
Shish
112422a2ca time and timestamp are incompatible 2012-07-28 12:07:46 +01:00
Shish
acf285bd68 IPs are variable length 2012-07-28 11:57:22 +01:00
Shish
53ad7d4a2f more sqlite, and indexes 2012-06-27 00:08:51 +01:00
Shish
02a286cba0 sqlite updates 2012-06-26 23:46:38 +01:00
Shish
f9008a70a6 refactoring fail 2012-06-24 07:13:53 +01:00
Shish
8dfeb7cda3 longer cache timings, with better invalidation 2012-06-24 01:57:12 +01:00
Shish
6c4fd0d14d remove ancient non-comment 2012-06-24 01:49:53 +01:00
Shish
38f7555d98 get rid of direct references to Database's engine 2012-06-24 00:57:55 +01:00
Shish
d313cea8a7 create the DB connection on demand; some pages don't require one at all thanks to caching 2012-06-24 00:50:13 +01:00
Shish
bcfcca7cda checking the engine can trigger a database init... 2012-06-24 00:25:47 +01:00
Shish
008cc4253b wibble database / cache connection functions, make them repeatable, and set persistant DB connections as an option 2012-06-23 23:57:34 +01:00
Shish
63437d1e09 cache user sessions 2012-06-23 23:38:28 +01:00
Shish
1c5bf478d9 initialise global _execs, else we get 'page used queries' when we want 'page used 0 queries' 2012-06-23 23:37:41 +01:00
Shish
d3e2653002 some cached values are often zero (eg unread PMs), 'zero' is still a cache hit though, only 'false' is miss 2012-06-23 23:17:17 +01:00
Shish
6181d59975 that slash needs to be there >_< 2012-06-22 20:02:53 +01:00
Shish
e7df4edbee slashes are removed already 2012-06-21 09:07:52 +01:00
Shish
2a18da523c the define wibbling for hiphop seems to work now 2012-06-18 01:23:31 +01:00
Shish
fd5b4c5910 more re-organisation for create_monolith / hiphop friendliness 2012-06-18 01:06:36 +01:00
Shish
553aad8a36 cache vars do nothing 2012-06-18 00:51:09 +01:00
Shish
78d701dd53 move stuff about to make create_monolith simpler 2012-06-18 00:45:32 +01:00
Shish
930de7fc8c remove built-in full-page caching; it doesn't do much any more, and everything it does do can be done better by Varnish 2012-06-18 00:07:12 +01:00
Shish
5519c3a320 lots of tidying and removal of duplicate code 2012-06-18 00:00:21 +01:00
Shish
082e6fa31b nice, event-based command line support; try 'php index.php' for info 2012-06-17 20:06:02 +01:00
Shish
239e028662 flash messages everywhere~ 2012-06-10 04:21:03 +01:00
Shish
61754b8dfe add a type arg, even if it's not used yet 2012-06-10 01:05:03 +01:00
Shish
37b3dd60b6 flash_message(str) function and support in themes 2012-06-09 17:00:25 +01:00
Shish
e89c14c72c Merge branch 'master' of github.com:shish/shimmie2 2012-06-05 13:09:31 +01:00
Shish
d167d25942 don't add navblock if there is already one 2012-05-28 10:03:17 +01:00
Shish
2e76add61b enhance zglob to allow really long patterns 2012-05-22 12:46:56 +01:00
Shish
545f5234bb less nesting, 25% speed gain 2012-05-16 07:36:20 +01:00
Shish
4cbd00c039 Merge branch 'master' of github.com:shish/shimmie2 2012-05-16 05:32:56 +01:00
Shish
fd725d3363 merge image ID lists before scanning the images table, not after 2012-05-16 05:12:19 +01:00
Shish
2347b1fab8 fff. 2012-05-14 11:12:50 +01:00
Shish
f7e25daeb5 move getMimeType to utils 2012-05-14 06:43:23 +01:00
green-ponies (jgen)
3902036477 Avoid breaking things. 2012-04-18 02:20:42 -04:00
green-ponies (jgen)
2fcc271f3d Small typo. 2012-04-18 01:17:44 -04:00
green-ponies (jgen)
1615f79be4 Examine integers separately. Also, don't break search. >_< 2012-04-18 00:56:11 -04:00
green-ponies (jgen)
caec1ac824 Support multiple databases as well. 2012-04-18 00:55:39 -04:00
green-ponies (jgen)
dd88127c30 Undoing this commit: Removing unnecessary call to int_escape(). Simply cast to int inline, saving function call overhead. 2012-04-18 00:54:18 -04:00
green-ponies (jgen)
f8832a5024 Merge branch 'filter_var' 2012-04-16 16:46:38 -04:00
green-ponies (jgen)
a79875c1eb The idn_to_ascii() function is only supported by PHP version 5.3 and up. 2012-04-16 16:42:32 -04:00
green-ponies (jgen)
0c37be79a0 Actually get the proper mime type for a given file.
(FIXME: now we handle more than just images)
2012-04-15 19:55:06 -04:00
green-ponies (jgen)
a0a0ba5bbc A better version of bool_escape() that uses filter_var if possible.
Also removed undb_bool() as it was basically a copy of the old bool_escape function.
2012-04-15 19:28:27 -04:00
green-ponies (jgen)
372f4fad7c Use filter_var for function url_escape($input). 2012-04-15 18:59:23 -04:00
green-ponies (jgen)
a82f9382d1 Removing unnecessary call to int_escape(). Simply cast to int inline, saving function call overhead. 2012-04-15 18:40:06 -04:00
Shish
678215e4bd width / height were never used individually, now just have images 2012-04-01 17:47:39 +01:00
Shish
7ad3ae55f9 inet = char(45) in mysql, to fit IPv6 addrs 2012-04-01 15:44:43 +01:00
Shish
eb05458c9f change user class / delete user separate from admin 2012-03-31 19:25:27 +01:00
Shish
67f1c1c51d store enabled exts in a config file, rather than moving directories around 2012-03-31 18:59:28 +01:00
Shish
15df989f72 nicer error reporting 2012-03-31 17:07:11 +01:00
Shish
55d8d16ee8 suggest a perm when dev typos 2012-03-31 17:06:53 +01:00
Shish
81c7ac0120 mass source set perm 2012-03-31 16:31:10 +01:00
Shish
1673e8e7ef et perm 2012-03-31 15:48:29 +01:00
Shish
4856af9c49 more perms 2012-03-31 12:33:55 +01:00
Shish
7ef52c853f more perms 2012-03-31 12:28:34 +01:00
Shish
f7f70b8600 more perms 2012-03-30 20:54:33 +01:00
Shish
62e13eda96 always create 2012-03-30 20:28:09 +01:00
Shish
7cbb62c8cc move data to data folder 2012-03-30 18:21:35 +01:00
Shish
29cebb44f9 event_listeners is a bit of cached data 2012-03-30 18:07:40 +01:00
Shish
fd094050fc move config file to data 2012-03-30 18:03:55 +01:00
Shish
e210fe739b more spaced out priorities 2012-03-30 16:41:25 +01:00
Shish
da786ee3c1 tags on thumb element 2012-03-22 13:18:15 +00:00
Shish
1085925504 css=style, js=script 2012-03-22 12:30:02 +00:00
Shish
88767b4c96 syntax 2012-03-22 12:15:03 +00:00
Shish
b156d4f380 no need for 'load files in a good way' to be optional, just do it 2012-03-21 15:04:17 +00:00
Shish
e71cf291a9 hide empty bits, not just null 2012-03-19 19:00:25 +00:00
Shish
a69d80d950 generic blocks, now with database storage 2012-03-19 18:40:37 +00:00
Shish
ea90e21d86 wiki perms 2012-03-19 13:21:59 +00:00
Shish
ee4b223f65 comment_anon bool -> create_comment perm 2012-03-19 13:17:47 +00:00
Shish
bca3dd919d upload_anon bool -> create_image perm 2012-03-19 12:59:02 +00:00
Shish
0300065b9d default anon can do nothing 2012-03-19 11:42:56 +00:00
Shish
45bff3ff31 inherit the class, not the name 2012-03-19 11:33:06 +00:00
Shish
50a6013569 nicer custom classes 2012-03-19 11:27:01 +00:00
Onivis Yhonay d'Izeworudi
f72b8babc0 Load style.css from theme when autocache is enabled 2012-03-18 16:59:13 +01:00
Shish
f518c608d9 lazy loading for thumbs 2012-03-15 19:26:16 +00:00
Shish
144c1afcbc ffffff, PHP, doing something weird rather than having a userful error message 2012-03-14 20:35:15 +00:00
Shish
6632521218 permission name tweaks 2012-03-14 19:24:10 +00:00
Shish
9a0228720a truncate as a function, which works 2012-03-13 07:01:27 +00:00
Shish
d54580e453 PLT is used by tooltips too... 2012-03-13 07:01:15 +00:00
Shish
dde5d4c9b5 html5 validation 2012-03-13 06:33:21 +00:00
Shish
efd05179f3 better log for owner change 2012-03-13 04:55:49 +00:00
Shish
a5ba9279c4 modification dates on CSS/JS links 2012-03-12 23:17:20 +00:00
Shish
02428a17f5 note of perms 2012-03-12 17:30:33 +00:00
Shish
0e262f5500 change_X -> edit_X for consistency 2012-03-12 17:29:03 +00:00
Shish
f15fa1c635 a newline so source is less cramped 2012-03-12 15:06:07 +00:00
Shish
3eb1f1c2ab move move common code into base classes 2012-03-12 05:08:40 +00:00
Shish
15777b3bb5 move common themelt parts into a base class 2012-03-12 05:04:29 +00:00
Shish
c638af1d76 consistent block rendering 2012-03-12 04:39:04 +00:00
Shish
652984adc1 trim comma from tags as well as whitespace 2012-03-11 14:54:14 +00:00
Shish
cf907237c6 with 5.2.1, we have an accurate, peak memory use 2012-03-11 04:33:24 +00:00
Shish
1b30aea557 compressed coverage logs 2012-03-11 00:36:57 +00:00
Shish
a6dbe3b7f2 Image::locked should always be a boolean 2012-03-10 18:53:42 +00:00
Shish
77b99adca7 remove more unused bits 2012-03-10 02:19:12 +00:00
Shish
b451f90b47 ip2color() was never used 2012-03-10 02:14:33 +00:00
Shish
bab3145fbc plural() was never used 2012-03-10 02:13:50 +00:00
Shish
f9910ba98f whitespace consistency 2012-03-09 22:27:12 +00:00
Shish
1f07a273f6 move copy & pasted transload code into a shared function 2012-03-09 21:07:21 +00:00
Shish
79ce40abd0 less code 2012-03-09 18:14:14 +00:00
Shish
569e93cd6b postgres requires a sequence name to be passed to get_last_insert_id 2012-03-08 02:55:04 +00:00
Shish
f928d178f4 Merge branch 'master' of github.com:shish/shimmie2 2012-03-08 01:30:38 +00:00
Shish
0ce9aa02a2 'false' == true. Convert the first param from DB value to real bool, and also use triple equals 2012-03-08 01:27:59 +00:00
Shish
5a6f146444 more detailed docs 2012-03-05 18:42:05 +00:00
Shish
88ee6ea148 get_theme_object is only used once, move it closer to where it's used 2012-03-05 14:21:41 +00:00
Shish
171a4b7c85 php syntax 2012-03-05 13:58:04 +00:00