Go Back   Netpond ™ > Webmaster Forums and Resources > Tutorials
Register FAQ Calendar Radio and TV NP Shop Search Today's Posts Mark Forums Read

Tutorials Tutorials and helpful articles made by ponders for ponders

Megasite
Reality, College Megasite, Gay, Shemale, Fetish Dating
Reply
 
LinkBack Thread Tools Display Modes
Old 05-06-2008, 05:51 AM   #1 (permalink)
MountainGoat
WARNING! May ask stupid questions...
 
MountainGoat's Avatar
 
Join Date: Feb 2008
Location: Catalan Pyrenees...
Posts: 602
Points: 715
Send a message via MSN to MountainGoat Send a message via Skype™ to MountainGoat
Simple open thumbnail in themed window PHP tutorial.

Here is a nice little bit of PHP for people who want to show their ‘larger’ images on a background instead of just a plain white background.

It is fairly simple to implement, and shows the larger image in the context of the web site/page, and allows you to display the banners or affiliated links around the image as well as on the site. So by your surfer looking at the same ‘page’ with the large image on it, only increases the chance of them clicking on your sponsor’s banner and making you some money, instead of just grabbing the big picture and may be not going any further.

To start with, you need to create a template for your page. Load it with your usual sponsor banners, links, or whatever you choose to put in there. This is just to insure that your pages look in the same context the whole way through of the page/site.

From your template save two files, for the purpose of this tutorial, I will say ‘gallery.php or HTML’ and ‘image.php’ (keeping the extensions the same is more professional looking in my opinion!)

First off we need to set up an image folder on the server structure. Keep it in the root, so you can find it easier, and it makes the little bit of coding later on a lot simpler to write.

1. Gather your images that you are going to use for the gallery.
2. Number the images 01 XX, where XX is the highest number of the amount of images you are going to use.
3. Create a copy of these images, and rename them with the prefix of L, so your image title would look L01.jpg, for example.
4. Now rename the images that you have previously numbered with the prefix of S… REMEMBER TO KEEP THE IMAGES MATCHING WITH THE ‘L’ PREFIXED ONES!!!
5. Cut the images with the prefix of S in to your standard thumbnail size for what you use.
6. Move both the S and L prefixed images in to the same folder, which could be a subfolder of /images/ for example.

Here we add the codes on to the gallery images, to open them up on the larger side, within site context.

1. Create your thumbnail gallery as normal, and instead of placing an direct link to image.jpg, use instead the link of:
PHP Code:
<a href="/image.php?id=XX&f=lXX" target="_blank"> <image src="/PATH TO IMAGES/sXX.jpg" alt="image 6" name="" width="WIDTH" height="HEIGHT" border="0" /></a
replacing the first XX with the gallery folder name, the second and third set of XX with the image number.
2. Go through all of the thumbs and add them to your page, but making sure that the ‘L’ number matches the ‘S’ number on them all.
3. Save this page and then that is that for this gallery.

Bringing the images up on the page, in context.

Now we are here, you need to open the ‘image.php’ file that you created earlier.

1. Position one of the large images in the area to be able to get the dimensions and positioning correct on the image.
2. Once you have got the positioning correct on the page, with your maximum width set (control by width, and leave out the height, because if not, you may end up with some squashed images later on!)
3. Flip over to the code view, and find the link to where the image is… It should look like
PHP Code:
<image src="/images/gallery1/L01.jpg" width="WIDTH" border="0" /> 
and then change to look like the following
PHP Code:
 <image src="/images/<?=$_GET["id"]?>/<?=$_GET["f"]?>.jpg" width="WIDTH" border="0" />
this will call the gallery identification, and also the image number when the link on your gallery is clicked.
4. You can put your own link on this image as well, using the standard <a href> command.
5. Save the image.php file to the root of your site.

I know this is probably very basic, and probably old, for most experienced webmasters, but it is a very good looking trick, which when set up is only a couple of minutes more work in putting a gallery together, and it puts your affiliate banners under the eyes of the surfer, again, instead of just letting them have the bigger image for nothing. If you get one extra sell out of it, then it is worth the time to set it up

To use banners or targeted texts directly to the sponsor whose images you are using, then create copies of the image.php, with a naming convention of your choice, and then put in the relevant banners to that version of image.php (prefix with the site initials, works well), and then in the gallery, instead of just using image.php in the link, you use the prefixed version.

You may have to change the location '/' on the image folders and the PHP script to get this working right, depending on how your site is structured.
__________________
I would change the world, but they would not give me the source code.
MountainGoat is offline   Reply With Quote Send a private message to MountainGoat
Old 05-16-2008, 01:04 PM   #2 (permalink)
flip
...babe bloggin'...
 
flip's Avatar
 
Join Date: Mar 2005
Location: ...around...
Posts: 4,264
Points: 612
Very nice dude - bookmarked this and will have a bash over the weekend
flip is offline   Reply With Quote Send a private message to flip
Old 05-16-2008, 01:09 PM   #3 (permalink)
PornBlogger
I see you baby.. shakin that Ass!
 
Join Date: Mar 2005
Location: Costa Rica
Posts: 1,606
Points: 690
Send a message via ICQ to PornBlogger
coolness!

gotta love da Pay-Hache-Pay

i'm going to sift through my little hacks and see if they are cool for tutorials, ya inspired me man!

gracias
__________________
- Reading can help your $$$ status
Vanity Email Service - "Be different.. Express Your Vanity!"
Daily Political News - "Coffee and Politics... Yum!" -
PornBlogger is online now   Reply With Quote Send a private message to PornBlogger
Old 05-18-2008, 11:02 AM   #4 (permalink)
AgentZee
I made fudge!
 
AgentZee's Avatar
 
Join Date: Oct 2007
Posts: 108
Points: 180
Send a message via ICQ to AgentZee
thanks for this goat - had to use this on the image.php page to stop it doing weird things during testing.

<image src="images/<?php echo $_GET['f']?>/<?php echo $_GET['id']?>.jpg" border="0" />
AgentZee is online now   Reply With Quote Send a private message to AgentZee
Old 05-19-2008, 09:47 AM   #5 (permalink)
MountainGoat
WARNING! May ask stupid questions...
 
MountainGoat's Avatar
 
Join Date: Feb 2008
Location: Catalan Pyrenees...
Posts: 602
Points: 715
Send a message via MSN to MountainGoat Send a message via Skype™ to MountainGoat
Quote:
Originally Posted by AgentZee View Post
thanks for this goat - had to use this on the image.php page to stop it doing weird things during testing.

<image src="images/<?php echo $_GET['f']?>/<?php echo $_GET['id']?>.jpg" border="0" />
That, as you have described there, is getting the gallery identification and the picture identification cross wired!

I've just read through the tutorial again, and where I was looking at it, I realised that I should have used something else to represent the image (possibly 'p' for photo). The reason I used the 'f' was when I was building it, I was building a site in Spanish, and 'f' is the inital for fotografía where as it could be confused in English as folder... Sorry for the confusion.

I have extended this script a bit, as to give the impression that you are updating your thumbnail page every day, where in fact you could only be doing it on a monthly basis... If anyone wants that posting up here, then let me know, and I'll sort it out.
__________________
I would change the world, but they would not give me the source code.
MountainGoat is offline   Reply With Quote Send a private message to MountainGoat
Old 05-19-2008, 03:10 PM   #6 (permalink)
joneze
If not us, who? If not now, when?
 
joneze's Avatar
 
Join Date: Apr 2004
Location: Spaceship Earth
Posts: 3,239
Points: 11,638
Nice Post MountainGoat.

Thank You.
joneze is online now   Reply With Quote Send a private message to joneze
Reply


Thread Tools
Display Modes



Netpond Resources
Resource Directory Tutorials & Articles Webmaster Tools Netpond News
 
Netpond Resources
LustDollars WildCash PussyCash Royal-Cash
Fetish Hits Cyberwurx MaxCash Fuck You Cash
AEBN GroobyBucks HD Pays PluginFeeds
Rabbits Reviews CraziesCash TrafficCashGold EvilAngelCash
Orgycash BigClicks Webcams Adult Pay Master
Free Porn Paradise British Porno British Porn Models ShanesworldCash
Shemale, Asian Megasite
All times are GMT -4. The time now is 08:29 AM.


Powered by vBulletin® Version 3.6.10
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
vBCredits v1.4 Copyright ©2007, PixelFX Studios