advert help?

Started on the old forum in May 2009 · view the original in the archive · old links redirect here

14 replies · 618 views · started 17 years ago · 1 min read

4 participants
n00b Developer · 61 posts #1

hi, i have adverts on my site but it wont aling center/middle could someone help me? to get it to aling center please? this is the code i have it in a .php and use it as include ("advert.php"); it keeps aling to the left

<!-- START CUSTOM WIDGETBUCKS CODE --><div><script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script></div><!-- END CUSTOM WIDGETBUCKS CODE -->
modfiles Developer · 200 posts #2

n00b wrote: hi, i have adverts on my site but it wont aling center/middle could someone help me? to get it to aling center please? this is the code i have it in a .php and use it as include ("advert.php"); it keeps aling to the left

<!-- START CUSTOM WIDGETBUCKS CODE --><div><script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script></div><!-- END CUSTOM WIDGETBUCKS CODE -->
<!-- START CUSTOM WIDGETBUCKS CODE --><script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script><!-- END CUSTOM WIDGETBUCKS CODE -->
n00b Developer · 61 posts #3

its still to the left with that code... modfiles

my site!

<!-- START CUSTOM WIDGETBUCKS CODE --><script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script><!-- END CUSTOM WIDGETBUCKS CODE -->
subzero Super moderator Fellow · 3,954 posts #4

Well if will not do that way use your style.css file

Place and mite need a edit to center your ads

p.margin {
margin: 2cm 4cm 3cm 4cm
}

Place anywhere is the file you want it to be....

<p class="margin">
<!-- START CUSTOM WIDGETBUCKS CODE -->
<script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script>
<!-- END CUSTOM WIDGETBUCKS CODE -->
</p>

Visit: Chat4u.mobi - The New Lay Of being a site of your dreams! Visit: WapMasterz Coming Back Soon!


SCRIPTS FOR SALE BY SUBZERO Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders. FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others... _______…

brentg Developer · 95 posts #5

ok seeing this topic is about ads i thought ill post here.

On my wap site i have mobile ads admob etc but i want when pc users browse my site that an adsesne ad will appear instead of admob etc.

Anybody can help? sorry for the hijack

Free Mobile Downloads: http://playwap.mobi

modfiles Developer · 200 posts #6

the browser detection script might help. and do something like this

//if detected as pc browser if ($browser == "$pc_browser") { echo "google_ads"; } else { //browser detected as mobile echo "mobile_ads"; }

subzero Super moderator Fellow · 3,954 posts #7

You can easy to decode mobile redirt script

Like in the include to include web and include wap

Visit: Chat4u.mobi - The New Lay Of being a site of your dreams! Visit: WapMasterz Coming Back Soon!


SCRIPTS FOR SALE BY SUBZERO Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders. FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others... _______…

brentg Developer · 95 posts #8

Thanx

Please correct me if im wrong:

//if detected as pc browser if ($browser == "$pc_browser") { echo "<?php include("adsense.php"); ?> "; } else { //browser detected as mobile echo "<?php echo admob_request($admob_params); ?>

<?php include("dtrade.php"); ?>

"; }

Free Mobile Downloads: http://playwap.mobi

modfiles Developer · 200 posts #9

brentg wrote: Thanx

Please correct me if im wrong:

//if detected as pc browser if ($browser == "$pc_browser") { echo "<?php include("adsense.php"); ?> "; } else { //browser detected as mobile echo "<?php echo admob_request($admob_params); ?>

<?php include("dtrade.php"); ?>

"; }

if are php functions and should be embedded within <?php ?> tag 😀 it should be like this

<?php
//if detected as pc browser
if ($browser == "$pc_browser") {
include ("adsense.php");
echo "<br />";
} else {
//browser detected as mobile
include ("admob.php");
echo "<br />";
include ("dtrade.php");
echo "<br />";
}
?>
brentg Developer · 95 posts #10

modfiles thanx.

but when i check on my phone the adsense code appears not the mobile code

😕

Free Mobile Downloads: http://playwap.mobi

modfiles Developer · 200 posts #11

i think you havent read my previous post 😛

the browser detection script might help. and do something like this

dont just use the code i posted. You need a browser detector/redirector script. you can find some in Source codes, small scripts

n00b Developer · 61 posts #12

subzero wrote: Well if will not do that way use your style.css file

Place and mite need a edit to center your ads

p.margin {
margin: 2cm 4cm 3cm 4cm
}


Place anywhere is the file you want it to be....

<p class="margin">
<!-- START CUSTOM WIDGETBUCKS CODE -->
<script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script>
<!-- END CUSTOM WIDGETBUCKS CODE -->
</p>

thanx il go try it now subzero

n00b Developer · 61 posts #13

modfiles wrote: i think you havent read my previous post 😛

the browser detection script might help. and do something like this

dont just use the code i posted. You need a browser detector/redirector script. you can find some in Source codes, small scripts

maybe this will help, upload the file and include this code on your index page

include('mobile_device_detect.php');
mobile_device_detect(true,true,true,true,,true,'http://www.YOUR-SITE.COM',false);
n00b Developer · 61 posts #14

i got it to center just incase anyones intrested heres the code... thanks for your help lads 🙂

<CENTER> <!-- START CUSTOM WIDGETBUCKS CODE --><div><script src="http://api.widgetbucks.com/script/ads.js?uid=OdQH5FQfygNxd1QH"></script></div><!-- END CUSTOM WIDGETBUCKS CODE --> </CENTER>

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close