Results 1 to 3 of 3

Thread: Help with random image link on click .

  1. #1
    Join Date
    Mar 2014
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Help with random image link on click .

    Pls help me find the script for random image link by click on this image.
    like below website : doremonche. com
    I intend to use in blogger. Thank you.

  2. #2
    Join Date
    Apr 2008
    Location
    So.Cal
    Posts
    3,643
    Thanks
    63
    Thanked 516 Times in 502 Posts
    Blog Entries
    5

    Default

    Have you looked for one yet? There are a huge number of such scripts available.
    If you are having trouble finding what you need, please describe what you want in more detail.

    Also,
    Please do not create more than one thread for your topic. Sometimes, legitimate posts get caught in our spam filter and must be approved by a moderator before they appear on the site. We usually find and review these within a few hours, so please be patient —your post will appear! Posting again only creates delays and more work for us.


    Welcome to DynamicDrive!

  3. #3
    Join Date
    Mar 2014
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thank you sir,
    I understand the rule now.
    for the script, i use below script with my blogspot blog but it did not work . pls advice.
    Code:
    <script language="JavaScript">
    <!--
    
    /*
    Random Image Link Script- By JavaScript Kit(http://www.javascriptkit.com) 
    Over 200+ free JavaScripts here!
    Updated: 00/04/25
    */
    
    function random_imglink(){
    var myimages=new Array()
    //specify random images below. You can have as many as you wish
    myimages[1]="image1.gif"
    myimages[2]="image2.gif"
    myimages[3]="image3.gif"
    myimages[4]="image4.gif"
    myimages[5]="image5.gif"
    myimages[6]="image6.gif"
    
    //specify corresponding links below
    var imagelinks=new Array()
    imagelinks[1]="http://www.javascriptkit.com"
    imagelinks[2]="http://www.netscape.com"
    imagelinks[3]="http://www.microsoft.com"
    imagelinks[4]="http://www.dynamicdrive.com"
    imagelinks[5]="http://www.freewarejava.com"
    imagelinks[6]="http://www.cnn.com"
    
    var ry=Math.floor(Math.random()*myimages.length)
    if (ry==0)
    ry=1
    document.write('<a href='+'"'+imagelinks[ry]+'"'+'><img src="'+myimages[ry]+'" border=0 id="image"></a>')
    }
    random_imglink()
    
    function openWin(){
    	var w = window.open("","","height=400,width=500");
    	w.document.write ("<html>\n<head>\n<title>Popup Document</title>\n</head>\n<body>\n");
    	w.document.write ("<img src='" + document.getElementById('image').src + "' border='0'>");
    	w.document.write ("\n</body\n</html>");	
    	w.document.close();
    }
    //-->
    </script>
    
    <p align="center"><font face="arial" size="-2">This free script provided by</font><br>
    <font face="arial, helvetica" size="-2"><a href="http://javascriptkit.com">JavaScript
    Kit</a></font></p>

Similar Threads

  1. Random image on click script
    By james438 in forum JavaScript
    Replies: 4
    Last Post: 11-29-2009, 10:47 PM
  2. Image, text and link in random order in a table
    By Bornfree in forum Looking for such a script or service
    Replies: 6
    Last Post: 11-23-2008, 10:32 PM
  3. Random image - link target
    By matt punga in forum JavaScript
    Replies: 8
    Last Post: 05-09-2008, 04:27 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •