]> git.mxchange.org Git - shipsimu.git/blobdiff - application/ship-simu/templates/de/code/login_main.ctp
All helper are now configurable
[shipsimu.git] / application / ship-simu / templates / de / code / login_main.ctp
index 81d3c0abbc945b511cc28ba1b709ca7c4079bf5c..e8b0044f1db2669d0d6bce6351226024dbccb557 100644 (file)
@@ -4,7 +4,7 @@
 ///////////////////////////////
 
 // Get a new instance for personal data
-$blockInstance = WebBlockHelper::createWebBlockHelper($this, 'persona_data');
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'persona_data'));
 
 // Set the data source instance which must exist in registry
 $blockInstance->prefetchValueInstance('user');
@@ -27,7 +27,7 @@ $blockInstance->flushContent();
 //////////////////////////////////////
 
 // Get a new instance for personal data
-$blockInstance = WebBlockHelper::createWebBlockHelper($this, 'company_data');
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'company_data'));
 
 // Set the data source instance
 $blockInstance->prefetchValueInstance('company', 'user');
@@ -62,6 +62,16 @@ if ($blockInstance->getValueInstance()->ifUserIsFounder()) {
 // Flush the content out to a template variable
 $blockInstance->flushContent();
 
+// Get helper instance
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout_action_link', 'index.php?app={?app_short_name?}&page=login_area'));
+
+// Add action
+$linkInstance->addLinkGroup('logout', "");
+$linkInstance->addActionLink('logout', "Ausloggen");
+
+// Flush the content
+$linkInstance->flushContent();
+
 // End of all PHP commands
 ?>
 <div id="content_header">
@@ -82,8 +92,7 @@ $blockInstance->flushContent();
        </div>
 
        <div id="logout_link">
-               [<a href="$config[base_url]/index.php?app=ship-simu&amp;page=login_area&amp;action=logout"
-                title="Aus dem Spiel ausloggen">Ausloggen</a>]
+               {?logout_action_link?}
        </div>
 </div>