Hi,
I am new to php and i am try to find out, if it is possible to use php to get live stock quotes similiar to finance.yahoo.com. where the bid and ask prices changes without refreshing the page.

Can somone show me a working example of a live stock quote list or a link on how to do that using php from any kind of database that gets updated every few sec.

Thanks
-Newbee

    Regardless of how you end up doing this, you are going to need a source for real-time stock prices. Perhaps Yahoo has an RSS feed?

    As far as YOUR php site updating frequently, you can try a few approaches
    1) create an iframe on your page that reads your data source and has a meta refresh tag so that it updates itself every 5 seconds or something
    2) Create an AJAX script that reads your data source
    3) Use Flash to read your data source.

    A database is probably not necessary for this...you just need to find a data source you can use and that will dictate what approach you need to take.

      Thanks Guys for the input.
      I have a soruce databse that will provide the data.

      I want to use ajax for live update of the data without refreshign the page, similiar to yahoo finance(http://finance.yahoo.com/q?s=goog) or marketwatch.

      Is there a working examples that I can use to build this using php or is it all possible building this using php? Since most sites i come acrossed were built using java servlet.

      Thanks for your help in advance.

      Kind Regards
      Newbee

        If you have a database then there's no need for real time updates is there?

          There is a need to show the latest content in the database since the database is updated every second with new date.
          So inorder to display the updated data from the database I need to refresh the page and I want to avoid refreshing it by clicking the refresh button or use the metadata.

          I was tryign to use ajax with php to show the changes realtime similair to this link yahoo finance(http://finance.yahoo.com/q?s=goog) where the cell is updated every second without refreshign the page and was wonderign if there is workgin example for that using php or is it possible?

          Thanks
          Regards

            Write a Reply...