I have just started building a drupal 7 site and have installed the media gallery module to it. I have the gallery set up and set to show media on a full page and have two problems I can't work out.
1. How do you change the alias / URL of the individual image pages so it can be more SEO, is there an option or does it need to be changed in the code?
2. How do I add an ALT tag to the images on the full page
Thanks
Comments
Comment #1
versvs commentedHi redhare,
I'm having the same issue. Not for SEO reasons, but I would like to have beautiful URL on each individual image. Did you manage to change that? How can it be made?
Thanks!
Comment #2
moloc commentedI don't see any option in media_gallery to do that, but in general (as a workaround) you can create aliases using /admin/config/search/path.
Comment #3
moloc commentedduplicate:
#1391558: Set URL for media on detail page.
#1463542: is there any way to assign Clean URLs to the individual media pages?
Change this to a feature request, to make URL-Aliases of /media-gallery/detail/%/% to some custom path (for example /gallery/image/[token]).
Note: Setting an alias for the URL /media-gallery/detail/%/% will break the colorbox-view, as the javascript is not able to replace the word detail to lightbox in the url.
Comment #4
jeramy commentedThere seems to be a decent answer on StackExchange:
http://drupal.stackexchange.com/questions/18574/path-configuration-in-me...
The answer is a bit over my head so I have been unable to implement it myself, but I link it here in hopes that maybe it will help someone else create a patch.
Comment #5
juliangb commentedFor info on this issue, I have created a small module for my own use that integrates media gallery with pathauto.
I have it working on my own site at the moment (see http://julian.granger-bevan.me/galleries/london), and will upload to drupal.org when I've made it a little more robust.
Comment #6
juliangb commentedI've uploaded the module to http://drupal.org/sandbox/juliangb/1785610 .
Please do try it out for your needs, and make an issue if we can make it better.
At the moment it works but is quite basic (and there might be better ways of doing things).
Comment #7
Hetta commentedOn D7.22 with media_gallery 7.x-2.x-dev, media 7.x-2.0-unstable7+38-dev, and pathauto 7.x-1.2+12-dev, I get the following error messages:
as well as this:
in the modules list.
Comment #8
juliangb commented@Hetta, was that on the sandbox module I linked to?
Comment #9
Hetta commentedYes, that was the sandbox one in #6.
Comment #10
Hetta commentedNevermind, media_gallery doesn't display "nice" URLs even if they're entered manually ... I'll be filing that as another bug.
Comment #11
Mooff commentedThe Sandbox version above unfortunately doesn't work with media 7.2 anymore.
It takes the pattern in file paths instead of the one in media gallery item paths and adds a redirect for that one.
Does anyone have a quick fix for that behaviour?
Comment #12
peterpan1972 commented@juliangb,
Hello, you can have your module Media Gallery Pathauto?
Comment #13
ivnish