Current location: Hot Scripts Forums » General Community » Script Requests » Simple Create a file code


Simple Create a file code

Reply
  #1 (permalink)  
Old 01-23-05, 05:31 AM
ancdy ancdy is offline
Newbie Coder
 
Join Date: Jan 2005
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Simple Create a file code

Hi,

I'm looking for a piece of (probably PHP) code, which does the following:

Information is typed in by the user in a online form. Such as name, etc
Also 2 music files are uploaded and 2 image files are uploaded by them.
When they press submit, i need to have it automatically create a folder (unique folder, so each user who has filled in the form has their own folder) in that directory, and save the files uploaded into this folder, as well as saving the information submitted into a text file.

Any ideas? Anyone got any code similar to this?

Many Thanks!
Reply With Quote
  #2 (permalink)  
Old 01-24-05, 03:09 AM
SwitchBlade SwitchBlade is offline
Newbie Coder
 
Join Date: Jan 2005
Posts: 51
Thanks: 0
Thanked 0 Times in 0 Posts
OK well that is very simple. Instead of me explaining it all go to php.net and lookup the following functions:

mkdir()
fopen()
fwrite()
fclose()
Reply With Quote
  #3 (permalink)  
Old 01-24-05, 11:02 AM
phprogramming phprogramming is offline
Wannabe Coder
 
Join Date: Nov 2004
Posts: 214
Thanks: 0
Thanked 0 Times in 0 Posts
dont listen to switch blade, pm me and i can do this, its easy, but u will need to change the max upload size in your php.ini file if accessible because at default its only 2MB and that is not always enough to upload songs, switchblade, tell me how u can write a music file and a image file to another file, and i am not sure if its possible, but do u mean use fwrite to write a file to the server? that would be ridiculous even if possible, anyway, pm me ancdy
__________________
Source Code Talk - Programming Discussion, Tutorials, and More!
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP code to edit a text file mdhall Script Requests 12 12-23-10 04:03 AM
Create an index with Asp.net-vb code kathryn ASP.NET 0 01-04-05 08:39 AM
pull code from a file nassau PHP 4 10-03-04 10:18 PM
Declared Functions skipper23 PHP 4 12-17-03 10:06 AM
index page not showing up skipper23 PHP 3 12-15-03 01:10 PM


All times are GMT -5. The time now is 10:58 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.