Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <script>
- //<![CDATA[
- window.onload=function(){
- Date.prototype.toMyString = function () {
- //If month/day is single digit value add perfix as 0
- function AddZero(obj) {
- obj = obj + '';
- if (obj.length == 1)
- obj = "0" + obj
- return obj;
- }
- var output = "";
- output += this.getFullYear();
- output += AddZero(this.getMonth()+1);
- output += AddZero(this.getDate());
- return output;
- }
- var d = new Date();
- var link = document.getElementById("image");
- link.setAttribute("src","http://cache3-img1.pressdisplay.com/pressdisplay/docserver/getimage.aspx?file=6107"+d.toMyString()+"00000000001001&page=1&scale=44");
- var link = document.getElementById("link");
- link.setAttribute("href","http://www.pressdisplay.com/pressdisplay/pageview.aspx?issue=6107"+d.toMyString()+"00000000001001");
- }//]]>
- </script>
- </head>
- <body>
- <center>
- <img id="image" width="200"><br/>
- <a id="link" href="#">Read Today Epaper</a>
- </center>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement