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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

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

[Notice] Undefined index: album


Go to End


3 Posts   1909 Views

Avatar
Multidots

Community Member, 16 Posts

6 October 2010 at 8:05am

Hello

I have installed the image_gallery module (r493) with silverstripe version 2.4.2.

After that I have created 2 album this is also working fine, but when I am trying to add photo(Upload Images....) to each album it give me error:

[Notice] Undefined index: album
POST /ProjectName/admin/EditForm/field/GalleryItems/UploadForm?ctf[GalleryItems][start]=0&ctf[GalleryItems][per_page]=10&ctf[GalleryItems][showall]=0&ctf[GalleryItems][sort]=SortOrder&ctf[GalleryItems][sort_dir]=&ctf[GalleryItems][search]=&ctf[GalleryItems][filter]=AlbumID_2&ctf[GalleryItems][view]=grid&ctf[GalleryItems][imagesize]=100

Line 87 in /var/www/ProjectName/image_gallery/code/ImageGalleryManager.php
Source

78 $fields = parent::getImportFields();
79
80 if(isset($_REQUEST['album']))
81 $fields->push(new HiddenField('AlbumID', '', $_REQUEST['album']));
82 return $fields;
83 }
84
85 protected function importLinkFor($file)
86 {
87 return parent::importLinkFor($file)."?album=".$_REQUEST['album'];
88 }
89
90
91 public function saveImportForm($data, $form)
92 {
93 if(isset($data['imported_files']) && is_array($data['imported_files'])) {

Trace

* ImageGalleryManager->importLinkFor(Folder)
Line 147 of FileDataObjectManager.php
* FileDataObjectManager->getImportFolderHierarchy(0)
Line 130 of FileDataObjectManager.php
* FileDataObjectManager->ImportDropdown()
Line 382 of FileDataObjectManager.php
* FileDataObjectManager->UploadForm(SS_HTTPRequest)
Line 137 of RequestHandler.php
* RequestHandler->handleRequest(SS_HTTPRequest)
Line 155 of RequestHandler.php
* RequestHandler->handleRequest(SS_HTTPRequest)
Line 155 of RequestHandler.php
* RequestHandler->handleRequest(SS_HTTPRequest)
Line 147 of Controller.php
* Controller->handleRequest(SS_HTTPRequest)
Line 281 of Director.php
* Director::handleRequest(SS_HTTPRequest,Session)
Line 124 of Director.php
* Director::direct(/admin/EditForm/field/GalleryItems/UploadForm)
Line 127 of main.php

Please help......

Avatar
Ryan M.

Community Member, 309 Posts

7 October 2010 at 7:00pm

I'm having the same problem after upgrading a SS 2.3.3 installation to 2.4.2.

I'll try to come up with a solution, but in the meantime please post if you find one! UncleCheese, if you have any idea how to fix, feel free to jump in.

Avatar
Ryan M.

Community Member, 309 Posts

8 October 2010 at 2:00pm

I contacted UncleCheese about this, his recommendation was to update the DataObjectManager, SWFUploadField and Image Gallery to their latest versions.

I did so and still get the same error, so am still looking for a solution. Will update if I find anything.