How can we remove adSense ads from post content - adsense

How can i remove the adsense banners from post content of wordpress site.
It seems ads adding automatically.
http://www.digitaldevnet.com/power-of-influencer-marketing-to-your-business/
showing at 3 different places.
I am not using any plugin.

You can target it by class 'adsbygoogle' and remove it from the document like this:
var ads = document.querySelector('.adsbygoogle')
ads.parentNode.removeChild(ads)
If you need to remove all ads from the page you'd need to get a collection of all elements with this class and remove the within the loop
var ads = document.querySelectorAll('.adsbygoogle')
for (var i=0; i<ads.length; i++)
ads[i].parentNode.removeChild(ads[i])
But I believe there will be one banner from amazon left...
If your site is not hosted on free hosting services you can just remove widgets with ads from your template.

Related

Ionic 3 | Set Admob Banner Position inside specified DIV

I'm working on ionic 3 app ( similar to news feeds ) and wanted to show AdMob in it. It is working and it is showing at the bottom of the screen. But I wanted to show it in a Div ( basically I wanted to show it between news feeds ). Is it possible?
If not, is it possible to use Google Adsense inside ionic 3? Where I can place the Adsense tag wherever I wanted inside the HTML.
And is it permissible to use Google Adsense inside ionic 3 ?
Im guessing that you use this AdMob Free NPM Module.
With this module you can specify banner Ads only on top or bottom of your WebView. There is no possible way to specify a DIV as position.
However you could go with the AdSense Method.
I recommend this NG2 Adsense Module. It also has a live Demo here.
With this module you can place Ads in your News Feed just like this for example:
<ng-adsense
[adClient]="'ca-pub-7640562161899788'"
[adSlot]="7259870550"
[display]="'inline-block'"
[width]="320"
[height]="108">
</ng-adsense>

Google DFP is rendering div for empty third party ad tags

I am using Google DFP Small Bussiness for ad serving and
everything whas fine until I upgraded from GAM tags
to GPT tags.
The issue is as follows
I have a standard 300x250 Ad unit
I create a normal line items and add this ad unt to it
I upload third party ad code (from ad network). Sometimes this
code will display the banner and sometime it wont.
Now with old GAM tags if third party ad is empty the GAM tag
will not render anything.
But with new GPT tag will render the div with 300px width and
250px height.
Is there any way to solve this issue.
Thx
You are looking for the collapseEmptyDiv's method.
https://support.google.com/dfp_premium/answer/3072674?hl=en

Google Apps Scripting: How see the version number of a Google Sites page on the page itself

I want to see the version number of a Google Sites page on the page itself. I am talking about the numbers you see when you click the "More" button, then select "Revision History".
I am OK with any method to solve the problem, however currently I am trying to solve the problem with Google Apps Scripting.
I am able to see the last update time of the page by embedding the script below to the page:
function doGet(e){
var app= UiApp.createApplication();
var page = SitesApp.getActivePage();
app.add(app.createHTML('Last updated: ' + page.getLastUpdated().toISOString()));
return app;
}
The problem is, I could not find a getVersion() like method.
Thx.
You can't do this for several reasons.
The page version is hosted in this variable inside the google site pages.
webspace.page.revision
This is a good news but you can't access it.
1) If you try to access it using html box, the content of your html will be sanitized by caja and you will not access this variable.
2) If you try to build a javascript code and put it in an Apps Script caja will also forbid you to use variables from the parent frame. Even if you use SandboxMode.NATIVE.
3) If you try to put this code in some other site and include it as an iframe the content will be striped by your browser because of cross domain restrictions.
Sorry to say but what you want is impossible with todays caja restrictions.

Google Custom Search Element: Styling Ads

I added a Google Custom Search Element to my website. I already modified the look and feel of the CSE to my website, but I can't modify the look of the ads element since it is inside an Iframe.
Does anybody know how to set-up the style of the ads Iframe? I want do put in a background color and change the font.
Thanks!
This feature seems to be available only for Google Site Search customers. If you are one, you'll be able to recieve your search results as an XML feed, and apply a presentation layer on the raw data. All the details on how to do this are available at the official Google Custom Search site.
You can try this api for AdSence search - https://developers.google.com/custom-search-ads/docs/implementation-guide?hl=en , but you can't make ads view like search results.

facebook-share popup not getting customized for an Iframe application created with DotNet Libraries

0 vote down star
I have a .aspx page and I am creating a Facebook iframe applcation and i want to implement the share functionality on my page by using which the facebook user is able to share the contents of my page on his/her wall I using the following code to achieve this functionality
function fbs_click()
{
u="http://apps.facebook.com/shareddatas/default.aspx/";
t=document.title;
alert(u);
window.open('http://www.facebook.com/sharer.php?u='+encodeURIComponent(u)+'&t='+encodeURIComponent(t),'sharer','toolbar=0,status=0,width=626,height=436');
return false;
}
-->
**
My problem is if in the javascript function fbs_click() if i use u = "http://www"DOT"google"DOT"com" then the google image and google customized content is coming properly but if i assign the value of u = "MYaPP#FACEBOOK" then i just get apps"DOT"facebook"DOT"com on my share.php popup and what ever customized content i want to share across doesn't appear on that
Is there is a way of customizing the share.php for iframe application if not then by what means can i achieve the functionality of sharing the contents available on my page on to my wall
The whole methodology for sharing/liking has changed. I would suggest you convert over to using the new Like Plugin: https://developers.facebook.com/docs/reference/plugins/like/