Jump to content

Create File In Directory


Warptweet

Recommended Posts

Hi there, I use this code to make a file...

[code]<?php
$o = fopen($_POST['uploadedfile'].".txt", "w");
fclose($o);
?>[/code]

How can I make it so that the file is created in the /flashportal/uploads directory?
If its impossible to choose which directory to create a file in, how can I MOVE the file into a directory?

SECOND QUESTION:
Is it possible to write HTML code or PHP code onto a file? If so, how?
Link to comment
https://forums.phpfreaks.com/topic/33844-create-file-in-directory/
Share on other sites

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.