• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

    • 😌 This community is user driven. Be polite with other users.
    • 👉 Is required to purchase a Chevereto license to participate in this community (doesn't apply to Pre-sales).
    • 💸 Purchase a Pro Subscription to get access to active software support and faster ticket response times.

SlimBox (aka. LightBox)

Danny.Domb

👽 Chevereto Freak
When you are on the viewer, when you click on the picture it loads it in a new page, instead, why not have a nice lightbox?

Demo:

xa2qf.png



First download and extract to the root of your chevereto website:
http://www.mediafire.com/?8k88prq1uhzw756

open INDEX.PHP

find
Code:
<script type="text/javascript">google.load("jquery", "1");</script>

REPLACE WITH
Code:
<script type="text/javascript">google.load("jquery", "1.6.1");</script>

find
Code:
<script type="text/javascript" src="<?php echo PATH_SCRIPT;?>js/jquery_support.js"></script>

add AFTER
Code:
<script type="text/javascript" src="js/slimbox2.js"></script>
<link rel="stylesheet" href="css/slimbox2.css" type="text/css" media="screen" />


find:
Code:
    <div id="imagen"><a href="<?php echo PATH_SCRIPT.DIR_IM.$folhost.$name?>"><img src="<?php echo PATH_SCRIPT.DIR_IM.$folhost.$name?>" alt="" <?php if ($ancho>=900) { echo 'width="900" '; } ?>/></a></div>

REPLACE WITH
Code:
    <div id="imagen"><a rel="lightbox" href="<?php echo PATH_SCRIPT.DIR_IM.$folhost.$name?>"><img src="<?php echo PATH_SCRIPT.DIR_IM.$folhost.$name?>" alt="" <?php if ($ancho>=900) { echo 'width="900" '; } ?>/></a></div>
 
--- Instructions for 2.0.8 ---

Still extract the contents to the root (public_html) of your website.


--- includes/template.functions.php

add the following code after line 395 (no need to call jquery as this versions already uses 1.6.1)

Code:
<script type="text/javascript" src="js/slimbox2.js"></script>
<link rel="stylesheet" href="css/slimbox2.css" type="text/css" media="screen" />


--- content/themes/Peafowl/view.php
--- on line 4 (for top text link) and line 5 (click on image link) change...

Code:
<a href="<?php show_img_url(); ?>" target="_blank">

to...

Code:
<a rel="lightbox" href="<?php show_img_url(); ?>" target="_blank">


done :)


*Note: Large images cause problems with functionality, they expand beyond the page and cannot be viewed or closed properly. Great for images smaller than standard screen resolution though.
 
Back
Top