Arfooo en français Arfooo in english

How to center the adsense

Propose here your templates, your plugins or ask one.
All tutorials available for Arfooo Directory are available in this category.

Moderator: effi

How to center the adsense

Postby vippt » Sun Jun 14, 2009 3:35 pm

Hello all,

Can somebody help me how i can center the adsense in the midle pages, abouve the categories, top hits, new .......

And yes i read the post about how to, but still dont know in wich place to add that code in the style.css

Thank you
vippt
 
Posts: 4
Joined: Sun Jun 14, 2009 3:30 pm

Postby saidbakr » Sun Jun 14, 2009 5:09 pm

Hello,

Simply, open the template file of the page you want to do that in and then search for {displayAd then place it inside div and set the text-align to center.

For Example:
In the template I use I opened the file templates/balanced/includes/header.tpl
Then I placed {displayAd place="header"} inside a div with the following code:
Code: Select all
<div style="float:left; text-align:center; width:100%; height:65px">{displayAd place="header"}</div>


Ofcourse you are able to manage the div style as you want or as meeting your template specification, but the major thing I think is to set the text-align:center.
Best Regards,
Said Bakr
Azzazi Anesthesia Web Directory, just another customized Arfooo directory.
saidbakr
 
Posts: 50
Joined: Wed Jul 23, 2008 9:09 pm
Location: Egypt

Postby vippt » Sun Jun 14, 2009 5:20 pm

Well that was my thought, but after trying i just got a blanck space.
So , not working and i dunno why.

For example:

In templates/afroo/includes/news.tpl i used:

Code: Select all
<div class="show_arbo">
<a href="{$setting.siteRootUrl}" class="link_showarbo">{'Directory'|lang}</a> &gt;
<a href="{'/site/news'|url}" class="link_showarbo">{'News'|lang}</a>
</div>

<div style="float:left; text-align:center; width:100%; height:65px">{displayAd place="header"}</div>

<div class="title_h_1">
<h1>{'News'|lang}</h1>
</div>


What i´m duing wrong ?

Thank you

saidbakr wrote:Hello,

Simply, open the template file of the page you want to do that in and then search for {displayAd then place it inside div and set the text-align to center.

For Example:
In the template I use I opened the file templates/balanced/includes/header.tpl
Then I placed {displayAd place="header"} inside a div with the following code:
Code: Select all
<div style="float:left; text-align:center; width:100%; height:65px">{displayAd place="header"}</div>


Ofcourse you are able to manage the div style as you want or as meeting your template specification, but the major thing I think is to set the text-align:center.
vippt
 
Posts: 4
Joined: Sun Jun 14, 2009 3:30 pm

Postby vippt » Sun Jun 14, 2009 5:32 pm

OK, i got it

very easy LOL

dont need to use a div just align center.

Code: Select all
<p align="center">{displayAd place="overSitesList"} </p>


Thank you for the help.
vippt
 
Posts: 4
Joined: Sun Jun 14, 2009 3:30 pm

Postby saidbakr » Sun Jun 14, 2009 6:42 pm

Hello,

The align attribute for HTML elements, currently, regarded as depreciated attribute. Hence, the usage of in-line CSS is more fine to be understood by all modern devices and applications.

By the way, the div styles regarded before, may not suitable or compatible with your template so you may use it as:
<div style="text-align:center; width:100%; height:XXpx;">{displayAd place="overSitesList"}</div>

Where XX is height required for your ad criteria.
Best Regards,
Said Bakr
Azzazi Anesthesia Web Directory, just another customized Arfooo directory.
saidbakr
 
Posts: 50
Joined: Wed Jul 23, 2008 9:09 pm
Location: Egypt

Postby vippt » Sun Jun 14, 2009 8:03 pm

Thank you, much better then my way :)

saidbakr wrote:Hello,

The align attribute for HTML elements, currently, regarded as depreciated attribute. Hence, the usage of in-line CSS is more fine to be understood by all modern devices and applications.

By the way, the div styles regarded before, may not suitable or compatible with your template so you may use it as:
<div style="text-align:center; width:100%; height:XXpx;">{displayAd place="overSitesList"}</div>

Where XX is height required for your ad criteria.
vippt
 
Posts: 4
Joined: Sun Jun 14, 2009 3:30 pm

Postby saidbakr » Mon Jun 15, 2009 12:23 am

Never Mind. I hope that you get your directory works fine :) and good luck
Best Regards,
Said Bakr
Azzazi Anesthesia Web Directory, just another customized Arfooo directory.
saidbakr
 
Posts: 50
Joined: Wed Jul 23, 2008 9:09 pm
Location: Egypt

Postby seopositive » Sat Jul 04, 2009 8:03 am

hi

put in <center> tag in html.
seopositive
 
Posts: 5
Joined: Mon Jun 29, 2009 7:36 am

Postby hosting456 » Sat Sep 12, 2009 9:19 am

Hi,
Use <center>Your AdSense Code</center>
hosting456
 
Posts: 8
Joined: Sat Sep 12, 2009 12:54 am


Return to Templates, plugins and tutorials

Who is online

Users browsing this forum: No registered users and 0 guests

 
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group | phpBB SEO
Copyright © arfooo.net  2007 - 2009  -  All rights reserved.