Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

Adsense in articles without Iframe

Asked Modified Viewed 3,603 times
A
abithecat
A
  • Junior Member, joined since
  • Contributed 29 posts on the community forums.
  • Started 14 threads in the forums
  • Started this discussions
asked
Junior Member

Hi, guys. I used iframe to show gog ads, but they changed the rules and adsense is not allowed to be showed in iframe. Now the question is how can I show adsense if we have these conditions:

* no iframe
* Automatic Line-Breaks shoul be ON - all my articles are formated this way...

If I switch off the Automatic Line-Breaks everytihng is ok, but my articles are displayed on one line. Any Ideas?


Thanks!
0 replies

3 posts

N
NetriX
N
NetriX 10
Need help? Having trouble?
» View our Documentation for guides, functions and more - including the Getting Started section!
» Attach Log Files and Screenshots when reporting issues
» My support days are usually Mon-Thurs. Send me a PM if urgent.
  • Senior Member, joined since
  • Contributed 566 posts on the community forums.
  • Started 93 threads in the forums
answered
Senior Member

No problem, are you open to have adsense displayed in a panel, and in this panel are you will to have it displayed on all pages (although you can choose via admin which pages to exclude).

So in :: Admin Panel > System Admin > Panels

Add a new Upper or Lower Center panel.

Quote

opentable("Advertisement"wink;
?>
<script type="text/javascript"><!--
google_ad_client = "ca-pub-7277300469198625";
/* 468x60, created 6/25/09 */
google_ad_slot = "7885283957";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<?php
closetable();


Replace my adsense code with yours.

Also, if you only want it on articles, edit the panel and under "Panel Restriction:"

add the following - /articles.php

Select the "Include on these pages" radio button, save.

Here's a screenshot for further details.
NetriX attached the following file:
ads.jpg [No information available / 68 Downloads]
0 replies
C
Craig
C
Craig 14
  • Fusioneer, joined since
  • Contributed 4,462 posts on the community forums.
  • Started 212 threads in the forums
answered
Fusioneer

Hi,

Take a look in the Addons DB for Ads Panel that might help you.

Regards
0 replies
A
abithecat
A
  • Junior Member, joined since
  • Contributed 29 posts on the community forums.
  • Started 14 threads in the forums
  • Started this discussions
answered
Junior Member

Hi thanks for the ideas, but I want something different.

Here is an example of what I am talking about: http://xn--80aalqgkndear.net/radio-fresh-radio-fresh-a3.html - here Automatic Line-Breaks is OFF and adsense appears like a charm.

I whant the adsense rectangle to be embeded in the text, like this ad. I modified articles.php and added the code in render_article function, but It can only be displayed in iframe or if Automatic Line-Breaks is OFF.

I want to avoid iframes or automatic Line-Breaks is OFF and show the ads surrounded with the text of the article. Big G forbade showing ads in frames and my articles doesn't appear well when automatic Line-Breaks is OFF...

Can I add the code in render_article function it theme.php?

There must be a solution
Edited by abithecat on 03-08-2011 22:40,
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 3 posts
  • Votes 0 votes
  • Topic users 3 members

3 participants

C
C
Craig 14
  • Fusioneer, joined since
  • Contributed 4,462 posts on the community forums.
  • Started 212 threads in the forums
N
N
NetriX 10
Need help? Having trouble?
» View our Documentation for guides, functions and more - including the Getting Started section!
» Attach Log Files and Screenshots when reporting issues
» My support days are usually Mon-Thurs. Send me a PM if urgent.
  • Senior Member, joined since
  • Contributed 566 posts on the community forums.
  • Started 93 threads in the forums
A
A
  • Junior Member, joined since
  • Contributed 29 posts on the community forums.
  • Started 14 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet