javascript - Displaying Different Pictures For Different Form Results -


i have form in google sites 2 text fields. don't know how retrieve data submitted. there way display different image on web page when specific answer form submitted?

here's have now:

<form action="interactive map"> start room: <input name="startroom" type="text" value="" /> end room: <input name="endroom" type="text" value="" /> <input type="submit" value="submit" /> </form> 

you should have array of images
after form submitted can use random index of array images

sample code

var arrayimglocation = ['img1.jpg','img2.jpg']; var rand = arrayimglocation[math.floor(math.random() * arrayimglocation.length)]; 

Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - .htaccess mod_rewrite for dynamic url which has domain names -

Website Login Issue developed in magento -