|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Howdy there.
I was wondering if anyone was able to help me out with PHP. I'm just a beginner, and I was wondering how you make a php script write information. Say a user submits a form, how do you make php create a file, and then print the info the user sent on the file? Also, many people told me to check: PHP Code:
or something like that out. When I go there, though, there's this huge bunch of tables with many commands that I have no idea on how to use. Please either email me to darkangel0203@cs.com or reply to this thread with any help you can give me, I would greatly appreciate it. Cheers |
|
#2
|
|||
|
|||
|
Hi THere
I know nothing about PHP - but I came across a site recently where you may find the help you need: http://www.php.net Seems like a good site to me... Good luck! Robin |
|
#3
|
|||
|
|||
|
Thanks
Hi,
Thanks, but I already figured it out. Cheers |
|
#4
|
|||
|
|||
|
phpinfo() rules although it won't help you create files :-) You stated you figured it out but jic here are some words :
phpinfo spits out a bunch of information, let's say you stick your phpinfo code in a file called info.php then call it like : info.php?bread=rye&butter=no Somewhere in there you may see reference to $HTTP_GET_VARS so if you do : print $HTTP_GET_VARS['bread']; // prints rye print $HTTP_GET_VARS['butter']; // prints no Usually the register_globals setting in php.ini (php configurations) is ON and if so, then $bread and $butter can also be used (you'll see register_globals somewhere in info.php and it'll tell you if it's on or off). Anyway, that's what people mean by saying "see phpinfo()" as you'll see other predefined variables such as PHP_SELF in there, and what they'll output, and all kinds of info. Play with it for awhile. Regarding writing files, see fopen() and fwrite(). |
![]() |
| Viewing: Dev Shed Forums > Other > Beginner Programming > PHP Help |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|