I'm trying to put an adsense ad in an excerpt. I've added <script> as an allowed tag in the Pagelines settings. But it is removed anyway. What could be wrong? I'm not using any plugin that could interfere. And other text in excerpt is not removed.
5 replies to this topic
#1
Posted 06 November 2012 - 08:20 AM
#2
Posted 06 November 2012 - 09:06 AM
Hi,
I have to be honest and say that I have never tried to add javascript to an excerpt that way before. However, without evening trying, I don't think it would work, as javascript isn't HTML.
I would recommend you use a hook, to add your adsense to excerpts.
I have to be honest and say that I have never tried to add javascript to an excerpt that way before. However, without evening trying, I don't think it would work, as javascript isn't HTML.
I would recommend you use a hook, to add your adsense to excerpts.
#3
Posted 06 November 2012 - 10:18 AM
I'm already adding the adsense code using a hook.
But the adsense code always is removed. Why?
But the adsense code always is removed. Why?
#4
Posted 06 November 2012 - 06:24 PM
You can also try using a plugin from wordpress. Several of them have options to add ad units to excerpts. Ad Injection I think is one of them.
#5
Posted 07 November 2012 - 12:50 PM
Yes. But the problem seems to be in PageLines...
#6
Posted 07 November 2012 - 02:25 PM
You need to use an action not a filter.
pagelines_loop_after_excerpt
pagelines_loop_after_excerpt












