Ajax Lightbox for Intermediate and Fullsize Images Ajax Lightbox for Intermediate and Fullsize Images
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Ajax Lightbox for Intermediate and Fullsize Images

Started by Garibaldi, December 11, 2006, 03:59:11 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Garibaldi

I recently installed the great Highslide plugin that uses ajax to bring up a larger version of the image on the thumbnail page. This works great, but I also wanted to give ajax effects on the fullsize page as well so that it wouldn't use popups. This MOD does the trick on the intermediate page, it uses lightbox to bring up the fullsize image. However, these two MODs are not compatible with each other unless you modify them like this:

1. Install Highslide
2. Install the 2nd MOD, LightBox JS for Fullsize Popup Image, following the instructions in this post, but not performing this step:
Step 6. Add this code to the head section of your template.html file and change the directories to match yours

<link rel="stylesheet" href="themes/your_theme_folder/lightbox/css/lightbox.css" type="text/css" media="screen" />
<script type="text/javascript" src="themes/your_theme_folder/lightbox/js/prototype.js"></script>
<script type="text/javascript" src="themes/your_theme_folder/lightbox/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="themes/your_theme_folder/lightbox/js/lightbox.js"></script>


3. Upload the changed files
4. Download displayimage.php and open it.
Find:

require('include/init.inc.php');

Before, Add:

include("ajax.php");


5. Make a new file and put this code into it, save it as ajax.php and upload it into the same folder as displayimage.php

<html>
<head>
<link rel="stylesheet" href="themes/subsilver/lightbox/css/lightbox.css" type="text/css" media="screen" />
<script type="text/javascript" src="themes/subsilver/lightbox/js/prototype.js"></script>
<script type="text/javascript" src="themes/subsilver/lightbox/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="themes/subsilver/lightbox/js/lightbox.js"></script>
</head>
<body>
</body>
</html>


6. Give it a shot, it should work like this demo

Alcor

Hello.

I've a little problem with Ajax lightbox and Highslide. I put the link to the post where I asked about this and where they told me that I would ask here.

http://forum.coppermine-gallery.net/index.php?topic=35539.msg205063#msg205063

Thanks in advance for your answer.

Garibaldi

Hi Alcor,

I'm not sure if this is your question but the highslide plugin will only grab the fullsize image, at least in my experience. The intermediate setting seems to do nothing, still linking to the fullsize image. Therefore, depending on your dimensions and connection, it may take a bit to load it and popup the highslide box.

Alcor

Hello Garibaldi. Thanks for your answer.

I've proved the highslide to link the intemediate size image and it works. I've also proved highslide linking intermediate and ajax lightbox and both work in my PC, the load of the fullsize image is faster, obviously, and it doesn't show a warning popup in IE, about a script is causing problems, like in my server. I don't know what is the error maybe a script in my theme.php ???

RoarinRow

SMF 2.0 RC4
TP 1.0 RC1
Wordpress 3.0.4