I want to make a new page and then close the 777 but my server do not do it or they telling me my code is wrong. It is? <?php include ("conn.php"); $sql = "SELECT * FROM users where users_mkdir='N' limit 5"; $result = mysql_query($sql) or die(mysql_error()); $rows=mysql_num_rows($result); echo $rows . "<br><br>"; chmod("/chmod("/xxxxxxxxxxxxxxxx/xxxxxxxxxx.com/", 0777); while ($row=mysql_fetch_array($result)) { $uid =$row["users_id"]; $uname =$row["users_name"]; $ucategory =$row["users_category"]; $ustatus =$row["user_status"]; $sqlupdate = "Update users set users_mkdir= 'Y' where users_id = '$uid' "; mysql_query($sqlupdate); mkdir($uname, 0755); sleep(1); $filename="index.php"; $filenum=fopen("$uname/$filename", "w"); $mystr='<? include ("../users-template.php"); ?>'; $fputs($filenum, $mystr); fclose($filenum); } chmod("/xxxxxxxxxxxxxxxx/xxxxxxxxxx.com/", 0755); ?> PHP:
Well there's 3 double quote marks. I don't know what you're trying to do, but in this example (ignoring the xxxx etc) that is definitely incorrect. You can clearly see from the colour of the PHP Code block. Dan