|
-
Jun 10th, 2005, 11:39 AM
#1
Thread Starter
Hyperactive Member
[resolved] How to read a specific line from a file? using php..
If i have a .HTML or .INI or .PHP file on my server, how can i make a .php site that reads a single specific line from that file..
ex:
i have the file INFO.INI containing:
NAME: somename somelastname
ADRESS: somewheres adress
CONTRY: somecountry
MOBILE: somemobilenumber
and then i want a file called ex: READ.PHP
that can read this INFO.INI and pull the info from ex MOBILE into a string called $MOBILE and then create a HTML code containing this info..
ex:
<?php
/some code to get the the MOBILE info from the INFO.INI
echo "<font color=red>" . $MOBILE . "</font>" ;
?>
something like this.. can anyone help me out a little..
hope you guys get what i mean, kinda hard to explain..
Thanks in advance...for any help regarding this.,..
(Cause i have a few domains like www.hfa.no and www.forbruksartikler.no where im to remake a webshops preview system into something quite simpler, but i cant really figure out how to make PHP read from a file this way, but i know that it is possible,cause i've seen it be done other places...)
Last edited by alexdata; Jun 11th, 2005 at 10:12 PM.
Reason: Adding Info..
***************
Please use [highlight=vb] ..your code.. [/highlight] when posting code!
When you have received the working answer to your question,
please mark it as *SOLVED* + Your Questions Title ...using your Thread's Tool menu.
Also try to point out what answer made it work for you, or edit your first post to contain a quote of the correct answer...
Please Answer All Questions With Working Code Examples...
My Unfinished Projects and My working Programs
***************
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|