| Author |
Message |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
Post subject: ThickBox 4 coppermine Posted: Fri Jan 11, 2008 1:31 pm |
|
Download from
www.jquery.com/demo/thickbox/
the following:
loadingAnimation.gif
macFFBgHack.png
jquery-latest.pack.js
thickbox-compressed.js
thickbox.css
Edit thickbox.css
find:
Code:
*{padding: 0; margin: 0;}
replace with
Code:
/* *{padding: 0; margin: 0;} */
find:
Code:
.TB_overlayMacFFBGHack {background: url(macFFBgHack.png) repeat;}
replace with
Code:
.TB_overlayMacFFBGHack {background: url(../../../images/macFFBgHack.png) repeat;}
Copy to your server:
loadingAnimation.gif and macFFBgHack.png to images/
jquery-latest.pack.js and thickbox-compressed.js to includes/javascript/
thickbox.css to themes/(yourtheme)/style(
Edit modules/coppermine/displayimage.php (make a backup first!)
find:
Code:
if (isset($image_size['reduced'])) {
after add:
Code:
global $modheader,$CPG_SESS;
$modheader .= '<script type="text/javascript" language="javascript" src="includes/javascript/jquery-latest.pack.js"></script>'."\n"
.'<script type="text/javascript" language="javascript" src="includes/javascript/thickbox-compressed.js"></script>'."\n"
.'<link rel="stylesheet" href="themes/'.$CPG_SESS['theme'].'/style/thickbox.css" type="text/css" media="screen" />'."\n";
find:
Code:
$pic_html = '<a href="'.getlink("&file=displayimagepopup&pid=$pid&fullsize=1",true,true).'" target="' . uniqid(rand()) . "\" onclick=\"imgpop('".getlink("&file=displayimagepopup&pid=$pid&fullsize=1",true,true)."','" . uniqid(rand()) . "','resizable=yes,scrollbars=yes,width=$winsizeX,height=$winsizeY,left=0,top=0');return false\">"; //toolbar=yes,status=yes,
replace with
Code:
$pic_html = '<a class="thickbox" href="'.get_pic_url($CURRENT_PIC_DATA, 'fullsize').'" target="blank">';
To show smaller images in the ThickBox
find in displayimage.php:
Code:
if (isset($image_size['reduced'])) {
replace with
_________________ Klas
.
My mice Terri & Tracy
Klas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
 |
|
| Back to top |
|
 |
dadki


Joined: Dec 17, 2007 Posts: 158
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Jan 11, 2008 2:39 pm |
|
nothing happens :S
dadki's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) xp/2.0.1/5.0.45/4.4.7/9.2 |
|
| Back to top |
|
 |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
|
| Back to top |
|
 |
dadki


Joined: Dec 17, 2007 Posts: 158
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Jan 11, 2008 3:02 pm |
|
yes it works on your i made all things like u wrote there and upload on my server in correct places but i can´t see changes
dadki's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) xp/2.0.1/5.0.45/4.4.7/9.2 |
|
| Back to top |
|
 |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Jan 11, 2008 3:12 pm |
|
Hmm, ok. I put all the files (including a modified displayimage.php from 9.2 rc2) in the zip below.
_________________ Klas
.
My mice Terri & Tracy
Klas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
 |
|
| Back to top |
|
 |
dadki


Joined: Dec 17, 2007 Posts: 158
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Jan 11, 2008 3:16 pm |
|
Thx man it works now
dadki's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) xp/2.0.1/5.0.45/4.4.7/9.2 |
|
| Back to top |
|
 |
jzky


Joined: Jun 25, 2004 Posts: 220 Location: Norway - Harstad
|
Post subject: Re: ThickBox 4 coppermine Posted: Sat Jan 12, 2008 10:28 pm |
|
Thnx for the tutorial Now it just needs some tweaks to have a back and forward button for a gallery... and a slideshow button 
And it only (?) works with LEO activated..
_________________ www.jzky.net a Dragonfly site. cms.jzky.net < test site. - Pardon my bad englsih My home town
jzky's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / Apache / PHP Version 5.2.0 /MySQL Version 4.1.21-standard / CMS Version 9.1.1 |
|
| Back to top |
|
 |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
Post subject: Re: ThickBox 4 coppermine Posted: Sun Jan 13, 2008 1:11 pm |
|
jzky wrote:
Now it just needs some tweaks to have a back and forward button for a gallery... and a slideshow button  ;)
www.terralights.de/ter...id=13.html
Quote:
And it only (?) works with LEO activated.. No, you don't need to activate LEO.
_________________ Klas
.
My mice Terri & Tracy
Klas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
 |
|
| Back to top |
|
 |
jzky


Joined: Jun 25, 2004 Posts: 220 Location: Norway - Harstad
|
Post subject: Re: ThickBox 4 coppermine Posted: Sun Jan 13, 2008 9:24 pm |
|
I had to activate LEO, with out it just opened the picture in a new browser window.
Not shure if it have something to do with some hack I had to do with coppermine to not check for GD lib.
_________________ www.jzky.net a Dragonfly site. cms.jzky.net < test site. - Pardon my bad englsih My home town
jzky's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / Apache / PHP Version 5.2.0 /MySQL Version 4.1.21-standard / CMS Version 9.1.1 |
|
| Back to top |
|
 |
jzky


Joined: Jun 25, 2004 Posts: 220 Location: Norway - Harstad
|
Post subject: Re: ThickBox 4 coppermine Posted: Sun Jan 13, 2008 10:53 pm |
|
Seems like I cant get lytebox to work, just shows the loading image see it in action
thickbox does work
_________________ www.jzky.net a Dragonfly site. cms.jzky.net < test site. - Pardon my bad englsih My home town
jzky's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / Apache / PHP Version 5.2.0 /MySQL Version 4.1.21-standard / CMS Version 9.1.1 |
|
| Back to top |
|
 |
Dylert


Joined: May 02, 2007 Posts: 109 Location: Norway
|
Post subject: Re: ThickBox 4 coppermine Posted: Wed Aug 11, 2010 7:27 pm |
|
Is it possible to set lytebox or thickbox as default? Now "Normal" is default.
Dylert's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / 1.3.34 / 4.1.13-standard / 4.3.11 / Dragonfly 9.2.1 |
|
| Back to top |
|
 |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
Post subject: Re: ThickBox 4 coppermine Posted: Thu Aug 12, 2010 11:23 am |
|
Hi Dylert,
I think you mean the "Thickbox and lytebox" hack from my homepage. If so, I have updated it. In displayimage.php you can now set thickbox/lytebox/normal to default.
There is also a new config value "alwaysauto" - I do not know if that makes sense, but I had the idea and could not resist 
test: test.terralights.de/in...at=0&pos=2
download: www.terralights.de/ter...id=13.html
_________________ Klas
.
My mice Terri & Tracy
Klas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
 |
|
| Back to top |
|
 |
Dylert


Joined: May 02, 2007 Posts: 109 Location: Norway
|
Post subject: Re: ThickBox 4 coppermine Posted: Thu Aug 12, 2010 8:34 pm |
|
Ok, thank you Klas, but how do I set lytebox to default in displayimages.php??
Dylert's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / 1.3.34 / 4.1.13-standard / 4.3.11 / Dragonfly 9.2.1 |
|
| Back to top |
|
 |
Klas


Joined: Apr 27, 2004 Posts: 37 Location: Oldenburg/Germany
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Aug 13, 2010 6:06 am |
|
You need to edit displayimages.php.
Open the file in an editor, at line 77 you find
Code:
$CONFIG['lb_display'] = 'thickbox'; // thickbox,lytebox,normal
replace 'thickbox' with 'lytebox'.
All behind // is a comment and need not to be changed.
The other settings are on/off settings, for example
if you replace it with
the option 'lytebox' will not be shown in the dropdown.
At line 603 you find
Code:
$info['Effekt'] = 'Wie soll das Bild dargestellt werden: '.lb_change();
You can change the text to something you like, for example
Code:
$info['Effect'] = 'How to show the image: '.lb_change();
_________________ Klas
.
My mice Terri & Tracy
Klas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
 |
|
| Back to top |
|
 |
Dylert


Joined: May 02, 2007 Posts: 109 Location: Norway
|
Post subject: Re: ThickBox 4 coppermine Posted: Fri Aug 13, 2010 5:28 pm |
|
Thanks a lot, Klas! It worked out well!
Dylert's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS) Linux / 1.3.34 / 4.1.13-standard / 4.3.11 / Dragonfly 9.2.1 |
|
| Back to top |
|
 |