NineChime forum

Furry stuff, oekaki stuff, and other stuff.

You are not logged in.

#1 08-12-2008 16:44:56

quentin
New member

Litebox type viewer

Just a suggestion that I've basically hacked into my own Oekaki (Takes 30 seconds, 1 js file, 1 css file, and a folder of small images)

I used 'Lytebox' ( http://dolem.com/lytebox/ ) but am currently experimenting with other versions of Lightbox, Litebox, Etc.

It makes viewing pictures a bit more entertaining, it pops up a small box that will view the fullsized picture.  (Also, it can dynamically expand to show the full picture, or if the picture is too big to fit in the window, it can squish it down so you don't have to scroll.  This is a setting that can be changed depending on your own preference.)

Its extremely simple to add to any Oekaki.  You only have to edit 2 files,  header.php  and  index.php.

Basically one has to edit the header to load the javascript, then in index.php just change how the oekaki prints out the image links so it works with the lytebox.

The ending result is very nice, which you can see at my oekaki(s)

http://oekaki.zookami.com
http://toekaki.zookami.com

(Warning, Adult themes if you become a member. wink )

--Edit--
I just realized, this could have went in the 'Mods for Wacintaki/Wax' section.

Last edited by quentin (08-12-2008 16:47:17)

Offline

#2 08-13-2008 01:46:50

Waccoon
Administrator

Re: Litebox type viewer

These viewers are indeed very nice.  Part of the reason why Wac/Wax went to XHTML code was to support these viewers.

I really should add a control panel feature to enable this stuff.  If done properly, a wide variety of viewers can be supported.

Offline

#3 11-05-2008 00:03:23

rainbow
Member

Re: Litebox type viewer

quentin wrote:

Just a suggestion that I've basically hacked into my own Oekaki (Takes 30 seconds, 1 js file, 1 css file, and a folder of small images)

I used 'Lytebox' ( http://dolem.com/lytebox/ ) but am currently experimenting with other versions of Lightbox, Litebox, Etc.

It makes viewing pictures a bit more entertaining, it pops up a small box that will view the fullsized picture.  (Also, it can dynamically expand to show the full picture, or if the picture is too big to fit in the window, it can squish it down so you don't have to scroll.  This is a setting that can be changed depending on your own preference.)

Its extremely simple to add to any Oekaki.  You only have to edit 2 files,  header.php  and  index.php.

Basically one has to edit the header to load the javascript, then in index.php just change how the oekaki prints out the image links so it works with the lytebox.

The ending result is very nice, which you can see at my oekaki(s)

http://oekaki.zookami.com
http://toekaki.zookami.com

(Warning, Adult themes if you become a member. wink )

--Edit--
I just realized, this could have went in the 'Mods for Wacintaki/Wax' section.

That looks awesome!

I'm planning to implement the Litebox type image viewer on my oekaki soon (possibly early next year) and I want to know is this.

How I can make it display as a slideshow when someone clicks on the image and exclude images that have been marked as adult when either someone is not logged it or that they have disabled the ability to view images marked as adult? big_smile

Last edited by rainbow (11-05-2008 00:06:13)

Offline

#4 11-05-2008 05:00:24

Waccoon
Administrator

Re: Litebox type viewer

You group images by a label.  Here's how Lytebox does it:

Normal images:  <img ... rel="lytebox[normal]" />
Adult images:  <img ... rel="lytebox[adult]" />

Just use the appropriate keyword depending on the picture's adult rating and the user's adult flag, and of course, don't use a "rel" XHTML tag if the user doesn't have the adult flag at all.  The "rel" tag is what tells Lytebox that the image is supposed to be a boxed image.

Offline

#5 11-05-2008 21:45:29

Twighlight
Member

Re: Litebox type viewer

wait, cam u explain what exactly u have to edit and what to edit it to
as in, before and after?
i'd like to use this

Offline

#6 11-05-2008 22:07:47

rainbow
Member

Re: Litebox type viewer

Waccoon wrote:

You group images by a label.  Here's how Lytebox does it:

Normal images:  <img ... rel="lytebox[normal]" />
Adult images:  <img ... rel="lytebox[adult]" />

Just use the appropriate keyword depending on the picture's adult rating and the user's adult flag, and of course, don't use a "rel" XHTML tag if the user doesn't have the adult flag at all.  The "rel" tag is what tells Lytebox that the image is supposed to be a boxed image.

Thanks! I'll bookmark this forum post and try it out in a couple of months time. wink

Offline

#7 11-06-2008 02:42:34

Rage
Guest

Re: Litebox type viewer

Twighlight wrote:

wait, cam u explain what exactly u have to edit and what to edit it to
as in, before and after?
i'd like to use this

^ That's basically what I was asking above Rainbow tongue This looks like a really cool thing to have, my members would love it. big_smile

I'm too lazy to log in tongue

#8 12-30-2008 22:58:59

Demu
New member

Re: Litebox type viewer

I'm confused on what to do in index.php. I'd really love to have this feature for my oekakis.

What exactly am I supposed to do in the index.php file for Lytebox to work for me?

Offline

#9 12-30-2008 23:22:26

Rage
Guest

Re: Litebox type viewer

Demu wrote:

I'm confused on what to do in index.php. I'd really love to have this feature for my oekakis.

What exactly am I supposed to do in the index.php file for Lytebox to work for me?

Change:

Code:

        // Print image
if ($adult_block_mode == 0) {
echo <<<EOF
            <a href="$master_image"><img src="$thumbnail_image" class="$img_class_type" {$scale_size} alt="Pic #{$outerrow['PIC_ID']}" title="Pic #{$outerrow['PIC_ID']}" /></a><br />

To:

Code:

        // Print image
if ($adult_block_mode == 0) {
echo <<<EOF
            <a href="$master_image" rel="lytebox"><img src="$thumbnail_image" class="$img_class_type" {$scale_size} alt="Pic #{$outerrow['PIC_ID']}" title="Pic #{$outerrow['PIC_ID']}" /></a><br />

It's pretty easy, and a nice feature, everyone loves it big_smile

#10 12-31-2008 00:59:03

Demu
New member

Re: Litebox type viewer

Oh I see what I was doing wrong now. xD Thank you! My users are really enjoying it already. [:

Offline

#11 01-04-2009 19:03:03

Twighlight
Member

Re: Litebox type viewer

i cant get this to work.
i put this in the body tag of header

Code:

<script type="text/javascript" language="javascript" src="lytebox.js"></script>
<link rel="stylesheet" href="lytebox.css" type="text/css" media="screen" />

and this into the body lie rage said

Code:

// Print image
if ($adult_block_mode == 0) {
echo <<<EOF
            <a href="$master_image" rel="lytebox"><img src="$thumbnail_image" class="$img_class_type" {$scale_size} alt="Pic #{$outerrow['PIC_ID']}" title="Pic #{$outerrow['PIC_ID']}" /></a><br />

its not working right, see?
http://twighlight.tw.funpic.org/Oekaki/


what dint i do right?

T-T

Offline

#12 01-04-2009 19:23:20

Rage
Guest

Re: Litebox type viewer

Twighlight wrote:

what dint i do right?

T-T

If you have:

Code:

// Start HTML
send_html_headers();
?>
<script type="text/javascript" language="javascript" src="lytebox.js"></script>
<link rel="stylesheet" href="lytebox.css" type="text/css" media="screen" />

Above the <head> tag in your header.php file, it should work.

Did you upload all of the files within the Lytebox zip?

#13 01-04-2009 20:21:55

Twighlight
Member

Re: Litebox type viewer

no, in fact, look what happened to my layout o.o

i did what u told me

Offline

Board footer

Yep, still running PunBB
© Copyright 2002–2008 PunBB