Table of Contents
Introduction

When a gallery is submitted or scanned TGPX will check the to see if it contains information regarding the US 2257 legislation for record keeping. To search for this code, you will need to tell TGPX what it should look for on the gallery pages. The 2257 Code function allows you to do just that, and this document covers this topic.

2257 Code Search Type

When you add a 2257 code you have the option of specifying if it is a regular expression. Regular expressions are more complex than standard searches that simply look for the item as-is, but they add a great amount of flexibility. In TGPX the Perl Compatible Regular Expressions format is used for regular expressions. If you are not familiar with regular expressions, please see the Pattern Syntax portion of the PHP manual for additional information. If you check the Regular Expression box on the 2257 code add/edit form, the item(s) you enter will be treated as regular expressions and used to match against the HTML code of the gallery page.

If the values you enter are not regular expressions, be sure to leave that box unchecked. This will cause a normal search to occur which will match the item you enter anywhere within the HTML code. For example, if you enter the code "18 USC 2257" as a 2257 code and someone submits a gallery with the HTML code "<a href="2257.html">18 USC 2257 Records</a>", this will match the "18 USC 2257" 2257 code since it appears in the HTML code. Note that the search is case-insensitive and will match not only exact HTML code, but also portions of code.

Viewing/Searching 2257 Codes

To view or search your currently configured 2257 codes, access the Settings > Manage 2257 Code function from the control panel menu. This will display a page where you will be able to see the currently configured 2257 codes and search them if you wish.

In the table that displays the 2257 codes items, you will find a couple of functions that you can run on a single 2257 code. Each of those functions are described below. In addition to running these functions on single 2257 codes, you can also run the delete function on multiple 2257 codes at once. To run the delete function, put a check in the checkbox next to the 2257 codes you want to delete, then press the Delete button at the bottom of the page.

Adding a 2257 Code

To add a new 2257 code, access the Settings > Manage 2257 Code function from the control panel menu. This will display your currently configured 2257 codes. Near the top of the page in the header bar that reads "2257 Code" click on the icon. This will display a popup window where you will be able to enter the data for the new 2257 code that you want to add. Each of the form fields are described below. Once you have filled in all of the fields as you want them, press the Add 2257 Code button. This will add the new item to the database, and it will be activated immediately.

Editing a 2257 Code

To edit a 2257 code you will first need to locate it through the View/Search interface. When you locate the item you want to edit, click on the icon to bring up the 2257 code editing interface. This interface is nearly identical to the 2257 code addition interface, and has the same form fields with the same properties. You can make the changes that you want, and then press the Update 2257 Code button to save your changes.

Deleting a 2257 Code

To delete a 2257 code you will first need to locate it through the View/Search interface. When you locate the item you want to delete, click on the icon, which will ask you to confirm the deletion.

You can also delete several 2257 codes at once by putting a check in the box next to the codes you want to delete, then pressing the Delete button at the bottom of the page.