UBB.Dev
Hi Guys:

I want to put an island between the first and second post in a PM thread. I get LOTS of PM traffic, and I want to put ssome advertising in there.

I know just enough coding to be dangerous.

Whatcha all think? I get the sense it's either a really simple template mod, or a highly complex re-write job.

Any helpers?

rb

i'd call it a template + code (small/medium) mod.

doable
Help please!

I want an ad slot in my PM template after first post. Any takers?

rb
like i said in pm at central, it's doable but would take some work to do
Okay, that took only 5 minutes smile

in /scripts/viewmessage.inc.php

find:
Code
	$user['USER_TOTAL_PM'] = $total_unread;

Add below:
Code
	$island_insert = get_portal_box("portal_box_3.php");

You can replace that number 3 there with any of the other custom boxes. It's hardcoded for simplicity of the hack. No sense in make more fuzz of it then the 2 line hack it is laugh

Just under it find
Code
		"online_status" => $online_status,

Add below:
Code
		"island_insert" => & $island_insert,

And yes, that's all there is to it.

It's a really simple hack, you just have to provide the $island_insert variable to the smarty template, and it will be displayed automaticly below post #1.
Posted By: Ian_W Re: Need a Mod ... Custom Island in PM templateHi - 10/15/2007 11:38 PM
Now we need a way to make these ads appear after say the 5th post in a thread or PM wink
That would be a major $10,000 dollar paid hack since you have to edit 2 files for that smile post_side.tpl and post_top.tpl and change the magic line in both smile

That's well beyond the scope of this topic wink
Hmm.

First off, HUGE thanks.

I'm running 7.1 and did the first add, but could not find in my viewmessage.inc.php file:

"online_status" => $online_status,

I tried putting the following in the smarty code, but no workee.

"island_insert" => & $island_insert,

Still no luck, Chuck.
Hm, I don't have a 7.1 copy running, I run the latest version (7.2.2 at this time).

Basicly all there is to it is adding that
"island_insert" => & $island_insert, in the $smarty_data = array(

But ehr, 7.1 could be your show stopper anyhow for this simply hack. If I remember correct, the joined post_side.tpl and post_top.tpl which is used to display posts in both flat, threaded and private topic mode was introduced in 7.2

I would recommend an upgrade to 7.2.2.
Originally Posted by blaaskaak
That would be a major $10,000 dollar paid hack since you have to edit 2 files for that smile post_side.tpl and post_top.tpl and change the magic line in both smile

That's well beyond the scope of this topic wink


$10,000 on it's way wink
Originally Posted by Ian_W
$10,000 on it's way wink


/templates/default/post_side.tpl

Code
{if $smarty.section.post.iteration == 1}

replace with

Code
{if $smarty.section.post.iteration == say the 5th post}

The post_top.tpl hack I will post after receiving the funds smile
i'll only charge $9999
Originally Posted by sirdude
i'll only charge $9999


yeah right, ex taxes I'm sure. Don't fall for that old trick Ian laugh
yah, but i'll also throw in a slightly used version of Halo II laugh
I'll add a 3 star New Mario Bros Nintendo DS savegame, with everything unlocked. And yarp, played those 3 stars myself.
always wondered how many stars you could get... lol
Originally Posted by Gizmo
always wondered how many stars you could get... lol


Final Castle, alle exits, all coins... That last one took me ages laugh
i guess i'm about 80% there, I have all castles done, probably all but 4 alt exits (2 ghost houses), and probably 80% of coins...

i've been really engrossed with Legend of Zelda, Phantom Hourglass; I'm a little over half way through, with the majority of minigames completed.
© UBB.Developers