Themes/Language > Theme Support

Re: Edits for ad mod_1-0-7_v1-0-2b on Smf 1.0.7 (Index.template.php edits)

(1/4) > >>

cslepage:

--- Quote from: bigguy on July 04, 2006, 10:13:30 am ---NEXT EDIT: In your themes directory of the theme you want to modify find the "Index.template.php" file open it.

In same file find:


--- Quote ---   echo '
--- End quote ---

and replace with:


--- Quote ---   global $modSettings;
   echo '</td></tr>';
if ($modSettings['js_text_displayads_botindex'] && allowedTo('ad_manageperm'))
{
   echo '   <tr><td id="bodyarea">
            <div align="center">',$modSettings['js_text_content'],'</div><br /></td></tr>';
}

   echo '</table>';
--- End quote ---

Save, close and upload....after backing up the original "Index.template.php"

--- End quote ---

Which "echo'" do I replace? 

Also, if the theme doesn't contain one of the files mentioned, like "MessageIndex.template.php," do I make the changes in the "MessageIndex.template.php" for the default theme instead?

bigguy:
If the theme you are using doesn`t contain one of the template files the changes will have already been made to the one in the default theme so you don`t have to worry about those edits. Also you want to be looking for the first:


--- Quote ---   echo '
--- End quote ---

after the first edit you made in that file. Does that make sense.

NOTE: Remember to backup the file you are working on before editing anything.

cslepage:
If I make those changes to the files in the default theme, does that mean the ads I intend for the non default theme will also show up in the default theme?

I have a forum on my board with its own theme, and only that forum, initially, would have ads.

Also, can this mod be used to show ads only to guests?

bigguy:
You shouldn`t have to make any changes to the default theme files. When the mod installs it only installs to the default theme. You have to make changes to any template files that are in your custom theme folder. Yes this mod can be used only to show ads to guests if this is the way you have it set in your permissions.

cslepage:

--- Quote from: bigguy on August 09, 2006, 12:41:41 pm ---If the theme you are using doesn`t contain one of the template files the changes will have already been made to the one in the default theme so you don`t have to worry about those edits. Also you want to be looking for the first:


--- Quote ---   echo '
--- End quote ---

after the first edit you made in that file. Does that make sense.

--- End quote ---

The next echo ' I see is in here:

function template_main_below()
{
    global $context, $settings, $options, $scripturl, $txt;

    echo '</td>
    </tr></table>';

Is that the one I replace?

Navigation

[0] Message Index

[#] Next page

Go to full version