TGPX allows you to create an unlimited number of TGP pages to display your galleries. This document will describe how you can add, update, and remove the TGP pages that TGPX will be building.
While TGPX does not set a limit on the number of TGP pages you can configure, your server configuration will be a limiting factor. If you plan on having a very large number
of TGP pages generated by TGPX (500+) it is highly recommended that you have a high-end dedicated server.
Searching/Viewing TGP Pages
To view the currently configured TGP pages so you can modify or delete them, access the TGP Pages > Manage Pages function from the control panel menu. This will display a page where you will be able to see all of the currently configured TGP Pages and search them if necessary.
In the table that displays the TGP pages you have configured, you will find several functions that you can run on a single TGP page at a time. Each of those functions are described below.
Click this icon to run a Build type of build on this page | |
Click this icon to run a Build With New type of build on this page | |
Click this icon to go directly to the TGP page template editing interface for this page | |
Click this icon to edit the TGP page settings. A window will appear where you will be able to edit all of the page settings. | |
Click this icon to delete this TGP page. This will delete the TGP page from the database so it is no longer updated, but will not remove the actual generated TGP page from your server. |
Adding TGP Pages
On some servers PHP has it's open_basedir setting configured so that PHP scripts can only write files in specific directories. In shared hosting environments, this
setting is often configured in such a way that TGPX Server Edition will not be able to create TGP pages for sites other than the one it is installed on. In these cases
you will need to have your server administrator adjust the open_basedir setting so that TGPX Server Edition can write to all of the directories that are for websites that
you own and want to generate TGP pages for.
To add a new TGP Page, access the TGP Pages > Manage Pages function from the control panel menu. Near the top of the page in the header bar that reads "Manage TGP Pages" click on the icon. This will display a popup window where you will be able to enter the information for the new page. Each of the form fields are described below.
Path & Filename | Enter the full directory path and filename for the new TGP page. With the Server Edition of TGPX you can enter any directory path on your server, which allows you to create TGP pages for other sites on your server from one TGPX installation. If this points to a directory that does not yet exist, you will need to create the directory and set it's permissions to 777. If this points to a file that already exists, the file should be deleted or have it's permissions changed to 666; note that the existing file will be overwritten if you simply change it's permissions and do not rename it. |
Page URL | Enter the full URL that corresponds to the value you entered in the Filename field. |
Category | Select a specific category for this page, or MIXED if you want to allow galleries and ads from all categories. If you do select a specific category, only galleries and ads from that category will be allowed to appear on the page. |
Build Order | Enter a number to indicate the order in which this page will be built. This value will automatically be filled in with the next available position in the build order, but you can change it to any value. Lower numbers indicate pages that will be built first, and larger numbers indicate pages that will be built last. |
Tags | You can use this field to specify tags for this page. Tags are useful for grouping purposes so that you can tell TGPX to build only certain pages based on the tag(s) they have set. Tags must be at least 4 characters long and should be listed separated by spaces. |
Lock this page | Check this box if you do not want this page to be built using either of the 'Build All' page building functions. If this box is checked, the page will only be built when you click on the or icons in the Manage Pages interface OR if you use the --override-lock option of the cron.php script. |
Adding TGP Pages in Bulk
To add a new multiple new TGP pages at once time, access the TGP Pages > Manage Pages function from the control panel menu. Near the top of the page in the header bar that reads "Manage TGP Pages" click on the icon. This will display a popup window where you will be able to enter the information for the new pages. Each of the form fields are described below.
Base Directory | Enter the full directory path to the directory on your server where you want the TGP pages generated. This directory should have 777 permissions. With the Server Edition of TGPX you can enter any directory path on your server, which allows you to create TGP pages for other sites on your server from one TGPX installation. |
Base URL | Enter a URL that corresponds to the value you set for the Base Directory. |
Category | Select a specific category to generate pages for, MIXED if you want to generate general pages that can contain any categories, or ALL CATEGORIES if you want to generate pages for all of your defined categories. |
Filename Prefix | If you have selected MIXED for the category, you will need to fill in the filename prefix. This will be the name that will be used to generate the names that are used for the TGP pages. Examples are listed below. |
File Extension | Enter the file extension - without a period - to use for the generated pages |
Tags | You can use this field to specify tags for the generated pages |
Number of Pages | Enter a number to indicate how many pages should be generated. Examples are listed below. |
Conversions | Select what conversions should be done to category names when generating the TGP page filenames |
Lock these pages | Check this box if you do not want these pages to be built using either of the 'Build All' page building functions. If this box is checked, the pages will only be built when you click on the or icons in the Manage Pages interface OR if you use the --override-lock option of the cron.php script. |
Bulk Page Examples
Here are a few examples of the TGP page names that will be generated based on the input specified.
-
Category: MIXED
Filename Prefix: tgp
File Extension: html
Number of Pages: 5
Conversions: -
Generated Pages
tgp.html
tgp2.html
tgp3.html
tgp4.html
tgp5.html -
Category: MIXED
Filename Prefix: tgp
File Extension: php
Number of Pages: 2
Conversions: -
Generated Pages
tgp.php
tgp2.php -
Category: Big Boobs
Filename Prefix: -
File Extension: html
Number of Pages: 3
Conversions: Replace non alpha-numeric with dash, all letters lower case
Generated Pages
big-boobs.html
big-boobs2.html
big-boobs3.html -
Category: Big Boobs
Filename Prefix: -
File Extension: shtml
Number of Pages: 4
Conversions: Remove non alpha-numeric, no change text case
Generated Pages
BigBoobs.shtml
BigBoobs2.shtml
BigBoobs3.shtml
BigBoobs4.shtml -
Category: ALL CATEGORIES (assume Hardcore, Softcore, Big Boobs, Anal)
Filename Prefix: -
File Extension: php
Number of Pages: 1
Conversions: Replace non alpha-numeric with underscore, all letters lower case
Generated Pages
hardcore.php
softcore.php
big_boobs.php
anal.php -
Category: ALL CATEGORIES (assume Hardcore, Softcore, Big Boobs, Anal)
Filename Prefix: -
File Extension: html
Number of Pages: 3
Conversions: Replace non alpha-numeric with dash, no change text case
Generated Pages
Hardcore.html
Hardcore2.html
Hardcore3.html
Softcore.html
Softcore2.html
Softcore3.html
Big-Boobs.html
Big-Boobs2.html
Big-Boobs3.html
Anal.html
Anal2.html
Anal3.html
To edit a TGP page you will first need to locate it through the Manage Pages interface. When you locate the page you want to edit, click on the icon to bring up the page editing interface. This interface is nearly identical to the page creation interface, and has the same form fields with the same properties. You can make the changes that you want, and then press the Update TGP Page button to save your changes.
Deleting a TGP Page
To delete a TGP page you will first need to locate it through the Manage Pages interface. When you locate the page you want to delete, click on the icon, which will ask you to confirm the deletion.
You can also delete several pages at once by putting a check in the box next to the pages you want to delete, then pressing the Delete button at the bottom of the page.
Page Quick Tasks
From the Manage Pages interface you will be able to access the quick tasks functions which allow you to perform a search and replace on your pages. To access the quick tasks interface click on the icon in the Manage Galleries interface. A popup window will appear displaying the search and replace function.
It is very important to note that if you do a replacement in the Page URL it will also be necessary to do the same replacement in the Path & Filename field
to ensure that the two values are correlated correctly.
Likewise, when doing a replacement in the Path & Filename field, it may be necessary to do the same replacement in the Page URL value. If the text you are replacing appears in the Page URL, it will be necessary to run the replacement on that as well.
Likewise, when doing a replacement in the Path & Filename field, it may be necessary to do the same replacement in the Page URL value. If the text you are replacing appears in the Page URL, it will be necessary to run the replacement on that as well.
If you need to quickly search for and replace an item in your entire database of TGP pages, you can use this function. For example, this can be used if you have decided that you want to move all of your archive pages from a directory named 'old' to a directory named 'archive'. To do this you would enter '/old/' in the Search For box and select Page URL for the Search Field. In the Replace With box enter '/archive/'. You can now press the Search and Replace button and TGPX will automatically go through the each of your TGP pages and replace each occurance of '/old/' with '/archive/'. If you want to search for an empty value, use the special string NULL in the Search For field.
You do need to be somewhat cautious when using this feature because it will locate the text you enter in the Search For box anywhere within the field it is searching. For example, if you search for 'html' in the Path & Filename field and set it to replace with 'php' this could cause a problem for pages that have a .shtml extension. It would change those pages from .shtml to .sphp, which obviously is not correct.