]> git.mxchange.org Git - city.git/blob - application/city/templates/code/login_main.ctp
fb818febcc230512fd65fa3b6a6ed68f821df0e3
[city.git] / application / city / templates / code / login_main.ctp
1 <?php
2 ///////////////////////////////
3 // Assign personal user data //
4 ///////////////////////////////
5
6 // Get a new instance for personal data
7 $blockInstance = ObjectFactory::createObjectByConfiguredName('html_block_helper_class', array($this, 'persona_data'));
8
9 // Set the data source instance which must exist in registry
10 $blockInstance->prefetchValueInstance('user', 'user_points');
11
12 // Assign fields with template variables
13 $blockInstance->assignField('username');
14 $blockInstance->assignFieldWithFilter('user_status', 'user_status_translator');
15 $blockInstance->assignFieldWithFilter('points', 'format_number');
16
17 // Shall we include registration date?
18 if ($blockInstance->ifIncludeRegistrationStamp()) {
19         // Then assign it as well!
20         $blockInstance->assignFieldWithFilter('registered', 'format_timestamp');
21 } // END - if
22
23 // Flush the content out to a template variable
24 $blockInstance->flushContent();
25
26 // Get helper instance
27 $linkInstance = ObjectFactory::createObjectByConfiguredName('html_link_helper_class', array($this, 'logout'));
28
29 // Add action
30 $linkInstance->addActionLinkById('logout', 'logout');
31
32 // Flush the content
33 $linkInstance->flushContent();
34
35 // [EOC]
36 ?>
37 <div id="content_header">
38         Willkommen im Loginbereich von <span class="app_name">{?app_full_name?}</span>!
39 </div>
40
41 <div id="content_body">
42         {?login_content?}
43 </div>
44
45 <div id="persona_data" title="Informationen zu Deinem Spieleaccount">
46         <div id="persona_header">
47                 Account-Infos:
48         </div>
49
50         <div id="persona_body">
51                 {?persona_data?}
52         </div>
53
54         <div id="logout">
55                 {?logout?}
56         </div>
57 </div>