Warning: file_put_contents : failed to open stream: No such file or directory in php -


<?php  class couty{    public function write ($a,$b){         @session_start();        if(!(isset($_session[`login`]) && $_session[`login`] != ``)){          echo "you must logged in create php file";        }        else{             file_put_contents($a,$b);             exit;        } } }  $c = `<!doctype html><html> <head><title></title></head> <body></body> </html>`;  if($_server[`request_method`] == `post`){    $new = trim($_post[`coutyv`]);    $dir = (mkdir(`folder/$new`));    $d = new couty();    $d->write(`$dir/$new.php`,$c); } ?> <form method = `post` action = ``> <input type = `text` name = `coutyv`/> <input type = `submit` name = `submit`/> </form>  

your problem in here . check if have these folders or not. anyway code not good

  $dir = (mkdir(`folder/$new`));    $d = new couty();    $d->write(`$dir/$new.php`,$c); 

Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -