Adsense's ad code doesn't work for my blog - adsense

i have google adsense Account which is activated already.
Now, i am going to place an AD on my blog and i added code into my blog but don't know why i am not able to see that AD on my blog
please help me out !!
Here is My Ad Code :
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<ins class="adsbygoogle"
style="display:block"
data-ad-client="ca-pub-9307704483757505"
data-ad-slot="2264250676"
data-ad-format="auto"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
Thanks

Related

Adsense - We found that your site is down or unavailable

It's my first time to try adsense in a site I made from scratch
I tried to add adsense to my website over 10 times and everytime it says:
We found that your site is down or unavailable:
And the code provided is already in the <head></head> section of the website
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<script>
(adsbygoogle = window.adsbygoogle || []).push({
google_ad_client: "ca-pub-2733350805802981",
enable_page_level_ads: true
});
</script>
website : https://www.a3traf.com

I'm getting spam when I load //pagead2.googlesyndication.com/pagead/js/adsbygoogle.js

When I load <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>, images on my page get replaced with spam ads of all kinds.
I'm testing bare bones in a guest instance of chrome on my pc.
This is the original code:
<html>
<head>
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
</head>
<body>
<img src="/images/ads/mm-mug-wide.jpg" />
</body>
</html>
These are screen shots of the network log with and without the adsense javascript. By the time I killed it, the network log with adsense showed 455 requests over 35 minutes.
With Adsense Javascript: https://18103791804392046531.googlegroups.com/attach/1841b7c6b6b0b5/adsense-network-log-with-adsense.jpg?part=0.3&view=1&vt=ANaJVrFCJMUV-pol5F7XFKcts8bc50qnvFbazg6PVlZXCOCj7PSJXGBJQkoZaU9AzQcs7xh0VS03Q8-pCS9c9iErGlhHCP3mkSWUMeMumfeQPkKkWpanUDU
Without Adsense Javascript: https://18103791804392046531.googlegroups.com/attach/1841b7c6b6b0b5/adsense-network-log-without-adsense.jpg?part=0.2&view=1&vt=ANaJVrHGcOCztReWJmK09Yr0YpkouhCZwxFzmmjfRfk2wyB0Rr9vb30Hl7SkanKF06LcCCxDvElQx4tB_ZQYRxB-96zOY8gXEp_IjL6q6pOzlsSuA4-nQZ8
UPDATE:
It only seems to do it if the word 'ad' or 'ads' ('header' was not a match) appear in the src. If the class is 'ad', it starts loading the spam resources but does not replace the image or continue on indefinitely.
The DNS on my router had been altered to point to a malicious DNS that was rerouting things such as google adsense.
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<script>
(adsbygoogle = window.adsbygoogle || []).push({
google_ad_client: "ca-pub-6483687610557857",
enable_page_level_ads: true
});
</script>

Custom Dimensions Dynamically Assigned When Presenting Ad

I have a web page that is linked to by partners with a URL pattern like so:
mydomain.com?partner=1
I would like to be able to view reports on ad revenue generated by adsense per partner id for revenue sharing purposes. Is there a way for me to provide the partner id to the adsense integration code so that later I can correctly attribute revenue to the appropriate partners?
Perhaps something like this written in on the server side?
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<ins class="adsbygoogle"
style="display:block"
data-ad-client="xxxxxxx"
data-ad-slot="xxxxx"
data-ad-format="auto"
<!-- SEE BELOW -->
data-custom-dimensions="<?=PUBLISHER_ID?>"
<!-- SEE ABOVE -->>
</ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

How can I register facebook users on my site ?

I am trying to find a walk through on how to register users via facebook onto my site.
The facebook developers site keeps confusing me and I was hoping there where easier tutorials to follow.
Stephen,
It can be a little complicated.
You have to combine the documentation at:
http://developers.facebook.com/docs/guides/web/
http://developers.facebook.com/docs/plugins/registration/
Boiling it down to the simplest case:
<html>
<head>
<title>My Facebook Registration Page</title>
</head>
<body>
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js">
</script>
<script>
FB.init({
appId:'yourAppID', cookie:true,
status:true, xfbml:true
});
</script>
<fb:registration
fields="[{'name':'name'}, {'name':'email'},
{'name':'favorite_car','description':'What is your favorite car?',
'type':'text'}]" redirect-uri="Your processing URL">
</fb:registration>
</body>
</html>
Facebook will return an encrypted form field with all the user data called "signed Request" You will need to decrypt this field with your secret key. There is an PHP example at the bottom of http://developers.facebook.com/docs/plugins/registration/

Resume FB Connect session

i am using FB Connect on my site and i am able get & store offline access session key in DB.
My question, i need to display the multiple friend selector form even if there is no FB connect session.
How can i force it to resume/create the session i have in DB, so i can display friends in the below form.
Since i already got extended permissions, I must not ask them for login again. please help
require_once 'config.php';
$user = "1294712371";
$session = "827466297c301f2cc6b581ce-1294712371";
?>
<fb:serverfbml style="align:center;">
<script type="text/fbml">
<fb:fbml>
<fb:request-form
action="test.php"
method="POST"
invite="true"
type="dot.com"
content="Come and join me"
<fb:req-choice url='see wiki page for fb:req-choice for details'
label='Join Me' />
<fb:multi-friend-selector showborder="false"
actiontext="Invite your friends">
</fb:request-form>
</fb:fbml>
</script>
</fb:serverfbml>
<script src="JS/FeatureLoader.js" type="text/javascript"></script>
<script type="text/javascript">
FB_RequireFeatures(["XFBML"], function()
{
FB.init('appapikey', "xd_receiver.htm");
});
</script>
Currently the above code shows no friends at all when there is no FB connect loggedin sesstion
You could use set_user method from the php client library
$facebook = new Facebook(API_KEY, API_SECRET);
$facebook->set_user($user, $session);