Writing to a file?

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   Writing to a file?
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
Im trying to make it make it so that only certian user can upload an image, so they can keep their own gallery, or album. I know the HTML to get the visuals, but what do I do to write to a file?

Here's what I've tried so far...

<?php

$fp = fopen("http://www.ideastream.com/images2004", "w");



fwrite($fp, $testimage);

fclose($fp)


?>


$testimage is the file the user browsed for.
But I don't understand that much..what is $fp? Can someone teach me or tell me a tut or something on how to take the users file from the computer, and put it in a directory on my hosting. Please. lol, I want to be able to MAKE this module. I just need help with the code. Thanks guys.



_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#2   re: Writing to a file?
Gareth
CZ Addict
 Codezwiz Site Donator
Gareth has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Student, Webmaster
Gender: Male
Fav. Sports Team: Liverpool FC
Status: Offline
Joined: May 29, 2004
0.08 posts per day
Posts: 587
Points: 38,220
   
uhhh, i know a tutorial on how to upload if that helps icon_rolleyes.gif icon_mrgreen.gif

icon_arrow.gif Gareth




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#3   re: Writing to a file?
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
tut on uploading...yea can i see it?




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#4   re: Writing to a file?
Gareth
CZ Addict
 Codezwiz Site Donator
Gareth has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Student, Webmaster
Gender: Male
Fav. Sports Team: Liverpool FC
Status: Offline
Joined: May 29, 2004
0.08 posts per day
Posts: 587
Points: 38,220
   
Kelly found this for me:
[ Register or login to view links on this board. ]

thank her icon_mrgreen.gif




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#5   re: Writing to a file?
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
Thanks Kelly!!! That helped me loads. Im working on this module now.




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#6   re: Writing to a file?
Gareth
CZ Addict
 Codezwiz Site Donator
Gareth has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Student, Webmaster
Gender: Male
Fav. Sports Team: Liverpool FC
Status: Offline
Joined: May 29, 2004
0.08 posts per day
Posts: 587
Points: 38,220
   
That is exactly what i said "Thanks Kelly That Helped Me A Lot icon_mrgreen.gif "

We have the same personalitys or something? lol because right after that i started working on a module where you upload stuff, icon_twisted.gif




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum