Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.



HTML
<script type="text/javascript">
  var imageUrls = [
       "https://qnetconfluence.cms.gov/download/attachments/533828942/LACE_events.png?version=1&modificationDate=1707246974813&api=v2"
     , "https://qnetconfluence.cms.gov/download/attachments/533828942/LACE_newmedia.png?version=1&modificationDate=1707246974741&api=v2"
     , "https://qnetconfluence.cms.gov/download/attachments/533828942/LACE_contactus.png?version=1&modificationDate=1707246974921&api=v2"
  ];
 var imageLinks = [
       "https://qnetconfluence.cms.gov/display/LACE/Upcoming+Events"
      , "https://qnetconfluence.cms.gov/display/LACE/Media"
       , "https://hcqis.slack.com/archives/C02Q5HJPBDZ"   
  ];

  function getImageHtmlCode() {
    var dataIndex = Math.floor(Math.random() * imageUrls.length);
    var img = '<a href=\"' + imageLinks[dataIndex] + '"><img src="';        
    img += imageUrls[dataIndex];
    img += '\" alt=\"Jorgesys Stackoverflow.com\"/></a>';
    return img;
  }
</script>
HTML
<script type="text/javascript">
  document.write(getImageHtmlCode());
</script>