7913 Posts in 1355 Topics by 930 members
DataObjectManager Module
SilverStripe Forums » DataObjectManager Module » Getting Description On Album Page
Discuss the DataObjectManager module, and the related ImageGallery module.
Moderators: martimiz, UncleCheese, Howard, Sean, Ryan M., biapar, Willr, Ingo, swaiba, simon_w
|
Page:
1
|
Go to End | |
| Author | Topic: | 1167 Views |
-
Getting Description On Album Page

3 July 2009 at 4:06pm
Quick question, I want just the current album's description listed on the specific album page. I can only loop through all of the descriptions, not get just one. I see there is an $AlbumTitle var, so wondering if there is something like $AlbumDescription or similar?
-
Re: Getting Description On Album Page

4 July 2009 at 4:31am
Oooh.. good idea. I've checked that into SVN for you.
-
Re: Getting Description On Album Page

4 July 2009 at 4:39am
Excellent, cheers.
I'm out of the office and will get working on this later. Mind telling me which file the change applies to? I have a decently modified version and I used SVN to download the copy onto my computer, and then upload it to the server. I no longer have the original version. (don't ask) haha.
While I'm here, any chance of having pagination for the album list? I have one image gallery page, and a lot of albums within it. I'd like to show the last X per page. Like how it works for amount of photos per page for the actual album.
-
Re: Getting Description On Album Page

4 July 2009 at 9:08am
I believe ImageGalleryPage.php has the change. Just FYI, in recent revisions, ImageGallery has become a lot more extendible through subclassing. You can now use custom Album, Image, and Page classes for ImageGallery which is designed to keep you out of the core code so you have the liberty to customize, but still get updates without any snags.
I don't have a timeframe for the album pagination. If you want to write the code in your modified version, send it along, and I'll ratify and check it in.
-
Re: Getting Description On Album Page

4 July 2009 at 11:42am
Okay great. Thanks good to hear about the new subclassing. I can't remember which version I'm currently running, but this will come in handy. I always dreaded upgrading and hoped to never have to (generally speaking of course), but I guess I'll take the time to do things proper to avoid this in the future.
One last note, not sure if you're aware but album titles can't have apostrophes in them or things bork. At least in my version.
-
Re: Getting Description On Album Page

15 January 2010 at 11:09pm
Hi did this feature get added? I have the latest SVN of ImageGalleryPage.php, how can include the Album Description of each page please?
I tried:
<% control Albums %>
<p>$Description</p>
<% end_control %>&
<% control Albums %>
<p>$AlbumDescription</p>
<% end_control %>But produces all or nothing. Thanks!
-
Re: Getting Description On Album Page

16 January 2010 at 3:30am
What do you mean "all or nothing?" Do you just want to show the description of the current album? You should be able to use <% control CurrentAlbum %>.. I would think.
-
Re: Getting Description On Album Page

16 January 2010 at 5:10am
Yeah sorry all or nothing was a bit cryptic! I meant all descriptions or none.
But anyway you solved it thanks!! CurrentAlbum not Albums! makes sense!
| 1167 Views | ||
|
Page:
1
|
Go to Top |


