When displaying Random Image in the sidebar the url it produces looks like this:
domain.com/image_block/random/33
and then redirect to the picture page. I've seen a bunch of other Gallery 3 sites that link directly to the image page and I would rather skip the redirect if possible. Can someone tell he how to accomplish this? Ive looked around all day and can't find any answers.
Posts: 27300
Perhaps it is not the image block module. Carousel would be a example.
Got a URL to show the behavior that you said you have seen?
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 18
Its listed as "Image Block 3 Display a random image in the sidebar"
My site isn't live yet but here is an example from the very first site posted in http://galleryproject.org/gallery/g3demosites/
http://www.arabaresimleri2.com/
Posts: 27300
Looking at the source of the page you referenced I see:
So I still don't see what you are saying.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 18
The url of the picture link in the image block should be http://domain.com/album-name/picture-name but instead shows up as http://domain.com/image_block/random/21 and then redirects you to http://domain.com/album-name/picture-name
If you hover your mouse over the picture in random image in the sidebar at http://www.natureplanet.info/ it shows up as:
http://www.natureplanet.info/Fragrant-and-elegant-lilac-flowers-pictures/Fragrant-and-elegant-lilac-flowers-pictures-08
If you hover your mouse over the picture in random image in the sidebar at the site I showed you earlier http://www.arabaresimleri2.com it shows up as:
http://www.arabaresimleri2.com/index.php/image_block/random/368
Posts: 27300
I don't think that is the stock image block module. Could be the image block ex module.
The page you reference has a text-align attribute for the div.
And the image block module does not:
https://github.com/gallery/gallery3/blob/master/modules/image_block/views/image_block_block.html.php
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 18
Every single g3 site on the G3 demo page http://galleryproject.org/gallery/g3demosites/ works properly except the first site listed, which is the one I just showed you. It's not a different module. They are all Image Block with the just alignment added to center the picture. Thanks for trying to help me.
Posts: 27300
Here is an example from page 14 of the demo sites:
http://seds.org/gallery/
it has the image_block/random/## for the url so I suspect they others have edited the default image module or it is a different module based on the image block module.
It should not be that hard to make the behavior they way you desire. How is your coding skills?
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 27300
its a easy fix:
find
<a href="<?= url::site("image_block/random/" . $item->id); ?>">
and change to:
<a href="<?= $item->abs_url() ?>">
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 18
Thanks Dave!
That did the trick! I appreciate you taking the time to help me with this small problem. Is there an easy way to chose what pages Image Block shows up on? I basically want it on every page except the single photo pages.
Posts: 27300
eidt image_block_block.php Change
to
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 18
You deserve a medal Dave, thanks!