News:

Join the Facebook Fan Page.

Main Menu

Attachments in new window

Started by habakuk, January 02, 2009, 06:27:18 PM

Previous topic - Next topic

habakuk

Hi all.
In the v1, it was easy to add the target so attached pictures could be opened in a new window. In v2, this ain't that easy, methinks. I see there is the javascript onclick action which just resizes the attached picture inline.

As a newbie who's looking forward to learn about creating mods (later on):

a) except removing the onclick part and using target="_blank", is there a easy way to open attached pictures in a new window?

b) if I'd go ahead and change the onclick call to a function written by myself (like opening a new window which will also display EXIF data and some other nifty features :)) what would be the proper way to do so.

I'm already happy if you point me to the relevant pages in the manuals. I spent a considerable time reading the forum and the manuals, but haven't found my way through to that part...

thanks in advance
®


karlbenson

I'd recommend HighSlide image viewer instead.

Much better than a new window.  A floating window.

http://custom.simplemachines.org/mods/index.php?mod=1450

Nao 尚

Or use SMF Media Gallery with Highslide enabled, too. Exif data is supported and shows through Highslide as well.

Of course that doesn't help much since you're mostly looking into programming mods yourself, sorry ;)

Hey Karl, did you notice how I'm sucking through your post stream? I'm enjoying that... Following your trail... Don't turn around... I might just be there :D
(Nah it's just that I noticed you have a gift for finding interesting topics, so I figured I'd just read all of your posts today! I'm done with your last one.)
I will not make any deals with you. I've resigned. I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.

Aeva Media rocks your life.

habakuk

Thanks a lot for the replies. I'll certainly have a look at the mentioned mods. Not that they fit my plans "perfectly", but hey, I can learn a lot anyway. SMF Gallery goes into a different direction as well.

I am happy with the attachements, no need for the gallery functionality.  I need a new window, as there will be more functionality added. Way beyond just displaying the data. The opening of the attachements will kind of start a whole new toolbox.

I simply added a new javascript function to the xml_topic.js file of the default theme, and referenced that script in the Sources/Display.php file.

However, I'd rather keep such changes less global... and wonder what the proper way to add such functionality might be.

Again, thanks for your help. I appreciate it.

cheers

Nao 尚

I can't help beyond what I said (I'm not very much into attachments now), so good luck to you anyway ;)
I will not make any deals with you. I've resigned. I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.

Aeva Media rocks your life.

habakuk


Advertisement: