Click to See Complete Forum and Search --> : news page, can it be done?
drasque
09-17-2003, 11:04 AM
Would it be possible to create a news page where I can just update one file and have the page dynamically update itself w/o the use of asp/cgi/php?
I was thinking of reading from an external file and having it place the information on the page.
And if I can't do it w/o a server side script. Can anyone give me an idea of how to start? What would be the easiest way to go?
Thanks in advance :)
AdamGundry
09-17-2003, 11:19 AM
AFAIK, you do need a server-side script. (You can do something similar in Javascript, but it's not very accessible). I would say SSI was probably the easiest, though PHP is fairly easy and a lot more powerful.
This thread gives the code for SSI and PHP: http://forums.webdeveloper.com/showthread.php?s=&threadid=17207
Adam
drasque
09-17-2003, 12:48 PM
ok, so after I figure out which script to use, would I be able to write a script that would create a new page for each new entry?
say as an example:
adding BIG NEWS to the table and then creating a .../news001.html
or something like that.
b/c having all the news stories on one single file would get rather...dangerous to say the least.
Thanks again, I'm new so i'm learning :)
AdamGundry
09-17-2003, 01:12 PM
I don't quite understand exactly what you want it to do, but a PHP script can create and handle files relatively easily. SSI can do it as well, but it is somewhat more complicated.
Adam
PeOfEo
09-17-2003, 05:32 PM
One thing I use for the news app on my site is ASP.NET it is a nother server side language which means the basic principals it uses are the same as those used by php. What I do is I have a form that you have to login to get to, and when the user enters the new post into that form it is added to a data base. The data from that data base is then displayed on the news page. This basic updating or adding of data is the whole key to server side scripting, accessing data bases and storing data is what makes them so powerful.
drasque
09-17-2003, 10:14 PM
So then once it's entered into the database, does it create a page for each news link? or how does it manage to view all the information that's on the news page?
can you get me off my feet in php? anyone?
thanks :P
PeOfEo
09-17-2003, 10:20 PM
Ok you have one page that adds the data to the data base by means of a form. Then you have a page that connects to the data base and gets the information from it and populates a table. I dont use php so I cant help you there but the code is very common and basic in and ssl.