News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Ad Management mod

Started by SMFHacks.com Team, January 30, 2006, 08:41:19 PM

Previous topic - Next topic

Bigguy

It`s all in the install.xml file. The above code tell you to look in the source directory for the file ModSettings.php and find this line:

'layout' => 'ModifyLayoutSettings',

and replace with this:

   'layout' => 'ModifyLayoutSettings',
      'ad_management' => 'ModifyAddManagement',

Don`t do this edit as it is done. I listed the files that need changed in your theme a couple posts up. If you can`t find the lines of code it tells you to then you will need to go to the theme author for a bit of help or check that thread out. (Helios thread)

RebelRose


Bigguy

I have to step out right now for a bit but if you can`t get it by the time I come back I will help if you want.

RebelRose

Thanks but I think if I cannot get it I will just not use it, thank you anyway

Bigguy

A really good editor that might help is Php Designer it`s really great.

hartiberlin

Quote from: electrohome on May 26, 2006, 01:03:06 AM
i am in the process of coding the new version of my mod, and it will include skyscrapers ads on the left side of the board along with the right side.
if you can wait a week or two i should have it complete

Hi Jeremy,
sounds good.
But there seems to be  still an error
in the y height space for the ads in the current 1.5 version.
Please have a look e.g. at this:
http://www.overunity.com/index.php/topic,933.230.html

There you can see, that the ad after the first posting is
cut off too early at the text...

2. For skyscraper ads I would prefer, if you could introduce it additionally
to the banner ads, so that one can use at least  3 or 4 different ads
througout the whole forum. ( 2 different ads at the sides and 1 or 2 different banner ad)
also it would be good, that the side ads would reload again newly, when a user
clicks a new page in the forum.
Many thanks for thius great mod !
Regards, Stefan.

hartiberlin

P.S. Please Jeremy make it sure, that it also
works with TinyPortal together.
So will it also support the skin themes from Tinyportal ?

Many thanks.

willi1

#427
Hello,

i have installed the vers 1.5 and i use the Theme Classic YaBB SE Theme what must i do
to see the ads in this template i can´t see it, i can see the ads only in the smf standard theme.

i have the setting only in the english language is that possible to have the settings in german language?

sorry for my english.

can you help me? any suggestions?

best regards

André

Bigguy

Quote from: Bigguy on May 30, 2006, 12:37:10 PM
You are going to have to edit that theme to work with the ad mod. If you go to the package manager and beside the mod it says "list files" press that link and then look for the install.xml file. You will see all the edits you have to do. The only ones you should have to do is the index.template.php, boardindex.template.php, Display.template.php, MessageIndex.template.php

EDIT: and maybe Modifications.english.php if your theme has it.

willi1

thank you for your answer,

my english is not so good, i understand so that i copy these files to the other theme is this correct?

best regards

André

ArkServer

Quote from: hartiberlin on May 31, 2006, 10:45:21 AM
P.S. Please Jeremy make it sure, that it also
works with TinyPortal together.
So will it also support the skin themes from Tinyportal ?

Many thanks.

I believe it works,  i use both tiny and this mod together and no probs.

Bigguy

No don`t copy them to your other theme. Go to the theme that you want the ad mod to work on. The only files you should have to modify in your theme you want it to work on are:

index.template.php, boardindex.template.php, Display.template.php, MessageIndex.template.php and maybe Modifications.english.php if your theme has it.

To find the "install.xml" file goto the package manager and click on "list files" next to the ad mod, then click "install.xml" In this file you will see the edits you have to make.

willi1

thank you for your answer,

i have found the list file and i have open the install.xml file

sorry sorry but i don´t know what settings i must change in these files?

index.template.php, boardindex.template.php, Display.template.php, MessageIndex.template.php and maybe Modifications.english.php if your theme has it.

sorry again

best regards

André

RebelRose

I was going to try to make this mod work with my theme and I looked at the install.xml and saw things there that are suppose to be replace in order to make this mod work, however, I am not that great or even good with code and I could not figure out where in the files the code needed to be replace.

Any assistance would be greatly appreciated

SMF 1.1 RC2
Helios Multi Color
MK Portal 1.1


Mr. Freeweed

Im also trying to get the ad mod onto the helios theme

currenty using

smf 1.1 RC2
tiny portal

Bigguy

#435
Here is the edit for the index.template.php. I do recomend getting an editor like php designer first.

Quote<file name="$themedir/index.template.php">
   <operation>
      <search position="replace"><![CDATA[   template_menu();]]></search>

<add><![CDATA[   template_menu();


if ($modSettings['ad_management_index'] && allowedTo('ad_manageperm'))
   echo '<br /><div align="center">',$modSettings['ad_management_content'],'</div>';]]>
</add>
</operation>


<operation>
<search position="replace"><![CDATA[function template_main_below()
{
   global $context, $settings, $options, $scripturl, $txt;]]>
</search>

<add><![CDATA[function template_main_below()
{
   global $context, $settings, $options, $scripturl, $txt, $modSettings;

if ($modSettings['ad_management_bot_index'] && allowedTo('ad_manageperm'))
   echo '<br /><div align="center">',$modSettings['ad_management_content'],'</div>';]]>
</add>
</operation>
</file>

All this means is.

find:

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

in "index.template.php" and replace it with:

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

if ($modSettings['ad_management_bot_index'] && allowedTo('ad_manageperm'))
   echo '<br /><div align="center">',$modSettings['ad_management_content'],'</div>';


After that, save the file, upload and move onto the next edit. ALWAYS MAKE A COPY OR A BACKUP OF THE FILE YOU ARE PLAYING WITH FIRST.

RebelRose

ok I did what you said to do, and I still do not see the ads, I have it to show an ad after first post. but nothing is showing

Bigguy

#437
Ok that is just the edit for the "show on all pages" not for "after first post" With that edit it should show at the top of your page. I should also point out that I am using ad_mod_rc2_v1-4-1 i`m not sure if the edits are different for the newest version.

RebelRose

ok well maybe it is different

thanks anyway

Farmacija

Quote from: electrohome on February 01, 2006, 06:14:10 PM
Quote from: RBH on February 01, 2006, 12:57:13 AM
any chance this could be made to display certain banners in certain boards or does it do that?
i hadn't thought of doing that. i have a few other things i want to add to this mod. if possible, i will look into that.
Quote from: d3v on February 01, 2006, 04:01:32 AM
adsense?
i assuming your asking if this works for adsense, and yes it does.

Quote from: BadCluster on February 01, 2006, 06:45:00 AM
i upload the mod as a zip file and try to install it,
before that i made everything '777' rights in the package folder and when i try to install it i get this error

"An Error Has Occurred!   
You cannot download or install new packages because the Packages directory or one of the files in it are not writable!


please verify that these files are also set to 777

Sources/ModSettings.php
Themes/default/index.template.php
Themes/default/BoardIndex.template.php
Themes/default/MessageIndex.template.php
Themes/default/Display.template.php
Themes/default/languages/Modifications.english.php

i do that but there isnt any change
www.farmaceuti.com
www.farmaceuti.com/tekstovi

Advertisement: