Hi, we’ve decided to publish detailed step-by-step instruction on how to start using sfGallery.
So first of all make sure you have these plugins installed:
- sfGuardPlugin
- sfModerationPlugin
- sfPropelActAsCountableBehaviorPlugin
- sfPropelActAsTaggableBehaviorPlugin
Then for frontend/backend allow modules:
frontend:
config/settings.yml
enabled_modules: [default, sfGallery]
backend:
config/settings.yml
enabled_modules: [default, sfModeration, sfGalleryAdmin, sfPhotoAdmin]
and in propel.ini you have to enable behaviours and modify propel.builder.peer.class:
#propel.builder.peer.class = addon.propel.builder.SfPeerBuilder
propel.builder.peer.class = plugins.sfModerationPlugin.lib.SfPeerBuilder
propel.builder.addBehaviors = true
this is requred by moderation plugin.
Also we use sfGuardPlugin for authentificating users (this can be changed easily though to any other authentificating plugin) and there must be added user_profile table, here is a sample of what can be used (you can put that in schema.yml):
propel:
_attributes: { package: plugins.sfGuardPluginPlus.lib.model }
sf_guard_user_profile:
_attributes: { phpName: sfGuardUserProfile }
id:
user_id: { type: integer, index: unique, foreignTable: sf_guard_user, foreignReference: id, onDelete: cascade }
nickname: { type: varchar(40) }
email: { type: varchar(40) }
created_at:
updated_at:
Custom routes are defined in sfGalleryPlugin/config/config.php, e.g.
http://sfgallery/user/gallery/new
http://sfgallery/photos
of course it’s better to put them into routing.yml for better performance.
And you can use these urls to get access to admin area:
http://sfgallery/backend_dev.php/sfGalleryAdmin
http://sfgallery/backend_dev.php/sfPhotoAdmin
(here sfgallery is possible project name).
Of course we skipped here part which describes enabling of sfGuardPlugin. So you should handle it because sfGalleryPlugin allows creating galleries/photos only for registered users (i.e. no anonymous mode availalbe).
And finally here is 1.0.1 fixed version of this plugin (as were reported some files were missed in 1.0.0 release): sfgalleryplugin-101
We hope this instruction will be helpfull for you.
Thanks for all ya comments and feedbacks!
6 replies on “sfGallery plugin 1.0.1 (installation step-by-step)”
Hi,
Great job ! Is there somewhere a demo of the plugin in action ?
unfortunately, nonone did report yet that put plugin into any project but we will definitely publish if anyone will do 🙂
why don’t you publish a demo somewhere…
sorry i dont have hosting which would support symfony so.. i cant
[…] sfGallery plugin 1.0.1 (installation step-by-step) […]
How about a screen shot or two?