Changeset 7 for branches/2/frontend.php
- Timestamp:
- May 9, 2008, 7:24:45 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2/frontend.php
r6 r7 32 32 } 33 33 34 function Login() 35 { 36 37 return($this->System->Modules['User']->Login($_POST['Username'], $_POST['Password'])); 38 } 39 40 function Logout() 41 { 42 43 return($this->System->Modules['User']->Logout()); 44 } 45 34 46 function TranslationGroupEdit($TranslationGroupId) 35 47 { 36 $Output = '<strong>Překlad textů:</strong><br /><table id="TranslationItem">';48 $Output = '<strong>Překlad textů:</strong><br /><table class="TranslationTable">'; 37 49 foreach($this->System->Modules['Translation']->GetTextList($TranslationGroupId) as $GroupItem) 38 50 { … … 69 81 function Menu() 70 82 { 71 $Output = '<strong>Menu:</strong><br /><a href="?Action=MangosImport">Import z MaNGOSu</a><br /><br />'; 83 $Output = '<strong>Menu:</strong><br />'. 84 '<a href="?">Uvodní stránka</a><br />'. 85 '<a href="?Action=TranslationGroupList">Seznam skupin</a><br />'. 86 '<a href="?Action=MangosImport">Import z MaNGOSu</a><br />'. 87 '<br />'; 72 88 return($Output); 73 89 } 90 91 function User() 92 { 93 $Output = 'Uživatel: '.$this->System->Modules['User']->User['Name'].' '; 94 if($this->System->Modules['User']->User['Id'] == 0) $Output .= '<a href="?Action=LoginDialog">Přihlásit</a>'; 95 else $Output .= '<a href="?Action=Logout">Odhlásit</a>'; 96 97 return($Output.'<br />'); 98 } 99 74 100 75 101 function Output() … … 79 105 switch($_GET['Action']) 80 106 { 107 case 'LoginDialog': 108 $Output = $this->LoginDialog(); 109 break; 110 case 'Login': 111 $Output = $this->Login(); 112 break; 113 case 'Logout': 114 $Output = $this->Logout(); 115 break; 81 116 case 'TranslationGroupEdit': 82 117 $Output = $this->TranslationGroupEdit($_GET['GroupId']); … … 85 120 $Output = $this->TextGroupList($_GET['GroupId']); 86 121 break; 122 case 'TranslationGroupList': 123 $Output = $this->TranslationGroupList(); 124 break; 87 125 case 'MangosImport': 88 126 $Output = $this->System->Modules['MangosImport']->FullImport(); 89 127 break; 90 128 } 91 else $Output = $this->Menu().$this->LoginDialog().'<br />'.$this->TranslationGroupList().'</div>';92 return($this->Header(). $Output.''.$this->Footer());129 else $Output = ''; 130 return($this->Header().'<table class="MainLayout"><tr><td id="LeftPanel">'.$this->User().$this->Menu().'</td><td>'.$Output.'</td></tr></table>'.$this->Footer()); 93 131 } 94 132 }
Note:
See TracChangeset
for help on using the changeset viewer.