Commit Graph

2008 Commits

Author SHA1 Message Date
Bharat Mediratta
83ebc2e2b0 Remove unused item::validate_no_name_conflict() and a debug line. 2009-09-07 20:59:11 -07:00
Bharat Mediratta
2f666f4c52 Add item::validate_url_safe() with a test. 2009-09-07 20:07:37 -07:00
Bharat Mediratta
6bc2235b27 Populate the slug field from the title as well. 2009-09-07 16:29:51 -07:00
Bharat Mediratta
795675e2b5 Add the slug to album, photo, and movie forms. 2009-09-07 16:21:58 -07:00
Bharat Mediratta
991bb0c063 Update golden file. 2009-09-07 16:21:58 -07:00
Bharat Mediratta
3f997562de Add support for a per-item "slug" which will be the user-visible url
component for that given item.  Album hierarchies are represented by
nested slugs.  By default, we convert the filename to a slug when you
create an album, photo or movie.
2009-09-07 15:42:08 -07:00
Bharat Mediratta
68a78f7cce Quiet down ffmpeg in movie::extract_frame() 2009-09-07 15:34:01 -07:00
Bharat Mediratta
14ba8505cc Don't allow users to take away their own edit permissions. If we
detect that they did, just give it back.  There's no visible message
in that case.
2009-09-06 11:45:41 -07:00
Bharat Mediratta
6c60310522 Don't show clickable link for breadcrumb items where the user doesn't
have edit permissions.
2009-09-06 11:34:51 -07:00
Bharat Mediratta
ac8c9d6670 Fix indentation. 2009-09-06 11:26:20 -07:00
Bharat Mediratta
d8f5b0f5a3 Change click() to change() so that we immediately update the UI when
the user picks a new option.
2009-09-05 21:14:25 -07:00
Andy Staudacher
b3d0cb5a4c Bugfixes for locales::locale_from_http_request(), and adding tests.
(And the tests should illustrate that kohana 2.4's API doesn't quite fit our purpose of simply getting the best match between the accepted (client) and the installed (g3) locales.)
2009-09-05 18:55:44 -07:00
Andy Staudacher
b01596c0f0 Update XSS test golden data file. 2009-09-05 18:19:13 -07:00
Andy Staudacher
beb232a1cc Revert previous edit. Prefer « none » (sweet, nice Unicode characters) instead of HTML entities. 2009-09-05 17:43:47 -07:00
Andy Staudacher
047196b23c Add missing view for language selection 2009-09-05 17:39:49 -07:00
Bharat Mediratta
9fbdcf3efd Change the module installer so that you don't need to provide your own
install() function if all you're going to do is to set the version of
the module from module.info into the database.  This means that for some
simple modules, you don't need an install.php file at all.
2009-09-05 13:39:30 -07:00
Bharat Mediratta
ab7323d17b Fix the url in the call to get subsequent entries to have the right
url, and to be json.  Fixes #719, which I introduced in my refactor.
2009-09-04 21:27:23 -07:00
Bharat Mediratta
add134cc75 placeholder for a missing view 2009-09-04 20:29:12 -07:00
Bharat Mediratta
a25640f9b2 Shorten the name in the block so that it doesn't wrap.
Use &laquo; and &raquo; in the << none >> text.
2009-09-04 20:28:46 -07:00
Bharat Mediratta
49de9bba68 Add @todo to replace locales::locale_from_http_request()
request::accepts_language() when we upgrade to Kohana 2.4
2009-09-04 20:19:15 -07:00
Andy Staudacher
f63766556a XSS test golden data file update 2009-09-04 11:20:02 -07:00
Andy Staudacher
75e99c9ea3 When changing user preferences, reset the session based locale preferences. 2009-09-04 11:17:11 -07:00
Andy Staudacher
001623c755 Add new locale preferences: Adding per session (cookie) locale preferences and check the browser's / OS' locale preferences.
Ticket 582.
2009-09-04 11:06:20 -07:00
Andy Staudacher
c453c0ef82 Simplifying SafeString a bit: From a XSS HTML security point of view, treat clean() and purify() the same.
No longer run a safe HTML string through the HTML purifier (since it's already marked as safe).

This also addresses the issue of calling purify() when no purifier is installed. In that case, we'd run clean() on a clean string (double HTML encoding).

If this approach doesn't work out, we can still modify the fallback code of purify() to check if the string is already clean before calling clean() instead of purify().
2009-09-04 10:11:42 -07:00
Bharat Mediratta
1ffb5b24df Checkpoint. 2009-09-03 11:34:02 -07:00
Bharat Mediratta
1405e8ed9e Fix tests for new purifier API. 2009-09-03 11:29:57 -07:00
Bharat Mediratta
1dca0b9d6b Fix test for new purifier API. 2009-09-03 11:28:42 -07:00
Bharat Mediratta
82dd468002 Refactor interaction with the purifier module so that the API is
cleaner and we don't need to know about the module innards.  Move the
config file over there too.
2009-09-03 11:25:02 -07:00
Andy Staudacher
e2d5944e56 Minor performance improvement: Reduce module var cache lookups in SafeString. 2009-09-03 08:49:14 -07:00
Andy Staudacher
8f6a120b52 Ensure that purify isn't applied twice for an already purified SafeString 2009-09-03 08:39:44 -07:00
Tim Almdal
c4b449add1 Merge branch 'master' into talmdal 2009-09-03 01:11:52 -07:00
Tim Almdal
dcdd44109b fix the expected return value of photos controller 2009-09-03 01:11:28 -07:00
Tim Almdal
41e3773417 fix the expected return value of album controller 2009-09-03 01:07:02 -07:00
Tim Almdal
33bcf11e27 Change the Html_Helper and SafeString tests to change the expeced results based on whether HtmlPurifier module is installed or not 2009-09-03 01:05:03 -07:00
Tim Almdal
3dc7e2e78c Merge branch 'master' into talmdal 2009-09-02 23:53:35 -07:00
Chad Kieffer
6feab02c86 Merge branch 'master' of git@github.com:gallery/gallery3 2009-09-02 22:36:19 -06:00
Chad Kieffer
02409d3b99 Fix bg images in tables bug in webkit and ie. #718 2009-09-02 22:35:54 -06:00
Bharat Mediratta
d007f31686 Undo rest of the indentation issue accidentally created in 8312eb and
partially fixed in 2c30dc
2009-09-02 21:29:22 -07:00
Bharat Mediratta
9237ab9bc1 Change graphics::generate() API so that it doesn't return a boolean,
instead it throws an exception if there's a problem.  The normal case
for graphics::generate is that it's going to succeed.  It'll only fail
if something un-handleable went wrong, so just use the resulting
exception.
2009-09-02 15:29:00 -07:00
Tim Almdal
de61da5bfc Merge branch 'master' into talmdal 2009-09-02 14:29:00 -07:00
Tim Almdal
2c30dc2d5b fix a leading space that was causing the file_structure_test to fail 2009-09-02 14:28:00 -07:00
Tim Almdal
aea34882b4 Merge branch 'master' into talmdal 2009-09-02 13:44:37 -07:00
Bharat Mediratta
b842a9d9ca Fix formatting, and use a properly named file in
change_photo_no_csrf_fails_test() so that GD doesn't bomb.
2009-09-02 11:58:04 -07:00
Bharat Mediratta
b9293755c0 Deal with the aftermath of adding sharpen() calls. Since GD does not
support it, this causes crashes as soon as you try to use it, which
breaks a bunch of our tests.  Also, give the user some idea that
sharpen() is missing in the UI.  Fixes #689.
2009-09-02 11:57:20 -07:00
Bharat Mediratta
79754c2ef4 Run 'graphics::choose_default_toolkit();' to pick a toolkit, which we
normally do as part of a regular install.
2009-09-02 11:53:10 -07:00
Bharat Mediratta
a09a6a06be Refactor how we use $this->relative_path() so that we're not calling
it twice on both sides of a ternary operator.
2009-09-02 11:28:41 -07:00
Tim Almdal
f2bbb2963a Remove debugging statementes 2009-09-02 07:07:47 -07:00
Tim Almdal
7fbd012d71 Move HTMLPurifier from core to contrib and make it optional. Delete the modules/gallery/lib and HTMLPurifier.php 2009-09-02 07:06:28 -07:00
Bharat Mediratta
d5cd6a92e7 Rename $comment_model to $comments, this time without stomping on the
pre-existing variable.
2009-09-01 20:40:18 -07:00
Bharat Mediratta
eab5d71d06 Revert "Rename $comment_model to $comments."
This reverts commit d85a8b20bb.
2009-09-01 20:39:08 -07:00