Theoreticaly, i thought this could work.....
Posted: Sun Nov 04, 2007 1:25 pm
feyd | Please use
main.txt has "hello" inside it, but instead its giving me "Resource id #3"
can anyone help me make it so it displays the contents of main.txt in the textarea?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
this is index.php, which should open main.txt and display it in a textbox, only thing is, its not displayin it in the textboxCode: Select all
<html>
<body>
<textarea rows="10" cols="30">
<?
$ourFileName = "main.txt";
$fh = fopen($ourFileName, 'r') or die("Can't open file");
echo "$fh"
fclose($fh);
?>
</textarea>
</body>
</html>can anyone help me make it so it displays the contents of main.txt in the textarea?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]