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

ImageGallery upload link


Go to End


2 Posts   1314 Views

Avatar
engelsman

Community Member, 3 Posts

25 October 2009 at 1:03am

I was unable to upload images to an album in a locale different than the default. Not sure if this is a correct fix but i had to change this function in ImageGalleryManager.php in order for it to work:

public function UploadLink()
{
return parent::UploadLink()."?album=".$this->getSelectedAlbumID();
}

to this:

public function UploadLink()
{
return Controller::join_links( $this->BaseLink(), 'upload?album=' . $this->getSelectedAlbumID() );
}

Could not find much info about it so maybe someone finds it useful.

Avatar
engelsman

Community Member, 3 Posts

25 October 2009 at 1:05am

Edited: 25/10/2009 7:07am

Or perhaps the UploadLink() function should be fixed in FileDataObjectManager... Which would make the subject of this post a bit misleading :S

edit: nevermind, the original ImageGalleryManager.UploadLink() would still need the fix