lundi 29 juin 2015

random picture script for new app

I am creating an app through AppMaker and I want a random picture to appear when someone clicks the icon. I found a script online (I am a newby to scripts and don't understand much of it. So I will need assistance). I entered the script in (where they accept html on a screen) and it doesn't seem to run when I test it. I created several test pictures and uploaded them to my online site and then ran this script. I have asked for tech support from the company and they have escalated the issue to higher tech support. Its been about a week and no one is getting back to me. Any help would be appreciated.

The script is as follows:

`<script type="text/javascript">
var total_images = 2;
var random_number = Math.floor((Math.random(2)*total_images));
var random_img = new Array(3);
random_img[0] = '<ahref="http://ift.tt/1KkyqoE"><img src="
images/Tarot1.jpg"></a>';;
random_img[1] = '<a href="http://ift.tt/1FKsO0D"><img src="
images/Tarot2.jpg"></a>';;
document.write(random_img[random_number]);
</script>`

Thank you so much for your assistance and patience with me as again, I am new to this.




Aucun commentaire:

Enregistrer un commentaire