| |||||||||||
| |||||||||||
PHP, Basic flat file shout box HELP Posted by Dbyte (Dbyte), 17 May 2007 Firstly i'd like to say i dont know more than really basic php, But i have a friend who loves php and he's very sick latly so i was hoping some one here could help me with his code... its spread across three files first one is index.php I could send you the files if you wish just email me digimbyte _at_ gmail _dot_ com Code:
shout.php Code:
the other part is the text file at url 'shout/shout.txt' to see how it looks now go to (some times the images don't load properly, I have no idea why) http://dbyte.icshost.org/ the text files url is http://dbyte.icshost.org/shout/shout.txt the php writes in the file fine but the div doesn't read it for some reason all i get is 'Resource id #3' thanks in advanced Posted by admin (Graham Ellis), 17 May 2007 Quote:
The code above opens a file for append, then prepares it for output ... however, it's just the file handle. To read a file, you need to use "r" rather that a in your fopen, then use an fgets (or something similar) to actually read the data. This page is a thread posted to the opentalk forum
at www.opentalk.org.uk and
archived here for reference. To jump to the archive index please
follow this link.
|
| ||||||||||
PH: 01144 1225 708225 • FAX: 01144 1225 793803 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho |