MyBB Community Forums

Full Version: Photo "pop-ups"?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Apologies in advance if this question is in the wrong place.

I have placed a new folder in my MyBB files where I have uploaded some photo's. I can link to these fine but they open in a new browser window. What I would like to know is if there is any way to make them open like a pop-up window to a given size and without browser controls, just an "X" or "Close" button. I know I can do it on my web site via my wysiwyg builder so it looks like this:

[Image: 2014-04-30_135210.jpg]

What I am trying to do is a year list of birds as can be seen here and scroll down to Spotted Flycatcher and you will see it is a link.

Can something like this be done in MyBB?

Denis.
You are going to want lightbox/shadowbox. They are for 1.4, but work if you change the compatibility to 1.6.

http://mods.mybb.com/view/lightbox-2
http://mods.mybb.com/view/shadowbox

I use shadowbox my self.
Thanks for that. I have uploaded shadowbox but it does not do as requested unfortunately. It only works from thumbnails, not links. Pity really as the end result was exactly what I was looking for.

Denis.
Try using Shadowbox, and when you add your link do this:

[lb=http://www.yoursite.com/imgdirectory/image.jpg]Image[/lb]

I made you a mycode:

regular expression

\[lb=(.*?)\](.*?)\[/lb\]

replacement

<a href="$1" rel="shadowbox">$2</a>

Obviously you need shadow box loading on your show thread (so install and activate shadowbox)
(2014-05-01, 08:19 AM)Leefish Wrote: [ -> ]Try using Shadowbox, and when you add your link do this:

[lb=http://www.yoursite.com/imgdirectory/image.jpg]Image[/lb]

I made you a mycode:

regular expression

\[lb=(.*?)\](.*?)\[/lb\]

replacement

<a href="$1" rel="shadowbox">$2</a>

Obviously you need shadow box loading on your show thread (so install and activate shadowbox)

Done all that. It works an absolute treat and is exactly what I was looking for. Is there a way to make the background a touch lighter though?

Anyway, that's a minor question I'm not too bothered about so I can only say a BIG thank you, you're an absolute star.

Denis.
Look in the shadow box setting - there is an option called Unlock Tweaks. Set that to ON and scroll down. you will find

overlayColor
The color to use for the modal overlay (in hex). Defaults to "#000000".

overlayOpacity
The opacity to use for the modal overlay. Defaults to 0.8.

Try adjusting those to change the color and opacity of the background color on popup.
(2014-05-02, 06:42 AM)Leefish Wrote: [ -> ]Look in the shadow box setting - there is an option called Unlock Tweaks. Set that to ON and scroll down. you will find

overlayColor
The color to use for the modal overlay (in hex). Defaults to "#000000".

overlayOpacity
The opacity to use for the modal overlay. Defaults to 0.8.

Try adjusting those to change the color and opacity of the background color on popup.

Thanks yet again, exactly how I wanted it now.

Denis.