silverstripe-picasaweb 

silverstripe-picasaweb Commit Details

Date:2013-05-10 10:49:11 (7 years 11 months ago)
Author:Nicola Fontana
Branch:master
Commit:204bac8319a6cce58d704e981c10f711ea0cb3e2
Parents: d74e18a8c3fd19eb0081c2d86367422ea4c2f738
Message:Improved main doc

Changes:
M_config.php (3 diffs)

File differences

_config.php
44
55
66
7
8
7
8
99
1010
1111
......
1313
1414
1515
16
16
17
1718
1819
1920
......
2122
2223
2324
24
25
26
27
25
26
27
28
29
30
31
2832
2933
3034
3135
3236
3337
34
35
38
39
40
3641
3742
3843
/**
* @package silverstripe-picasaweb
*
* Provides different ways to interface a SilverStripe based project to
* the PicasaWeb service using developer API v.2.
* Provides different ways of interfacing a SilverStripe based project
* to PicasaWeb services using developer API v.2.0.
*
* There are two kind of Picasaweb objects: photos and albums. They are
* identified by different links. An album is a Picasaweb link without a
* A photo is a Picasaweb album link with a fragment identifier appended
* such as https://picasaweb.google.com/109188999413540243075/ADGCairoCanvasSoftwareLibrary#5859399409666509250.
*
* The editing can be enhanced to include a [picasa] short-code, so
* The first way to integrate Picasaweb in a SilverStripe application is
* by enabling the [picasa] shortcode inside the HTML content, so e.g.
* [picasa]https://picasaweb.google.com/109188999413540243075/ADGCairoCanvasSoftwareLibrary[/picasa]
* will be rendered as an album.
*
* ShortcodeParser::get()->register('picasa', array('Picasaweb', 'shortcode'));
* </code>
*
* A specific page type can be augmented by providing a onBeforeWrite()
* callback so that the user can just paste a Picasaweb link prefixed
* by a dollar sign ($) inside the HTML code to get a specific photo or
* album element.
* Shortcode expansion happens on every hit, so every album modification
* on the Picasaweb side will be reflected in the next hit.
*
* The second form of interaction is by augmenting a specific page type
* by overriding its onBeforeWrite() callback so that the user can just
* paste a Picasaweb link prefixed by a dollar sign ($) inside the HTML
* code to get a specific photo or album element.
*
* <code>
* Object::add_extension('Page', 'PicasawebExtension');
* </code>
*
* In this case, the expansion of the links happens before storing the
* HTML code in the database, avoiding further Picasaweb requests on
* every page hit.
* HTML code in the database (hence once), avoiding further Picasaweb
* requests on every page hit. This in turn means every subsequent
* modification on the Picasaweb side will not be reflected.
*
*
* @todo implement an Object::add_extension('SiteConfig', 'PicasawebConfig')

Archive Download the corresponding diff file

Branches