for my website mobileapps.co which is in php dynamically driven, it is pulling products from the database. I am also running jquery for creating bubble popup for each products.
How can I loop my javascript for all the products, i am using the following code
<ul>
<script>
$(document).ready(function() {
$('.popup0').CreateBubblePopup({
position: 'top',
align: 'center',
innerHtml: '<?php echo $result['
embeddedcode ']; ?><p style="float:left"><?php echo substr($result['
appdesc '], 0, 100); ?><img src="images/rate-off.gif" /><img src="images/rate-off.gif" /><img src="images/rate-on.gif" /><img src="images/rate-on.gif" /><img src="images/rate-on.gif" /></p>',
innerHtmlStyle: {
color: '#FFFFFF',
'text-align': 'center'
},
themeName: 'all-black',
themePath: 'images/jquerybubblepopup-theme'
});
});
</script>
<?php foreach ($fetchapps->arr as $result): ?>
<li id="app-<?php echo $result['appid']; ?>" class="popup0">
<div class="icon">
<a href="app-details.php?result=<?php echo $result['appid']; ?>"><?php echo $result['embeddedcode']; ?></a>
</div>
<p>
<a href="app-details.php?result=<?php echo $result['appid']; ?>"><?php echo substr($result['apptitle'], 0, 15); ?></a>
<span><a href="app-details.php?result=<?php echo $result['appid']; ?>"><?php echo $result['category']; ?></a></span>
<strong><?php if($result['appprice'] != 'free') echo $result['appprice']; ?></strong>
<b><?php if($result['appprice']!='free'){ ?>$.<?php } ?><?=$result['appprice']?></b>
</p>
</li>
<?php endforeach; ?>
</ul>