Kirby Software Forum
April 25, 2018, 09:53:03 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Moved to new web hosting company
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Tip On How To Display A Random Stock Quote Each Day  (Read 1658 times)
Ian Cook
Administrator
Hero Member
*****
Posts: 924



WWW
« on: June 14, 2007, 03:06:29 AM »

Hi
This tip was sent in by Tad.

Tad is using Kirby Alarm Pro to display a random stock quote each day from a list of stock codes.
With his permission I am publishing his idea here in case it may benefit someone else.

Step 1. Copy the specially prepared list into the kirby alarm pro folder
Here is an extract of the list (The full list of over 5000 stock codes can be downloaded from http://www.kirbyfooty.com/randomquotes.zip)
Quote
<!DOCTYPE NETSCAPE-Bookmark-file-1>
<!-- This is an automatically generated file.
It will be read and overwritten.
Do Not Edit! -->
<TITLE>Bookmarks</TITLE>
<H1>Bookmarks</H1>
<DL><p>
    <DT><H3 FOLDED ADD_DATE="1148228432">GREEN INVESTING</H3>
    <DL><p>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=A&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">A</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AA&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AA</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAA&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAA</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAC&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAC</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAI&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAI</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAME&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAME</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAP&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAP</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAPL&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAPL</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAR&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAR</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AATK&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AATK</A>
<DT><A HREF="http://finance.yahoo.com/q/bc?s=AAU&t=1y" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">" ADD_DATE="1165384790" LAST_VISIT="1165384790" LAST_MODIFIED="1165384790">AAU</A>
</DL><p>
<script language="JavaScript">
numlinks = document.links.length
link = document.links.item( numlinks * Math.random() + 1 )
window.location.replace( link )
</script>



Step 2. Create an alarm in Kirby Alarm to call the list.
Here is a screen dump of the alarm settings to display a random stock quote at 10am each weekday.



Naturally Tad's idea can easily be extended to display other random web site etc from a list.

Thanks for the great tip Tad!!

Ian
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!