The configuration uses the factory pattern with which you can store and change configuration parameters centrally.
This enables jybrid to be reconfigured again and again in large web applications.
$jybConfig = \Jybrid\Factory::getInstance()->getConfig();
// or, if you are working with only one "Factory" named Class in this File use the "use" use Jybrid\Factory; $jybConfig = Factory::getInstance()->getConfig();
// or if you want to configure without the new variable "$jybConfig" initialisation \Jybrid\Factory::getInstance()->getConfig()->setExitAllowed(false);
Personally, I only use this feature during development.
Jybrid\Scripts\Core(['scriptName' => 'myScriptName', 'fileName' => 'myScriptName_0.3.0.js', 'useScriptLoadTimeout' => true]); has to contain the "'useScriptLoadTimeout' => true"
The following script is then automatically stored in the head tag.
default is true
/* Boolean: bExitAllowed A configuration option that is tracked by the main <jybrid>object. Setting this to true allows <jybrid> to exit immediatly after processing a jybrid request. If this is set to false, jybrid will allow the remaining code and HTML to be sent as part of the response. Typically this would result in an error, however, a response processor on the client side could be designed to handle this condition. */
/** Function: getCharacterEncoding Called automatically by new response objects as they are constructed to obtain the current character encoding setting. As the character encoding is changed, the <jybridResponseManager> will automatically notify the current response object since it would have been constructed prior to the setting change, see <jybridResponseManager::configure>. */
The per request configuration is located at