68 Commits

Author SHA1 Message Date
Johan Cwiklinski
6746792bdf Drop short_tags 2018-05-19 17:01:37 +02:00
shadlaws
9b9f1a7b07 #2031 - Add class_exists() before method_exists() if class existence is unknown.
- fixed all instances of this in core code
- deleted previous Zend Guard Loader workaround in MY_Kohana.php
- updated Bootstrap.php to reflect deleted MY_Kohana.php
2013-03-02 13:25:10 +01:00
Bharat Mediratta
49f6ce2d94 gallery.menalto.com -> galleryproject.org
codex.gallery2.org -> codex.galleryproject.org

Fixes #1957.
2013-01-22 18:39:24 -05:00
Bharat Mediratta
d45a737779 Update copyright to 2013. Fixes #1953. 2013-01-21 01:22:01 -05:00
Bharat Mediratta
6effd5f75e Update date format to make it RFC822 compliant. Thanks to moullas. Fixes #1798. 2012-05-07 13:30:39 -07:00
Bharat Mediratta
bf2bb3e1ea Update copyright to 2012. #1822 2012-02-27 09:48:23 -08:00
Bharat Mediratta
c07af35a19 Oops, fix broken codex urls. For #1698. 2011-04-23 14:53:39 -07:00
Bharat Mediratta
ba20d5a500 Oops, this is the rest of the modules and themes for #1696 and #1698. 2011-04-23 14:46:07 -07:00
Bharat Mediratta
423daa52d5 Update copyright to 2011. 2011-01-21 23:01:06 -08:00
Bharat Mediratta
48af5e6b50 Rename "children" to "items" in our feed view because it makes more
semantic sense.
2010-06-20 17:25:23 -07:00
Bharat Mediratta
c3c2b45280 Update the copyright to 2010. It's only 3 months into the year :-) 2010-03-03 10:15:34 -08:00
Andy Staudacher
61f8af6e4c Fix for ticket #1020: Fix RSS feed validation of album / recent items feeds. 2010-02-16 21:56:56 -08:00
Bharat Mediratta
e7c564133f Use single quotes on the <?xml tag for readability. 2010-02-01 11:02:36 -08:00
Bharat Mediratta
0dc184e99f Overload url::current() and url::merge() to make the current url XSS
safe.  Add tests to make sure that it doesn't relapse with future
Kohana changes.  Fixes ticket #983.

Ref: http://gallery.menalto.com/node/93738
2010-01-18 11:10:37 -08:00
Bharat Mediratta
8b9a02084a Updates for the latest version of Kohana 2.4:
1) Controller::$input is gone -- use Input::instance() now
2) Handle new 'database.<default>.connection.params' parameter
3) Handle new 'cache.<default>.prefix' parameter
2009-12-21 21:27:43 -08:00
Bharat Mediratta
62693db037 Merge branch 'master' of git@github.com:gallery/gallery3 into bharat_dev 2009-12-05 17:56:31 -08:00
Bharat Mediratta
03ea1ee701 Change the default image to be the full size so that the slideshow shows the big one. 2009-12-05 12:00:50 -08:00
Bharat Mediratta
4a417708f0 Kohana::show_404() -> throw new Kohana_404_Exception() 2009-11-25 13:51:33 -08:00
Tim Almdal
dc67cf6481 Remove the REST_Controller and assorted baggage. Completes ticket #917 2009-11-25 13:02:14 -08:00
Bharat Mediratta
d12555de9a Don't show resizes for albums, only for photos.
Fixes ticket #893.
2009-11-15 18:54:12 -08:00
Tim Almdal
7ea13b3869 Normalize capitalization ticket #596 2009-10-28 12:15:52 -07:00
Tim Almdal
5fb0434a47 Clean up the rss feed for the slideshow. It now validates using "http://validator.w3.org/feed/". Fixes ticket #806. Doesn't fix ticket#23. 2009-10-23 21:15:16 -07:00
Chad Kieffer
3e6ba7acc3 Renamed most, if not all css selectors from gName to g-name. Moved a few shared images from wind to lib. Deleted unused images in the admin_wind. This will likely break a few ajax features. 2009-10-04 00:27:22 -06:00
Tim Almdal
60d35b8992 Use the block_manager to manage site sidebar panels. Fixes ticket #110.
* Extend block_manager to handle sidebar blocks. get_available has become get_available_admin_blocks, get_list becomes get_admin_list.
* Create new functions get_available_site_blocks which will look for gallery_block get_available_site_blocks.
* Refactor sidebar_blocks into a separate function and then call block_manager::get_html(site.sidebar). Convert image_block to use block management instead of theme::sidebar_blocks
* Change the block_manager api so that the theme is passed into the get method. convert info to the new sidebar block approach
* Convert the user module to use the new sidebar block structure. remove the installers for info and image_block modules.
* Convert tag and rss modules to the new sidebar framework. reset the version number to 1 for info and image_block modules.
* Change the get_html method to ignore empty blocks and change the individual handlers to return an empty string if no block is generated
* Add a warning message if no sidebar blocks are active and provide a link to the admin page that configures the sidebar.
2009-09-30 07:31:12 -07:00
Andy Staudacher
7608870537 Controller auth / CSRF fixes 2009-09-15 22:51: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
03c5c11775 Allow the RSS feed page size to be customizeable, up to 100 items (to
mitigate DoS attacks).

Have PicLens request a 100-item page to mitigate the bug where it
refuses to load the 2nd page.

Mitigates #23.
2009-09-01 20:13:23 -07:00
Andy Staudacher
2bc73e2e36 Fix XSS vectors in HTML attributes (mostly t() calls) 2009-08-31 21:51:57 -07:00
Andy Staudacher
8c3a2db380 Fix typo in description 2009-08-31 21:28:37 -07:00
Andy Staudacher
b9bd1681a3 Update all code to use helper method html::clean(), html::purify(), ... instead of SafeString directly. 2009-08-29 22:54:20 -07:00
Andy Staudacher
0204617b60 XSS fixes 2009-08-29 15:41:02 -07:00
Andy Staudacher
c01ac42c46 Refactor all calls of p::clean() to SafeString::of() and p::purify() to SafeString::purify().
Removing any p::clean() calls for arguments to t() and t2() since their args are wrapped in a SafeString anyway.
2009-08-29 12:48:40 -07:00
Bharat Mediratta
e2a9a1d284 Add quotes around all values that contain spaces in them, and add a
test to make sure that we continue to do so.

This makes sure that we don't have problems with 5.3 which treats the
literal "on" as a boolean.
2009-07-13 10:36:55 -07:00
Bharat Mediratta
bfca0c7903 Refactor the install/upgrade code to be more flexible.
Add xxx_installer::upgrade($version) method so that upgrade stanzas
are separate from install stanzas.  In the old code, to do an upgrade
meant that you had to re-evolve everything from the initial install
because we'd step through each version's changes.  But what we really
want is for the initial install to start off in the perfect initial
state, and the upgrades to do the work behind the scenes.  So now the
install() function gets things set up properly the first time, and the
upgrade() function does any work to catch you up to the latest code.
See gallery_installer.php for a good example.
2009-06-23 12:00:49 -07:00
Bharat Mediratta
32ea4406c8 Refactor the way that the rss module works so that we're not allowing
the url to dictate arbitrary static method calls.

* Each xxx_rss helper has a single feed() call which takes an id as the argument

* xxx_rss::available_feedS() only returns feeds when they're applicable (ie
  if you're viewing a tag, it won't show you an item feed).

* Feed urls are now in the module/feed_id form so that we can bind a
  feed id to a given module

* Tightened up the Rss_Controller by using url::merge and some other tricks.

* Made the slideshow module express its own feed.
2009-06-14 21:51:54 -07:00
Bharat Mediratta
00fad54c0b Refactor feed code to use stdClass everywhere. Fix bugs in the
max-pages calculation code.  Move feed related data into the $feed
variable and only pass that to the view.
2009-06-14 16:40:57 -07:00
Tim Almdal
8b7f7a2fbe Don't use stdClass to return the feed data. Just use an array. 2009-06-14 12:38:57 -07:00
Tim Almdal
76b89556fc Remove the sidebar flag from the feed definition returned by available_feeds and
replace with a type field with one of two values (head and block).  We need to
do this to determine what fields go in the rss block so we can ignore the
definitions that are related to the page head when creating the rss block that
goes into the sidebar.
2009-06-14 12:09:47 -07:00
Tim Almdal
484796e7cc Remove rss:item_feed, rss::tag_fead and rss_theme::head and move that
functionality in the <module_name>_theme::head function. Created rss::feed_link
to wrap the module supplied uri in the html link element.
2009-06-14 11:39:53 -07:00
Tim Almdal
b32670f030 Rename:
rss::get_feeds() -> rss::available_feeds()
 rss::process_feed() -> rss::feed_data()
2009-06-14 11:20:08 -07:00
Tim Almdal
e581440c3d Rename Rss_Controller::__call to Rss_Controller::feed, which changes the feed
url to rss/feed/<feed name>/[<id>]
Where feed name is the name of the feed (i.e. albums, updates, comments, tags
etc.) and id is the optional element id that the feed applies to.
2009-06-14 10:13:12 -07:00
Tim Almdal
30bdaa8123 Continue refactoring the rss module and distribute the creation of album and
tag feeds to the gallery and tag modules respectively.  This chould close
ticket #388
2009-06-12 11:48:13 -07:00
Tim Almdal
dc6c75cd05 Move the processing of rss feeds from the rss controller to callbacks in the
modules that are supplying the feed. The rss controller becomes a router.
In this change the comment and updates fields are distributed.
2009-06-12 08:52:03 -07:00
Tim Almdal
d4d145a443 Change from an event driven model to a call driven model similiar to the task
api.
2009-06-12 07:46:42 -07:00
Tim Almdal
e5793b5b26 Change the "request_feed_links" eventing handling so that individual modules
provide the part of the url (the suffix) that they are interested in and the
rss module will format the rest of the url.
2009-06-12 06:58:53 -07:00
Tim Almdal
4877f968b4 Rearrange the code in sidebar_block to logically group the code for readability. 2009-06-11 00:48:32 -07:00
Tim Almdal
1272d0837e Changed rss_theme::sidebar_blocks to fire the event "request_feed_links" to
allow modules to contribute rss feed links to the rss sidebar block.
Ticket #388.
2009-06-11 00:44:34 -07:00
Tim Almdal
0c5cb026a7 Only add the comment rss feeds if the comment module is active. fix for #365 2009-06-10 08:26:40 -07:00
Bharat Mediratta
9a6f18075a Rename "text" to "title" for clarity. 2009-05-31 01:14:28 -07:00
Bharat Mediratta
9369ccab7f Run all variables that come from user-entered data through p::clean() 2009-05-31 01:02:51 -07:00