Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Gallery: show image details


Reply


29 Posts   4959 Views

Avatar
pinkp

Community Member, 168 Posts

14 October 2009 at 6:52am

It was the host like you said. I had to create a php5.ini file with the contents:
display_errors = on
error_reporting = E_ALL

So now I know the error is:

Fatal error: Class 'ImageGallery_Controller' not found in /home/sites/mysite.co.uk/public_html/mysite/code/MyImageGalleryPage.php on line 6

Do you know how I fix this please?

Avatar
UncleCheese

Forum Moderator, 4096 Posts

14 October 2009 at 7:15am

Change

class MyImageGalleryPage_Controller extends ImageGallery_Controller {

to

class MyImageGalleryPage_Controller extends ImageGalleryPage_Controller {

Avatar
pinkp

Community Member, 168 Posts

14 October 2009 at 10:00am

BINGO! all works like a charm, thanks so much for your help UncleCheese!!! wicked. :)

Avatar
UncleCheese

Forum Moderator, 4096 Posts

14 October 2009 at 10:05am

That's great! I haven't had too many users customize the ImageGallery classes, so it's good to know that it's that easy.

Avatar
pinkp

Community Member, 168 Posts

14 October 2009 at 10:13am

I'd didn't realise it would create a brand new page type (noob error I expect) so it just means I have to re-build the gallery page but thats fine! all the new options are in the pop-up box and they show in the live site, just need to add my red dot images etc.
I will post the link to the final site when its finished as an example of it in action. Thanks again!

Avatar
pinkp

Community Member, 168 Posts

19 October 2009 at 11:18pm

Couple more points. After you add the details and you have a couple of rows of images the titles are covered by the next row of images. I fixed this by increasing the bottom-padding of the li in the CSS. Just in case that is helpful for anyone who tries this.

---------------------

Also though, the "Allow drag & drop reordering" is not having an effect on the actual live page. I can still check the box move my images and save etc. But this does not show on the front end only in the CMS?

It is still working fine with the ImageGalleryPage just not the MyImageGalleryPages??
Any ideas why this might be?

-Thank You

Avatar
pinkp

Community Member, 168 Posts

28 October 2009 at 4:50am

Could the drag and drop not be working in the new pages MyImageGalleryPage because of this that I read in the docs?:

"Activate Drag-and-Drop Sorting

Because drag-and-drop sorting adds custom functionality to all eligible DataObject subclasses, the DataObjectManager requires that the user opt into sorting capability.

mysite/_config.php

SortableDataObject::add_sortable_class('Testimonial');

After running a /dev/build, the following will be modified to give Testimonials sorting capability.

*
The field SortOrder will be added to the Testimonial table

*
The $default_sort property of the Testimonial will be set to SortOrder. This will ensure that the frontend template displays the objects in the correct order.

Note: To add several sortable classes at once, use SortableDataObject::add_sortable_classes(array $classNames)
"

Avatar
UncleCheese

Forum Moderator, 4096 Posts

28 October 2009 at 5:16am

Yes. Very good point. You need to add to your mysite/_config.php:

SortableDataObject::add_sortable_class("MyImageGalleryItem");

and build.