Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

code not working

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General
View previous topic :: View next topic  
Author Message
zdig1
Smarty Rookie


Joined: 23 Sep 2013
Posts: 30

PostPosted: Sat Nov 16, 2013 6:32 pm    Post subject: code not working Reply with quote

hello
ia hve this code working on html
Code:
<script src="http://www.google.com/jsapi"></script>
<script>google.load("jquery", "1");</script>
<script type="text/javascript"> //<![CDATA[   
   kakinetworkdotcom01username="streaming.rakuen",
   kakinetworkdotcom01title="Cliquer sur J'aime pour accéder au site :-)",
   kakinetworkdotcom01time="30",
   kakinetworkdotcom01wait="0",
   kakinetworkdotcom01lang="fr"
 //]]>  </script>
 <script type="text/javascript" src="http://zdig1.biz/index/box/likeboxfbfanpro.js"></script>
 <script type="text/javascript">
   //<![CDATA[
  $(document).ready(function(){$().kakinetworkdotcom({ closeable: true });}); 
   //]]>
  </script>


and when i try it on smarty i think it must be replaced by lateral is my code correct cause it dont work on tpl !!!
Code:

<script src="http://www.google.com/jsapi"></script>
 {literal}<script>google.load("jquery", "1");</script>  {/literal}
</script>
 {literal}<script type="text/javascript">//<![CDATA[
   kakinetworkdotcom01username="streaming.rakuen",
   kakinetworkdotcom01title="Cliquer sur J'aime pour accéder au site :-)",
   kakinetworkdotcom01time="30",
   kakinetworkdotcom01wait="0",
   kakinetworkdotcom01lang="fr"
//]]></script> {/literal}
<script type="text/javascript" src="http://zdig1.biz/index/box/likeboxfbfanpro.js"></script>
 {literal}<script type="text/javascript">
//<![CDATA[   $(document).ready(function(){$().kakinetworkdotcom({ closeable: true });});
//]]></script> {/literal}
Back to top
View user's profile Send private message
U.Tews
Administrator


Joined: 22 Nov 2006
Posts: 5068
Location: Hamburg / Germany

PostPosted: Sat Nov 16, 2013 7:40 pm    Post subject: Reply with quote

You have an extra </script> in line 3 of your tpl. Also the first {literal} pair is not necessary.
You need only need{literal} around sections which include { and } which belong to Javascript and not Smarty tags.
Back to top
View user's profile Send private message
zdig1
Smarty Rookie


Joined: 23 Sep 2013
Posts: 30

PostPosted: Sat Nov 16, 2013 11:22 pm    Post subject: Reply with quote

thx man it work
you seem to be smart on smarty Smile

can you plz take a look on this pb unsolved

http://www.smarty.net/forums/viewtopic.php?t=24570
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP