Jump to content

[SOLVED] Ok so I rewrote my question/problem to make it more clear


prcollin

Recommended Posts

Basically i have a form and below it (on the code side not display side) i have an html document.  The variables in the html document are reflective of what is entered in the form

 

So say i have a text box <input type="text" name="title">

Then I set that $title = 'title'

IN the html portion of the form there is a place for the title of the site

 

<title> $title </title>

 

And the whole html document is refelctive of what the user enters. 

 

SO i have all that working and when they click submit it sends me an email with all of hte correct code and user inputs form the form.  Right now I have to take the code, place it in a notepad, save it as .html or .php then upload it to my server.

 

Is there an easy way to just have the new file created just post to the server as a .html or .php?  Each time a user signs up I want the new information to post to a new directory and save itself as a new .html or .php file

mkdir(foldername to be created) makes the folder

you can trigger it on submission

 

if you want a file in the folder, make sure you keep the folder name

and just

$filetosave = fopen($folder.$filename,'w');
fclose($filetosave); 

 

to save it

and you're done

mkdir(foldername to be created) makes the folder

you can trigger it on submission

 

if you want a file in the folder, make sure you keep the folder name

and just

$filetosave = fopen($folder.$filename,'w');
fclose($filetosave); 

 

to save it

and you're done

 

 

Thank you very much

mkdir(foldername to be created) makes the folder

you can trigger it on submission

 

if you want a file in the folder, make sure you keep the folder name

and just

$filetosave = fopen($folder.$filename,'w');
fclose($filetosave); 

 

to save it

and you're done

 

one more question.  If there is no file with that name already in the directory it will just create a new one with it right?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.