I decided to make a little script so that I could put thumb sites up in a matter of minutes. It's based on the TGP Charger engine so I am going to call it TGP Charger Lite. If you want it I am charging $25 via epassporte ([email protected]). You can use it on as many sites as you like but aren't allowed to give it to anyone else.
HOW IT WORKS:
If you open export.txt (which is a simple export from Smart Thumbs) you will see that it is a pipe [|] delimited file in this format.
thumb|url|description
This is your gallery database.
Now open index.tpl
TEMPLATE SECTION:
There are only 2 parts to know about the template. First is the Link Definition which has to be the first thing in the template. You can have as many link definitions as you need as long as they are labelled uniquely with A-Z characters...
There are only 3 template variables for the link definition:
%%url%% = The url to the gallery
%%thumb%% = The url to the gallery thumb
%%description%% = The text description for the gallery
In the example above there are 2 Link Definitions. Link Definition A and Link Definition B. Link Definition A is a Thumbnail Gallery and Link Definition B is a Text Link Gallery.
The second part of the template is the gallery output block (the table of thumbs). The script will output a whole table of thumbs for each block variable that you put in the template. The format for a block variable is as follows:
Link Definition:Number of Columns:Number of Rows:Block Number
Link Definition = The Link Template you defined in the Link Definition Section "<!--define LINK A -->". In the example you can see that there is an "A" there... this specifies that the block should use Link Definition A for all of the links in this block. "3" tells the script that you want 3 columns and "7" tells the script that you want 7 rows. The last number "1" tells the script that this is block number 1... if you want 2 blocks then the second Block Variable needs to end with "2" and so on.
USAGE:
Upload to the directory that you want the TGP to be in... CHMOD the directory 0775, CHMOD index.php 0777, run http://www.yourtgp.com/make.php to build the site.
CRON:
The script rotates the galleries on a completely random basis... If you want to update the site hourly you would us this cron job.
You can see the template in use at http://www.thumbviewer.com/index.tpl
You can build the site at http://www.thumbviewer.com/make.php
You can see the result http://www.thumbviewer.com
Hit me up on ICQ 212090289 or shoot me an email at [email protected]
HOW IT WORKS:
If you open export.txt (which is a simple export from Smart Thumbs) you will see that it is a pipe [|] delimited file in this format.
thumb|url|description
This is your gallery database.
Now open index.tpl
TEMPLATE SECTION:
There are only 2 parts to know about the template. First is the Link Definition which has to be the first thing in the template. You can have as many link definitions as you need as long as they are labelled uniquely with A-Z characters...
Code:
<!--define LINK A --> <a href = "/out.php?url=%%url%%&p=50" target="_blank" onMouseOver="window.status='%%url%%'; return true;" onMouseOut="window.status='';"><img src="%%thumb%%" border="0" alt="%%description%%"></a> <!--define END --> <!--define LINK B --> <a href = "/out.php?url=%%url%%&p=30" target="_blank" onMouseOver="window.status='%%url%%'; return true;" onMouseOut="window.status='';">%%description%%</a> <!--define END -->
%%url%% = The url to the gallery
%%thumb%% = The url to the gallery thumb
%%description%% = The text description for the gallery
In the example above there are 2 Link Definitions. Link Definition A and Link Definition B. Link Definition A is a Thumbnail Gallery and Link Definition B is a Text Link Gallery.
The second part of the template is the gallery output block (the table of thumbs). The script will output a whole table of thumbs for each block variable that you put in the template. The format for a block variable is as follows:
Link Definition:Number of Columns:Number of Rows:Block Number
Code:
<!-- Thumbnail Block 1 --> <!-- Output 21 Thumbnail Galleries in 3 columns and 7 Rows --> %%A:3:7:1%% <!-- Thumbnail Block 2 --> <!-- Output 21 Thumbnail Galleries in 3 columns and 7 Rows --> %%A:3:7:2%% <!-- Text Block 1 --> <!-- Output 50 Text Link Galleries in 2 columns and 25 Rows (50 Galleries) --> %%B:2:25:1%% <!-- Text Block 2 --> <!-- Output 50 Text Link Galleries in 2 columns and 25 Rows (50 Galleries) --> %%B:2:25:2%%
USAGE:
Upload to the directory that you want the TGP to be in... CHMOD the directory 0775, CHMOD index.php 0777, run http://www.yourtgp.com/make.php to build the site.
CRON:
The script rotates the galleries on a completely random basis... If you want to update the site hourly you would us this cron job.
Code:
*/60 * * * * cd /home/sites/yourtgp.com/; /usr/local/bin/php -q make.php >/dev/null
You can see the template in use at http://www.thumbviewer.com/index.tpl
You can build the site at http://www.thumbviewer.com/make.php
You can see the result http://www.thumbviewer.com
Hit me up on ICQ 212090289 or shoot me an email at [email protected]

Comment