/lenasys/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/lenasys/trunk

« back to all changes in this revision

Viewing changes to codeigniter/application/controllers/layout.php

  • Committer: b11johgu
  • Date: 2013-05-03 11:39:08 UTC
  • mto: This revision was merged to the branch mainline in revision 53.
  • Revision ID: b11johgu@student.his.se-20130503113908-m8nilvexb8atwtvz
Added controllers for examplepage, templatelayout.
Updated models for login and database interaction.
Added ajax controller.
... A lot of stuff has changed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?php
 
2
/*
 
3
Copyright (C) Högskolan i Skövde <his.se> 2013.
 
4
Copyright (C) Oscar Jonsson <c11oscjo@student.his.se> 2013.
 
5
Copyright (C) Simon Bergöö <a11simbe@student.his.se> 2013.
 
6
This file is part of LenaSYS
 
7
 
 
8
This program is free software: you can redistribute it and/or modify
 
9
it under the terms of the GNU Lesser General Public License as published by
 
10
the Free Software Foundation, either version 3 of the License.
 
11
 
 
12
This program is distributed in the hope that it will be useful,
 
13
but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
15
GNU Lesser General Public License for more details.
 
16
 
 
17
You should have received a copy of the GNU Lesser General Public License
 
18
along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
19
*/
 
20
 
 
21
class layout extends CI_Controller {
 
22
        
 
23
        public function index() {
 
24
                $headData['list'] = array('headTag', 'header', 'layout_view');
 
25
                $this->load->view('headTag', $headData);
 
26
                $this->load->helper('form');
 
27
                $this->load->model('user');
 
28
                $userInfo = array(
 
29
                        'userType' => $this->user->getUserType(),
 
30
                        'userName' => $this->user->getUserName()
 
31
                );
 
32
                
 
33
                $this->load->view('header', $userInfo);
 
34
                $this->load->view('layout_view');
 
35
                
 
36
        }
 
37
        public function test($arg1){
 
38
                echo "<h1> Layout ".$arg1."</h1>".
 
39
                         "<p>You have pressed layout ".$arg1.". (This is only a test-function and will be removed.)</p>";
 
40
        }
 
41
        
 
42
}
 
 
b'\\ No newline at end of file'