...

View Full Version : Resolved PHP directory copy?



slappyjaw
03-19-2009, 04:25 AM
Hey everyone, i was wondering if someone could help me with my website. I am not advanced in php coding. I am tring to make a site like freewebs. i can do everything but the part where someone creates a site. I might be trying to do this wrong but what i did is i tried to make it so that when someone enters the name of their site it duplicates a folder that has the template in it and then renames it to the name of their site, WELL IT DOESNT WORK. so if anyone could give me some help that would be sick. Thanx.:) Also i will put you in the site credits page cause you helped. Thnx again:)

djm0219
03-19-2009, 01:22 PM
Show us the code that you have tried that isn't working as you expect it to.

slappyjaw
03-19-2009, 08:12 PM
Thanks for the reply. The code did not work because i was tring to copy a folder. But mainly i was wondering if there was easier way to make a page and put iti n a specified folder. This is my code::confused:


<?php
$sitename = $_POST['sitename'];
mkdir("C:/xampp/htdocs/clansites/".$sitename, 0777);
copy("C:/xampp/htdocs/includes/clansite/templates/shelld", "C:/xampp/htdocs/clansites/".$sitename);
?>
That's all i have and most of it is either wrong or it isnt the way itproably should. There are nor error messages and there are no if's or and's. Thanks for any help.:thumbsup:

sea4me
03-19-2009, 11:26 PM
I think you have to do it for every file not directory....

You can get the files in the directory and do a loop for each of the files...... :thumbsup:

Fou-Lu
03-19-2009, 11:31 PM
I don't believe that PHP has a multiple copy command. I have no idea why it doesn't.
Here's what you do, create the folder with the mkdir, which is what you're doing.
Then, you can use a glob or scandir command to read through the files in the templates directory, and run a copy command on each file to copy it to the newly created directory.

With what you have there, the copy is probably failing since you haven't specified the new name for the file. I'm pretty sure copy needs an actual filename, and not just the path. This is why a glob/scandir method is recommended.
If the folder is created and the file is not copied over (after the corrections), I'd suspect that the problem is with file permissions on the shelld or templates directory. If it can't be read, it can't be copied, so you'd have to make sure that you're user has at least read privileges.


Sea4me snuck in there ;)
I see what you mean there, so I have to ask is the shelld supposed to be a file or directory?

sea4me
03-19-2009, 11:37 PM
Sea4me snuck in there ;)
I see what you mean there, so I have to ask is the shelld supposed to be a file or directory?


Yes I did :D but you get the credit since you wrote more and also explained it better :thumbsup:

slappyjaw
03-20-2009, 02:11 AM
Yes it is a directory. Thank you both for the help. I will make the corrections. I will deff give you both credit for the help.

slappyjaw
03-20-2009, 04:57 AM
Greate so i still need your help:


<?php
$sitename = $_POST['clanname'];
$admin = $_POST['uname'];
$password = $_POST['password'];
$dirdest = "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename;
$dirsource = "D:/hshome/rubygirl58/gameparody.com/templates/shelld";
COPY_RECURSIVE_DIRS($dirsource, $dirdest);
function COPY_RECURSIVE_DIRS($dirsource, $dirdest)
{ // recursive function to copy
// all subdirectories and contents:
if(is_dir($dirsource))$dir_handle=opendir($dirsource);
mkdir($dirdest, 0755);
while($file=readdir($dir_handle))
{
if($file!="." && $file!="..")
{
if(!is_dir($dirsource."/".$file)) copy ($dirsource."/".$file, $dirdest."/".$file);
else COPY_RECURSIVE_DIRS($dirsource."/".$file, $dirdest);
}
}
closedir($dir_handle);
return true;
}
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/headers", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib", 0755);

copy("D:/hshome/rubygirl58/gameparody.com/templates/images/background.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/copyright.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/footer_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_end.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/header.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_normal.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/welcome.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/news/soldier.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news");
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/team", 0755);
?>

The script doesnt copy the image files. Can you tell me whats wrong. Do i need an opendir synax? thanx for the help!

Fou-Lu
03-20-2009, 05:06 AM
You're copy command still doesn't list the new filename in it.
ie:


copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav");


This is missing the forums_hover.jpg in the destination directory, or you could rename it to something different.

slappyjaw
03-20-2009, 06:03 PM
OH OK. haha sorry. Thnx.

slappyjaw
03-21-2009, 05:12 PM
ok one last problem i was wondering if anyone could fuse these two scripts to gether so that i can have a self submitting form. So i dont have to change the page.


<?php
$submitted = $_POST['createclan'];
if (isset($submitted)) {
$sitename = $_POST['clanname'];
$admin = $_POST['uname'];
$password = $_POST['password'];
$dirdest = "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename;
$dirsource = "D:/hshome/rubygirl58/gameparody.com/templates/shelld";
COPY_RECURSIVE_DIRS($dirsource, $dirdest);
function COPY_RECURSIVE_DIRS($dirsource, $dirdest)
{ // recursive function to copy
// all subdirectories and contents:
if(is_dir($dirsource))$dir_handle=opendir($dirsource);
mkdir($dirdest, 0755);
while($file=readdir($dir_handle))
{
if($file!="." && $file!="..")
{
if(!is_dir($dirsource."/".$file)) copy ($dirsource."/".$file, $dirdest."/".$file);
else COPY_RECURSIVE_DIRS($dirsource."/".$file, $dirdest);
}
}
closedir($dir_handle);
return true;
}
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/headers", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/team", 0755);

copy("D:/hshome/rubygirl58/gameparody.com/templates/images/background.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/background.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/banner.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/copyright.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/copyright.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/footer_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/footer_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/head_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_end.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/head_end.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/banner.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/header.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/header.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/nav_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_normal.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/nav_normal.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/news.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/team.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/welcome.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/welcome.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/contact.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/contact_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/forums.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/forums_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/homepage.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/homepage_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/media.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/media_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/news.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/news_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/results.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/results_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/scene.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/scene_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/team.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/team_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/news/soldier.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news/soldier.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/css-reset.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/css-reset.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/ie6.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/ie6.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/roster.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/roster.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/web.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/web.css");
echo '<meta http-equiv="refresh" content="1;URL=<?php echo "http://www.gameparody.com/clansites/$sitename";?>"/>';
}
?>



<form action="<?php echo $_SERVER['PHP_SELF']?>" method="post" name="Form" id="Form">
<div class="content22">
<p class="style3">All fields are required!</p>
<table width="100%" border="0">
<tr>
<td width="41%"><div align="right"><span class="style10">Name of clan site:</span></div></td>
<td width="59%"><label>
<input name="clanname" type="text" id="clanname">
</label>
<span class="style7">(Will be URL of site) </span> </td>
</tr>

<tr>
<td><div align="right" class="style10">Admin Username:</div></td>
<td><label>
<input type="text" name="uname" id="uname">
</label> </td>
</tr>
<tr>
<td><div align="right" class="style10">Admin Password:</div></td>
<td><label>
<input type="text" name="password" id="password">
</label> </td>
</tr>
</table>
<p>
<label>
<input name="createclan" type="submit" id="createclan" value="Create">
</label>
<label>
<input name="reset" type="reset" id="reset" value="Reset">
</label>
</p>
</div>
</form>
I tried but i cant get it work.

sea4me
03-21-2009, 10:53 PM
Try:


<?php
if (isset($_POST['createclan'])) {
$sitename = $_POST['clanname'];
$admin = $_POST['uname'];
$password = $_POST['password'];
$dirdest = "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename;
$dirsource = "D:/hshome/rubygirl58/gameparody.com/templates/shelld";

function COPY_RECURSIVE_DIRS($dirsource, $dirdest)
{ // recursive function to copy
// all subdirectories and contents:
if(is_dir($dirsource))$dir_handle=opendir($dirsource);
mkdir($dirdest, 0755);
while($file=readdir($dir_handle))
{
if($file!="." && $file!="..")
{
if(!is_dir($dirsource."/".$file)) copy ($dirsource."/".$file, $dirdest."/".$file);
else COPY_RECURSIVE_DIRS($dirsource."/".$file, $dirdest);
}
}
closedir($dir_handle);
return true;
}

COPY_RECURSIVE_DIRS($dirsource, $dirdest);

mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/headers", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib", 0755);
mkdir("D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/team", 0755);

copy("D:/hshome/rubygirl58/gameparody.com/templates/images/background.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/background.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/banner.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/copyright.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/copyright.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/footer_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/footer_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/head_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/head_end.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/head_end.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav_bg.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav_bg.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/banner.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/banner.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/header.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/header.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/nav_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/blank/nav_normal.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/blank/nav_normal.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/news.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/team.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/header/welcome.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/header/welcome.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/contact.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/contact_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/contact_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/forums.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/forums_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/forums_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/homepage.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/homepage_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/homepage_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/media.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/media_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/media_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/news.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/news_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/news_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/results.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/results_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/results_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/scene.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/scene_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/scene_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/team.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/nav/team_hover.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/nav/team_hover.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/images/news/soldier.jpg", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/images/news/soldier.jpg");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/css-reset.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/css-reset.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/ie6.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/ie6.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/roster.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/roster.css");
copy("D:/hshome/rubygirl58/gameparody.com/templates/lib/web.css", "D:/hshome/rubygirl58/gameparody.com/clansites/".$sitename."/lib/web.css");

header( "Location: http://www.gameparody.com/clansites/".$sitename ); //redirect to their page
}
?>
<form id="Form" action="<?php echo $_SERVER['PHP_SELF']?>" method="post" name="Form">
<div class="content22">
<p class="style3">All fields are required!</p>
<table border="0" width="100%">
<tr>
<td width="41%">
<div align="right">
<span class="style10">Name of clan site:</span></div>
</td>
<td width="59%"><label>
<input id="clanname" name="clanname" type="text"> </label>
<span class="style7">(Will be URL of site) </span></td>
</tr>
<tr>
<td>
<div align="right" class="style10">
Admin Username:</div>
</td>
<td><label><input id="uname" name="uname" type="text"> </label>
</td>
</tr>
<tr>
<td>
<div align="right" class="style10">
Admin Password:</div>
</td>
<td><label><input id="password" name="password" type="text">
</label></td>
</tr>
</table>
<p><label>
<input id="createclan" name="createclan" type="submit" value="Create">
</label><label>
<input id="reset" name="reset" type="reset" value="Reset"> </label></p>
</div>
</form>

slappyjaw
03-22-2009, 05:35 AM
Thanks guys so much! Here is what you have helped me achieve.
Game Parody (http://www.gameparody.com) Thankyou
You cant see the clan site thing but if you register it pops up. Now i have to work on the editor for the sites. Also if anyone would like to be a manager if you have spare time. feel free to ask. Thanks
-Greg

slappyjaw
03-23-2009, 03:35 AM
Hey how can u change this to resolved?

PappaJohn
03-23-2009, 03:57 AM
Hey how can u change this to resolved?
Edit the original post and select 'Resolved' from the dropdown near the topic title.

Fou-Lu
03-23-2009, 03:59 AM
I think its a three day limitation on the editing of posts.
I'll flag it as resolved for you.

PappaJohn
03-23-2009, 04:00 AM
Ah, I thought it was 14 days (glad I didn't mention it).

Fou-Lu
03-23-2009, 04:04 AM
I'm not 100% certain what it is, but I just checked a post in another forum thats 6 days old. I can't edit that one, but it may be more than three days. I wish that the title could be edited without editing the initial post, that would allow the resolution to be set without needing to be able to edit the first post.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum