Editing Your TGP Page HTML
Editing Your TGP Page
HTML
Introduction
Before you begin, make sure your brain is in HTML mode.
From here out, it is assumed that you understand HTML at the source level.
If you don't know HTML very well but want a very custom look to your site,
we recommend locating a professional HTML developer to assist you. HTML
coding is not a service we provide, and the tech support staff can only
provide limited assistance in getting your HTML to look how you want it -
this is why HTML knowledge is listed as a requirement when you purchase
the software. Editing the HTML for your TGP Pages is done through
the administrative script. As you can see from the screenshot below, just
select the "Edit HTML For" function, then the page you want to edit.
Planning Your HTML Ahead
Before
you even begin working on your HTML in the administrative interface, we
highly recommend that you layout how you want your TGP Page to look. This
can be done with your normal method for creating HTML pages. Once you have
a look that you are satisfied with, save the HTML so you can work with it
later in the adminisrative interface. Take a moment now to look
over your HTML so you are sure you know how it works. The better you
understand your HTML now, the easier it will be for you to set it up in
the administrative script later.
The Three Boxes
When
you get to the HTML editing interface you will be presented with one large
text box at the top and two smaller boxs at the bottom. They will be
labeled Main HTML, Template HTML, and Date Change HTML. This is where you
will place all of your HTML for the page you are working on. The first
time you view this page, the default HTML that is included with the
software will be displayed. You should look this over to get a general
idea of how things work. Add a few test submissions to your TGP, then
rebuild the pages so you can see how the HTML is written to the page. From
there, you can begin making changes to give the TGP pages your own look.
Main HTML This box will contain 95% of the HTML you
want to use for the page you are working on, and controls the basic layout
of the page. In the places where you want a gallery to appear, you will
use special template code to indicate that. When the software builds your
page, it will then replace that special code with the code that you enter
in the Template HTML box. Template HTML In this box
you will enter the HTML for a single gallery link. This HTML will
then be used for each of the galleries displayed on the selected page.
This HTML will generally include the gallery URL, description, number of
pics, and category. Date Change HTML This HTML is
optional, but can be used to insert a specified piece of HTML each time
the date changes. This can be useful if you want to display a date and
then a section of galleries for that date. The only valid template value
that you can use in this field is #%DATE%#, which will display the date of
the galleries to follow. Each time the software detects a change in the
date from the previous gallery it will insert the HTML you enter in this
box. Note that the date change HTML should only be used if you are
displaying your galleries sorted by approval date - it will not work if
they are sorted differently. This is the default method the software uses,
but if you have entered a custom sorting string in setup.cgi you need to
be aware of this.
Main HTML - In Depth
The
Main HTML box will contain 95% of the HTML for your TGP pages, and
controls the basic layout of your page. This portion will also tell the
software where you want your gallery links inserted, but not how you want
them to look. The template HTML tells the software how you want each
gallery link to appear, and that is covered in the next section.
We are going to give a very simple example to work with in this
section. Below is a complete HTML page, and this is an example of the HTML
you can use in the Main HTML box.
TGP
#%GALLERY_1%#
#%GALLERY_2%#
#%GALLERY_3%#
#%GALLERY_4%#
#%GALLERY_5%#
As you can see, this block of code contains
the necessary elements to create a very basic HTML page. The part that
should not look familiar to you are the #%GALLERY_1%# through
#%GALLERY_5%# portions of text. These are the special codes you need to
use to tell the software where you want each of the gallery links placed.
On this sample page, there will be 5 gallery links displayed.
The #%GALLERY_x%# Values In all of the following
text x represents a number between 1 and the total number of galleries you
have choosen to display per page on your TGP. It is important to note that
the x value does NOT correspond with the post IDs that are assigned to
submissions. These values tell the software where to insert your
gallery links. Every time the software encounters one of these values, it
will examine it to determine which gallery to place in that spot. The
software will then take the Template HTML, fill in all of the values
contained in it, and put the resulting code in the location where the
#%GALLERY_x%# value was. Categorizing The software
allows you to categorize your main TGP pages. In order to do this, you
have to use special versions of the#%GALLERY_x%# values. For every
category you have, there will be a corresponding #%GALLERY_x%# value for
you to use. Several examples are listed below. CATEGORY #%GALLERY_x%# Value
-------- -------------------
Hardcore #%Hardcore_x%#
Old & Mature #%Old & Mature_x%#
FuNkY CaTEgoRy #%FuNkY CaTEgoRy_x%#
The category name you enter in the
#%GALLERY_x%# value must match exactly with the category name you entered
in setup.cgi. An example of producing categorized output is listed below.
TGP
#%Hardcore_1%#
#%Hardcore_2%#
#%Hardcore_3%#
#%Old & Mature_1%#
#%Old & Mature_2%#
#%Old & Mature_3%#
#%FuNkY CaTEgoRy_1%#
#%FuNkY CaTEgoRy_2%#
#%FuNkY CaTEgoRy_3%#
When the software comes across the
#%Hardcore_1%# value, it will look up the first Hardcore gallery in your
database. The software will then take the Template HTML, fill in all of
the values contained in it, and put the resulting code in the location
where the #%Hardcore_1%# value was. Displaying by Date
With AutoGallery SQL you have the option of displaying the most
recent days worth of posts. For this, you will use the following template
values. Note that these template values will only work if you have
selected the most recent days worth of posts display option in setup.cgi.
#%DAY_1_1%##%DAY_1_2%##%DAY_1_3%##%DAY_1_4%##%DAY_1_5%#
#%DAY_2_1%##%DAY_2_2%##%DAY_2_3%##%DAY_2_4%##%DAY_2_5%#
DAY_1 is the most recent day, DAY_2 will be the day before, and so
on. Inserting The Date of the Previous Gallery In
building your TGP page it is often useful to have access to the date of
the gallery preceeding some HTML you want to insert. For example, if you
want to insert a blind link in your list of galleries so that it blends
in, you can use this feature. To do this all you need to do is use a
#%DATEOF_GALLERY_x%# template value. Below is an example.
#%GALLERY_1%##%GALLERY_2%##%GALLERY_3%##%GALLERY_4%##%GALLERY_5%##%DATEOF_GALLERY_5%#
- <a href="http://www.blindlink.com">15 Hardcore
Thumbs</a>#%GALLERY_6%##%GALLERY_7%#For this example
#%DATEOF_GALLERY_5%# will be replaced with the approval date of the
gallery that is in the #%GALLERY_5%# position. This can be done for any
gallery, and also works if you are using the category template values by
using#%DATEOF_Category Name_x%#
Template HTML - In Depth
The
template HTML is what will control how each of the gallery links will look
on your page, and this portion of your HTML will contain several template
values. Template values can be recognized within HTML because they are
surrounded by #%%# characters. For example, using #%CATEGORY%# in the
template box will tell the software to replace #%CATEGORY%# with the
category for the gallery it is currently printing to the HTML file.
This section will explain each of the template values that you can
use, and how you go about replacing your HTML with them so you get the
correct display. We'll start out by explaining the available template
values.
Value
Replaced By
#%POST_ID%#
The ID number assigned to the
gallery
#%GALLERY_URL%#
The URL to the gallery
#%DESCRIPTION%#
The description of the gallery
#%CATEGORY%#
The category of the gallery
#%NUM_PICS%#
The number of pics in the
gallery
#%APPROVE_DATE%#
The date when the gallery was
approved
#%APPROVE_TIME%#
The time when the gallery was
approved
#%ICONS%#
If this is a partner submission,
the icons for this partner
#%CHEAT_URL%#
The URL where surfers can report
broken links and cheating sites
#%FONT_COLOR%#
The font color to use for this
gallery
#%FONT_SIZE%#
The font size to use for this
gallery
#%[B]%#
This will make partner
submissions bold
#%[/B]%#
This will close the bolding HTML
tag for a partner submission
Now that
each of the template values has been explained, we will give a simple
example of how you can take your HTML and insert the template values in
the correct locations. Say that you want your list of gallery links to
look like the following: 12-20-2001 - 18 Hardcore
Pics12-20-2001 - 12 Softcore
Pics12-20-2001 - 14 Teen
PicsWhat you need to do is look at your HTML and detemine what
tags will generate one of those gallery links. In our case, the
HTML we have pulled out is:
12-20-2001 - 18 Hardcore Pics
Now we can take this HTML and start plugging
in the template values at the correct locations. The first thing we will
do is replace the category with the #%CATEGORY%# template value:
12-20-2001 - 18 #%CATEGORY%# Pics
Next, lets put in the number of pics on the
gallery, #%NUM_PICS%#
12-20-2001 - #%NUM_PICS%# #%CATEGORY%# Pics
Finally, we'll add the #%APPROVE_DATE%#
template value to insert the date and the #%GALLERY_URL%# value for the
URL to the gallery
#%APPROVE_DATE%# - #%NUM_PICS%# #%CATEGORY%# Pics
That's all there is to it, you've just
created your first template. All of the HTML you need to use is listed on
the line directly above. It is important to note that you will only enter
the HTML for a single gallery link in the template field.
Finishing Up
If
you're pretty sure you've got everything laid out how you want it, and
have setup the template values, you're ready to save it. Just select the
function at the bottom of the page to save this HTML for the pages you
want. You will then be returned to the main page of the administrative
interface where you can run the rebuild function. Once you have done that,
you can view your TGP page to see how it turned out. If you need to make
any changes, just follow the same procedure. To see example HTML
and instructions for setting up custom pages, visit the templates section
of the owners lounge. Many times having a look at some examples will get
you pointed in the right direction. Please note that these examples are
provided by other users of the software, and are therefore not supported
by our tech support staff.
Wyszukiwarka
Podobne podstrony:
TVideoGrabber embedded in HTML pageTVideoGrabber dynamically created in HTML pageTVideoGrabber IP?mera with authentication embedded in HTML pagepage$The Best Way to Get Your Man to Commit to Youhtmlpage&install product pageEditing the toolpathTraffic Authority Sell Your Own Productspage36page 1więcej podobnych podstron