|
|||||||
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
#1 |
|
Barefoot on the Moon!
Staff
Premium Member
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,385
|
Displaying random lines from a *.txt on a webpage
I'm looking for a way to display random (or ordered, doesn't matter) lines of text from a text file on a webpage. I've seen it done before and was wondering how it could be done.
__________________
There are two secrets to staying young, being happy, and achieving success. You have to laugh and find humor every day, and you have to have a dream.
|
|
|
|
|
|
#2 |
|
Barefoot on the Moon!
Staff
Premium Member
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,385
|
*bumpity bump*
|
|
|
|
|
|
#3 |
|
Barefoot on the Moon!
Staff
Premium Member
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,385
|
Any suggestions? What languages could I accomplish this with?
|
|
|
|
|
|
#4 |
|
Registered User
Join Date: Nov 2001
Posts: 1,965
|
Hi force_flow2002,
I wonder if it's possible in JavaScript, but I prefer to do it server-side, so if your host supports PHP, read on! PHP Code:
|
|
|
|
|
|
#5 |
|
Barefoot on the Moon!
Staff
Premium Member
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,385
|
I suspected it would be done with some server-side language. Rats. That and Flash are my great webpage weaknesses.
![]() Thanks anyway, aym_7 |
|
|
|
|
|
#6 |
|
Member (8 bit)
Join Date: Jan 2004
Location: europe
Posts: 172
|
i have seen something very similar with javascript. check out javascript.internet.com
|
|
|
|
|
|
#7 |
|
Member (8 bit)
Join Date: Jan 2004
Location: europe
Posts: 172
|
|
|
|
|
|
|
#8 |
|
Registered User
Join Date: Nov 2001
Posts: 1,965
|
tips here are hardcoded into the page and not saved to a separate txt file.
|
|
|
|
|
|
#9 |
|
Barefoot on the Moon!
Staff
Premium Member
Join Date: Aug 2002
Location: Northeastern USA
Posts: 13,385
|
Thanks anyway guys. I managed to find out how to do it.
Thought this thread was long dead
|
|
|
|
|
|
#10 |
|
Registered User
Join Date: Nov 2001
Posts: 1,965
|
so how did you do it? JavaScript? PHP? Or something else?
and it's not me, bmrmrb summoned the thread back to life
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|