Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

reading from a text file randomly

Status
Not open for further replies.

xeonaphobe

Programmer
Jan 21, 2005
1
GB
Hi,

I'm currently creating an extremely basic blog using PHP (although i'm not quite ready for any MySQL trickery yet!). I want to store my entries in a text file, and be able to call up whichever entry i wish to view. I was wondering if there was a way i could set different points in the text file and then read in which ever entry i choose into a variable by referencing these points (ie random access). Is this possible in php?
Hope that made sense, i'm a bit tired as i've been working on this blasted thing for hours. Any advice, examples or even a URL which will help me out would be fantastic.

Cheers!
Neil
 
My advice, use MySQL. It's not trickery. It will do what you want without a lot of jumping through hoops.

Ken
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top