FutureQuest, Inc. FutureQuest, Inc. FutureQuest, Inc.

FutureQuest, Inc.
Go Back   FutureQuest Community > General Site Owner Support (All may read/respond) > General Coding/Development
User Name
Password  Lost PW

Reply
 
Thread Tools Search this Thread Display Modes
Old 01-17-2002, 04:23 PM   Postid: 60431
Jeepers
Registered User

Forum Notability:
10 pts: User-friendly
[Post Feedback]
 
Join Date: Jun 2001
Location: richmond
Posts: 30
Cron job and mysql data

After being introduced to cron jobs a couple of days ago, I think its the coolest thing.I'm wondering how it may work with mysql data.

Every night, I will input some stock data into a mysql database.
In my webpage, I have a table that fetches the information from my database and displays it in a table format(I use PHP for this).

The problem is, it seems that fetching the data from the database everytime I refresh the webpage is kinda slow.

I have idea as follows :
1)I would have a new page that includes ONLY the php code that fetches the data and displays it in a table format.
2)Then everynight I would use a cron job with the following code :

#!/usr/bin/perl
use LWP::Simple;
mirror ('http://www.mydomain.com/mystock data.php3','tabledata.html');

This html would capture the php output. The reason for the new html page is so that it loads faster because it doesn't have to call up the mysql database.

The question is......How do I grab this mirrored html page and insert it into a portion of another existing webpage?

Any thoughts on this process?
I tried the new html page page and the table loads a lot faster, but I don't know how to insert this table to another page.
Or is there an even easier way?

thanx
Jeepers is offline   Reply With Quote
Old 01-17-2002, 05:09 PM   Postid: 60436
Dunx
Someone who likes orange
 
Dunx's Avatar

Forum Notability:
41 pts: User-friendly
[Post Feedback]
 
Join Date: Apr 2001
Location: Portland, OR, USA
Posts: 770
Server side includes should do the job; there's an AOTA tutorial which should get you started, but basically the command
Code:
<!--#include virtual="/include/test.txt" -->
...should do what you want.
__________________
--
Dunx
Dunx is offline   Reply With Quote
Old 01-18-2002, 12:37 AM   Postid: 60464
Jeepers
Registered User

Forum Notability:
10 pts: User-friendly
[Post Feedback]
 
Join Date: Jun 2001
Location: richmond
Posts: 30
thanx
Jeepers is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 visitors)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 12:10 PM.


Running on vBulletin®
Copyright © 2000 - 2013, Jelsoft Enterprises Ltd.
Hosted & Administrated by FutureQuest, Inc.
Images & content copyright © 1998-2013 FutureQuest, Inc.
FutureQuest, Inc.