SMFHacks.com
** Home Forum Index Hacks Products Login Register Search
Welcome, Guest. Please login or register.
May 25, 2012, 04:34:29 am

Login with username, password and session length
Members
Total Members: 10071
Latest: cdavidson012
Stats
Total Posts: 28687
Total Topics: 4977
Online Today: 60
Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Users: 0
Guests: 60
Total: 60
+ 
|-+ 
| |-+ 
| | |-+ 
| | | |-+ 
0 Members and 2 Guests are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: Why such a different location between these two?  (Read 542 times)
ApplianceJunk
Ad Seller Pro Customer
Sr. Member
*****
Offline Offline

Posts: 368



View Profile WWW
« on: September 01, 2011, 10:14:20 pm »

I was just using a image of a google ad until I got the ad placement where I wanted.

Code:
<br><img src="https://www.google.com/adsense/static/en_US/images/728x15.gif">

I had to use one br to drop the image down just were I wanted it in the center as show in first attachment, adgood..

Then I replaced the ad code with the google adsense script and it drops it way down, as show in the second attachment, adlow...

I have been trying to adjust the google adsense code placement, but don't know if it's possible.

Here is the code as I have it in the index.template.php file.

Code:
echo '
', empty($settings['site_slogan']) ? '<img id="smflogo" src="' . $settings['images_url'] . '/smflogo.png" alt="Simple Machines Forum" title="Simple Machines Forum" />' : '<div id="siteslogan" class="floatright">' . $settings['site_slogan'] . '</div>', '';


// Begin Ad Seller Pro Location - Test Location

global $sourcedir;
include_once $sourcedir . "/adseller2.php";

$adSellerAdData =  ShowAdLocation(1000);

// Check if any ads where found
if ($adSellerAdData != false)
{
// Dispaly the advertising code
echo $adSellerAdData;
}

// End Ad Seller Pro Location - Test Location
 
 echo '



</div> <div id="upper_section" class="middletext">
<div class="user">';

I have tried moving the Ad Seller Pro code around, but just seem to break it everytime I try something different.

Is it just the way it is or can it be adjusted so the google adsense ad displays higher up?

Thanks,
Logged

ApplianceJunk
Ad Seller Pro Customer
Sr. Member
*****
Offline Offline

Posts: 368



View Profile WWW
« Reply #1 on: September 02, 2011, 08:31:30 am »

After sleeping on it I wondered what would happen if I put the adsense code in a table first. Smiley

That did the trick...

With the adsense in a table it acts just like my image did that I was using to help locate the ad placement.

Anyway I go the ad just where I want it now, thanks for the great mod!
Logged

SMFHacks
Administrator
Hero Member
*****
Offline Offline

Posts: 9678


View Profile
« Reply #2 on: September 02, 2011, 08:38:35 am »

Glad you got it working. Yeah sometimes a table will keep the code in place. Adsense and scripts like that behave a little differently so sometimes either a table or div helps keep them in order.
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  

Recent
[May 24, 2012, 08:02:50 am]

[May 24, 2012, 04:11:41 am]

[May 21, 2012, 08:54:11 am]

[May 20, 2012, 11:06:52 am]

[May 20, 2012, 05:58:11 am]

[May 19, 2012, 06:16:58 pm]

[May 19, 2012, 05:42:37 pm]

[May 18, 2012, 03:08:38 pm]

[May 17, 2012, 06:07:46 pm]

[May 17, 2012, 02:22:07 pm]
Random Picture
Donate to SMFHacks.com
Help Support the SMFHacks.com mod making.
Powered by SMF 1.1.16 | SMF © 2006-2011, Simple Machines LLC
TinyPortal v0.9.7 © Bloc
SMF and SimpleMachines are registered trademarks of Simple Machines. SMFHacks.com is not affiliated with nor endorsed by Simple Machines.
Page created in 4.692 seconds with 18 queries.