Duplicating Adtool Types

From TMM Wiki
Revision as of 15:21, 21 July 2010 by TMMStephenY2 (talk | contribs)
Jump to navigationJump to search
NATS 4
Members Admin
The Members Admin
View Member Details
Add Member
MySQL Auth
Mod Authn DB
Multisite Access
Member Logging
Member Password Retrieval
OpenID Connect
Mod Auth OpenIDC
ID Numbers
Adtools Admin
The Adtools Admin
Duplicating Adtool Types
Add New Adtools
Add New Adtool Type
Bulk Import Adtools
Downloadable Content Adtool Type
Get Hosted Galleries
Adtool Templates
Content of the Day
Linkcodes and Tools Admin
Setting Rules

NATS provides the ability to duplicate Adtool types, allowing you to build new adtools off of previously existing ones.

Note: Make sure you complete the following instructions before you begin customizing your duplicated adtool type in the [[NATS4 Adtools Admin|Adtools Admin].

Duplicating An Adtool

To duplicate an already existing adtool type, go to the adtools admin, find the adtool type you wish to duplicate, and click the "Duplicate Adtool Type" icon.

After you enter a shortname for your duplicated adtool type, you will be taken to the Editing Adtool Type page. Change your adtool description to a unique description and click Save Changes-- you will be making other changes later on. Next, click the "View Adtools" tab and upload your duplicated adtool type's first adtool.

To clarify, "original adtool type" refers to the adtool type that existed before duplicating, while "duplicated adtool type" refers to the new adtool type that NATS created after you clicked the icon.

Configuring Your Duplicated Adtool

Go to the Skins & Templates Admin and edit the default skin. You need to find templates related to your original adtool type. The template names you need contain three parts: "function_display_adtool", a shortname, and a view type. Find template names starting with "function_display_adtool" and containing the original adtool type's shortname. For example, to duplicate the Content adtool type, find the following two templates:

  • function_display_adtools_content_min
  • function_display_adtools_content_max

For each template you find, make your web browser open the template's edit page in a new tab or window. Usually you can do this by holding your keyboard's Ctrl key while clicking the edit icon in NATS. Without closing the new tabs or windows, go back to the template listing and scroll to the top of the screen. In the create template box, enter a name with the following form:

  • function_display_adtools_<shortname>_<view type>

Replace <shortname> with your duplicated adtool type's shortname. Replace <view type> with the view type of the first template you found earlier. For example, the first Content adtool type template gets the following name:

  • function_display_adtools_mytool_min

In the Header drop-down, choose No Header; in the Footer drop-down, choose No Footer. Enter a description and click Add. Go to the first template you found earlier, copy the entire contents of the template's Template Body, and paste it into the new template's Template Body.

In the new template, you need to update the variables that reference the original adtool type's fields so that they reference the duplicated adtool type's fields. When changing the field names in the template, prefix "ign_" to each field name.

After duplicating each template you found earlier, return to the Ad Tools Admin and edit your duplicated adtool type. In the Display Template field, click the drop-down box, select the option with your adtool's shortname, and click Save Changes.

From the Main Program Page, go to Affiliate Adtools, find your duplicated adtool type, and try getting the initial adtool you uploaded earlier. If it doesn't work, please submit a ticket and we'll help you out.


You can find specific instructions for duplicating a downloadable content adtool type in the New Downloadable Content Adtool Type article.