2012-10-12 4 views

Antwort

3

missingAction Methode in Ihrem Controller implementieren,

Wie gesagt @xdazz, überprüft er, ob Verfahren vorhanden ist, und wenn nicht nennt es missingAction Methode .

//This method is invoked when the controller cannot find the requested action. 

public function missingAction($actionID) 
{ 
    // Your code here 
} 
+0

Ich habe das versucht und es funktioniert gut !!!!!!!!!!! Vielen Dank –

3

Dies hängt von der Implementierung des Frameworks ab.

Zum Beispiel, wenn der Rahmen des Code implementieren wie:

If (!method_exists($controller, $action)) { 
    throw new Exception("The system is unable to find the requested action $action"); 
} 
Verwandte Themen