Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Ajax Lightbox for Intermediate and Fullsize Images  (Read 8000 times)

0 Members and 1 Guest are viewing this topic.

Garibaldi

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 100
    • Wisconsin Collector Car
Ajax Lightbox for Intermediate and Fullsize Images
« on: December 11, 2006, 03:59:11 am »

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
Code: [Select]
<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:
Code: [Select]
require('include/init.inc.php');
Before, Add:
Code: [Select]
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
Code: [Select]
<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
Logged

Alcor

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 32
    • Cosas de Agapornis
Re: Ajax Lightbox for Intermediate and Fullsize Images
« Reply #1 on: April 17, 2007, 02:06:50 pm »

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.
Logged

Garibaldi

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 100
    • Wisconsin Collector Car
Re: Ajax Lightbox for Intermediate and Fullsize Images
« Reply #2 on: April 18, 2007, 05:32:27 am »

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.
Logged

Alcor

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 32
    • Cosas de Agapornis
Re: Ajax Lightbox for Intermediate and Fullsize Images
« Reply #3 on: April 18, 2007, 09:50:02 am »

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 ???
Logged

RoarinRow

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 23
    • Avalanche Style
Re: Ajax Lightbox for Intermediate and Fullsize Images
« Reply #4 on: August 27, 2007, 05:24:11 am »

Cool, thanks for the code.
Logged
SMF 2.0 RC4
TP 1.0 RC1
Wordpress 3.0.4
Pages: [1]   Go Up
 

Page created in 0.024 seconds with 20 queries.