(Solved) Please help: populate array() from text file?
Posted: Wed Aug 03, 2005 11:11 am
Hi everyone. This is my first post. I am two weeks old in my exposure to & learning PHP and I am absolutely excited at the possibilities!
However, I've run into a problem. Well, not really a problem. Just a question of efficiency.
Background history: I have a customer who wants to minimize - AS MUCH AS POSSIBLE! - the risk of inadvertently screwing up the code that builds her pages. So, in light of that, I wanted to be able to populate the array from an external text file instead of having to prepopulate the field thus:
She would be the one building the text file where the input would simply be something along the lines of a shopping list:
and have that file populate the array.
Rather than bug folks, I've searched, googled, and re-searched until I am ready to throw in the towel. I am probably not using the correct search parameters or understanding the material I've read.
Is there somewhere a prepackaged code that I can follow until I gain more experience coding PHP myself?
Thank you in advance.
However, I've run into a problem. Well, not really a problem. Just a question of efficiency.
Background history: I have a customer who wants to minimize - AS MUCH AS POSSIBLE! - the risk of inadvertently screwing up the code that builds her pages. So, in light of that, I wanted to be able to populate the array from an external text file instead of having to prepopulate the field thus:
Code: Select all
$filename = array('index','contact','thisfile','thatfile',);Code: Select all
index
contact
thisfile
thatfileRather than bug folks, I've searched, googled, and re-searched until I am ready to throw in the towel. I am probably not using the correct search parameters or understanding the material I've read.
Is there somewhere a prepackaged code that I can follow until I gain more experience coding PHP myself?
Thank you in advance.