FM Design
Would you like to react to this message? Create an account in a few clicks or log in to continue.

IMPORTANT

FM Design is in read-only mode, please click here for more information.

Latest topics
» Forumactif Edge - Releases
by Ange Tuteur Tue 03 Sep 2019, 11:49

» GIFActif - Giphy Button for the Editor
by Ange Tuteur Wed 08 May 2019, 17:21

» Forum Closure
by Ange Tuteur Mon 01 Jan 2018, 01:28

» Chit Chat Thread
by Valoish Sun 31 Dec 2017, 19:15

» Font/Text background color.
by Valoish Sun 31 Dec 2017, 19:11

» Forumactif Messenger - Instant Message Application for Forumotion
by Wolfuryo Sun 31 Dec 2017, 18:24

» [GAME] Count to One Million!
by brandon_g Fri 29 Dec 2017, 18:58

» Post Cards
by manikbiradar Wed 20 Dec 2017, 07:50

» [GAME] Countdown from 200,000
by Valoish Wed 13 Dec 2017, 23:22

» GeekPolice Tech Support Forums - GeekPolice.net
by Dr Jay Mon 11 Dec 2017, 19:12

» Asking about some plugin for Forumotion
by Dr Jay Mon 11 Dec 2017, 19:10

» [GAME] What are you thinking right now?
by Van-Helsing Sat 09 Dec 2017, 14:51

» Widget : Similar topics
by ranbac Wed 06 Dec 2017, 18:11

» Change the Background of the Forum and put an image and how to make prefixs?
by Clement Wed 06 Dec 2017, 15:19

» Hello from Western Australia
by SarkZKalie Wed 06 Dec 2017, 05:34

Recent Tutorials
Top posting users this month

Who is online?
In total there are 27 users online :: 0 Registered, 0 Hidden and 27 Guests :: 2 Bots

None

[ View the whole list ]


Most users ever online was 515 on Tue 14 Sep 2021, 15:24

[SOLVED] why this code is not matchin in forumotion

View previous topic View next topic Go down

sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 16:23

i want add a responsice bloc size from adsense
Code:
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- hhrhr -->
<ins class="adsbygoogle"
    style="display:block"
    data-ad-client="ca-pub-xxxxx"
    data-ad-slot="xxxx"
    data-ad-format="link"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
the type of code is synchrone

but it does not appear !! why
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Wed 03 Aug 2016, 19:18

Hi @sohab,

I have some questions :

1. Are you placing this in the templates, or somewhere else ? If somewhere else, please specify where.
2. Do any errors appear in your console ? Right Click > Inspect > Console tab
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 19:35

i place the code in html page and template too but it's not workinq and nothing appear !!

http://www.saudijobstoday.net/h4-page
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Wed 03 Aug 2016, 20:07

I see links, is this what's supposed to appear ? or is this the wrong one ?
[SOLVED] why this code is not matchin in forumotion Captur49
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 20:55

noo
i added to ads's bloc and it not appear
SLGray
SLGray
Valued Member
Gender : Male
Age : 51
Posts : 2465
Points : 7347
Reputation : 290
Location : United States
Language : English
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : ModernBB
http://www.fmthemes.forumotion.com https://www.facebook.com/FM-Themes-655055824604957 https://twitter.com/FMThemes https://pinterest.com/FMThemes

PostSLGray Wed 03 Aug 2016, 21:05

What exactly do this code do?

Are you adding your ads to the forum?  If yes, did you remove the default ones by using credits?
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 21:10

SLGray wrote:What exactly do this code do?

Are you adding your ads to the forum?  If yes, did you remove the default ones by using credits?

yes i removed the defaults codes

this code is for bloc responsive adsense
SLGray
SLGray
Valued Member
Gender : Male
Age : 51
Posts : 2465
Points : 7347
Reputation : 290
Location : United States
Language : English
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : ModernBB
http://www.fmthemes.forumotion.com https://www.facebook.com/FM-Themes-655055824604957 https://twitter.com/FMThemes https://pinterest.com/FMThemes

PostSLGray Wed 03 Aug 2016, 21:15

What do you mean by removed old codes?
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Wed 03 Aug 2016, 21:18

Well I tested the code "as is" from your post above and the reason it doesn't work for me is because I don't have the correct data filled in. Did you replace xxxxx and xxxx with the necessary data ?
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 21:26

yes i change it
this is the correct code
Code:
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- grge -->
<ins class="adsbygoogle"
    style="display:block"
    data-ad-client="ca-pub-1087510162742319"
    data-ad-slot="9665344186"
    data-ad-format="auto"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>


<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- htrhtr -->
<ins class="adsbygoogle"
    style="display:block"
    data-ad-client="ca-pub-1087510162742319"
    data-ad-slot="2142077384"
    data-ad-format="link"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Wed 03 Aug 2016, 21:26

theire they are two codeof two bloc ads
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Wed 03 Aug 2016, 21:34

sohab wrote:yes i change it
this is the correct code
Code:
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- grge -->
<ins class="adsbygoogle"
    style="display:block"
    data-ad-client="ca-pub-1087510162742319"
    data-ad-slot="9665344186"
    data-ad-format="auto"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>


<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- htrhtr -->
<ins class="adsbygoogle"
    style="display:block"
    data-ad-client="ca-pub-1087510162742319"
    data-ad-slot="2142077384"
    data-ad-format="link"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

This is the result I get when I add them to an HTML page :
[SOLVED] why this code is not matchin in forumotion Captur50
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Thu 04 Aug 2016, 06:20

yes yes it's work in html page but not in the template ?
why ?
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Thu 04 Aug 2016, 06:23

Try adding a line break between the curly brackets in this line :
Code:
(adsbygoogle = window.adsbygoogle || []).push({});

So you get this :
Code:
(adsbygoogle = window.adsbygoogle || []).push({
});

I think they're being mistaken as variables in the templates without that break.
sohab
sohab

Gender : Unspecified
Posts : 140
Points : 3264
Reputation : 2
Language : frensh
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : phpBB2
http://www.saudijobstoday.net/

Postsohab Thu 04 Aug 2016, 06:33

wow wow wow wow
thanksssssssssssssssssssssssssss heroooooooooooo
you know that this has been more than a year I have this problem the
I do not know how to thank you  [SOLVED] why this code is not matchin in forumotion 1f62d [SOLVED] why this code is not matchin in forumotion 1f622
Ange Tuteur
Ange Tuteur
Administrator
Gender : Male
Posts : 4741
Points : 12255
Reputation : 2376
Location : Pennsylvania
Language : EN, JA, FR
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
https://sethclydesdale.github.io/ https://twitter.com/sethc1995

PostAnge Tuteur Thu 04 Aug 2016, 06:40

You're welcome. Smile

Yes you need to be vigilant with JavaScript in the templates. If you have two curly brackets together like this : {}, forumotion will think that they're a variable and parse them that way -- usually removing them from your JavaScript. You either need to add a line break between them, or call
Code:
new Object()
instead. Wink

Archived
Sponsored content

PostSponsored content

View previous topic View next topic Back to top

Create an account or log in to leave a reply

You need to be a member in order to leave a reply.

Create an account

Join our community by creating a new account. It's easy!


Create a new account

Log in

Already have an account? No problem, log in here.


Log in

 
Permissions in this forum:
You cannot reply to topics in this forum