Jump to content

RSS and PHP


Traces

Recommended Posts

This is probably a pretty odd question but hopefully an easy one.  Don't worry, I don't want anyone to write a script for me or anything like that, I have a friend that does php and can do all the dirty work, we are just stuck on a couple of things.

Basically this is what I am trying to do...  I have a site hosted by godaddy with php, a program on my computer is outputting a html file every 5 minutes with data, the data is uploaded via ftp every 5 minutes automatically to the website.  What I want to do is have a RSS feed dynamically created with parsed information from the data file.  So after some calculations by the php script I get a concise output which makes my life a little easier since I don't have to do it by hand.  Why an RSS exactly?  I *always* have my personalized google page open which is filled with RSS feeds.  Basically all I would have to do is glance at the RSS feed and have everything done for me as I kept an eye on it.  For the clarification I would just be using the RSS feed as a way to display the dynamic results from the data.

So: raw data > data.html every 5 minutes > data.html uploaded to website every 5 minutes > php parses and works it's magic every 5 minutes > php creates a dynamic rss feed with parsed info every 5 minutes

Here is the problem though.  How do sites keep their xml files dynamically updated?  I know it can be done by hand of course but as you can see that wouldn't work for me.  Making php do this is easy, once.  But making it automagically update the xml file?  I did some research (I am not a programmer) and crontab is what I want but godaddy doesn't support this for shared hosting plans.  I could always setup a unix box here locally and have it upload the finalized xml file, which would seem like the better route here but that is quite a bit of work for me as I am not familiar with anything other than windows.  Honestly I *really* don't want to go that route.  Is there another way of doing this by using PHP?  Do the programming gurus think I am doing this ass backwards and have a more elegant solution?

I know you guys get a -lot- of requests for help but like I said before I don't need anyone to write a script, I am just at an impass.  If you guys can clarify the path for me google and my friends php skills can take over from there.  Thanks guys.

Oh and I don't know if this helps but the server API is CGI/FastCGI
Link to comment
Share on other sites

I doubt that you will be able to do what you need to do a godaddy hosting account, just because you don't access to the server settings to do this the "easy way".

The easy way is to change your server settings to tell the server that a .xml file extension is allowed to parse PHP code, and you just use the PHP to parse out the correct XML syntax. Each time the page is loaded, the PHP exectues and checks for updates and automatically outputs those changes to the XML. That is the easiest way to do that, but again, I don't think that Go Daddy is going to allow you to do that on a shared server.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.