homepage Welcome to WebmasterWorld Guest from 54.226.206.205
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
Forum Library, Charter, Moderator: open

JavaScript and AJAX Forum

    
Execute Javascript inside a Javascript ? O.o?
Execute Javascript inside a Javascript
DrHawk




msg:4411771
 1:21 am on Jan 28, 2012 (gmt 0)

Hello everyone! this what im trying to do:

Im using this script [ndoherty.biz...]
its an Ajax Slider simple to use... but i want to display some Google advertisement in one of the panels and like you should know those are display by javascript, so when i place the ads-script inside de slide-script it doesnt work... the question is HOW CAN I RUN THE ADVERTISEMENT SCRIPT INSIDE THE SLIDER SCRIPT?


<!-- Begin JavaScript -->
<script type="text/javascript" src="javascripts/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="javascripts/jquery.easing.1.3.js"></script>
<script type="text/javascript" src="javascripts/jquery.coda-slider-2.0.js"></script>
<script type="text/javascript">
$().ready(function() {
$('#coda-slider-1').codaSlider();
});
</script>
<!-- End JavaScript -->


</head>

<body class="coda-slider-no-js">

<h1>Coda-Slider 2.0</h1>

<div class="coda-slider-wrapper">
<div class="coda-slider preload" id="coda-slider-1">
<div class="panel">
<div class="panel-wrapper">
<h2 class="title">Panel 1</h2>
<p>TEXT 1</p>

</div>
</div>
<div class="panel">
<div class="panel-wrapper">
<h2 class="title">Panel 2</h2>
<p>TEXT2</p>

</div>
</div>
<div class="panel">
<div class="panel-wrapper">
<h2 class="title">Panel 3</h2>
<p>
<script type="text/javascript"><!--THIS IS THE AD!
google_ad_client = "ca-pub-01010101010101010101";
/* footer-ads-posts */
google_ad_slot = "0101010101";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

</p>
</div>
</div>
<div class="panel">
<div class="panel-wrapper">
<h2 class="title">Panel 4</h2>
<p>TEXT 4</p>
</div>
</div>
</div><!-- .coda-slider -->
</div><!-- .coda-slider-wrapper -->

</body>
</html>


 

DrHawk




msg:4411775
 1:49 am on Jan 28, 2012 (gmt 0)

UPDATE!: It is working on Chrome and Firefox but not in Explorer... how can i fix it to make it work on explorer?

DrHawk




msg:4411785
 2:37 am on Jan 28, 2012 (gmt 0)

NEW UPDATE!: Sometimes it does show the google-ads on Internet Explorer... sometimes it doesnt.... or if i reload it doesnt show it anymore after that.... help?

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved