src-dev/Mouf/Controllers/MoufController.php
public function createInstanceByCode($selfedit = "false", $instanceName=null) {
        if (!$instanceName) {
            $this->newInstanceByCallback();
            return;
        }

        $this->selfedit = $selfedit;

        if ($selfedit == "true") {
            $this->moufManager = MoufManager::getMoufManager();
        } else {
            $this->moufManager = MoufManager::getMoufManagerHiddenInstance();
        }

        $this->moufManager->createInstanceByCode()->setName($instanceName);
        $this->moufManager->rewriteMouf();
        header("Location: ".MOUF_URL."ajaxinstance/?name=".urlencode($instanceName)."&selfedit=".$selfedit);
    }
public function createInstanceByCode($selfedit = "false", $instanceName=null) {
        if (!$instanceName) {
            $this->newInstanceByCallback();
            return;
        }

        $this->selfedit = $selfedit;

        if ($selfedit == "true") {
            $this->moufManager = MoufManager::getMoufManager();
        } else {
            $this->moufManager = MoufManager::getMoufManagerHiddenInstance();
        }

        $this->moufManager->createInstanceByCode()->setName($instanceName);
        $this->moufManager->rewriteMouf();
        header("Location: ".MOUF_URL."ajaxinstance/?name=".urlencode($instanceName)."&selfedit=".$selfedit);
    }
public function createInstanceByCode ( $ selfedit = "false" , $ instanceName = null ) { if ( ! $ instanceName ) { $ this -> newInstanceByCallback ( ) ; return ; } $ this -> selfedit = $ selfedit ; if ( $ selfedit == "true" ) { $ this -> moufManager = MoufManager :: getMoufManager ( ) ; } else { $ this -> moufManager = MoufManager :: getMoufManagerHiddenInstance ( ) ; } $ this -> moufManager -> createInstanceByCode ( ) -> setName ( $ instanceName ) ; $ this -> moufManager -> rewriteMouf ( ) ; header ( "Location: " . MOUF_URL . "ajaxinstance/?name=" . urlencode ( $ instanceName ) . "&selfedit=" . $ selfedit ) ; }
Performs the action of creating a new instance.

@Action
@Logged
Performs the action of creating a new instance .