phpMv -UI toolkit 2.4.12
jQuery, jQuery UI, Twitter Bootstrap and Semantic-UI library for php & php MVC Frameworks
Loading...
Searching...
No Matches
FormLogin.php
Go to the documentation of this file.
1<?php
8class FormLogin extends BusinessForm {
13 public function __construct($identifier,$modelInstance=null,$fieldsOrder=[],$fieldsDefinition=[],$fields=[],$captions=[],$separators=[]) {
14 parent::__construct($identifier,$modelInstance,$fieldsOrder,$fieldsDefinition,$fields,$captions,$separators);
15 }
16
17 protected function getDefaultModelInstance(){
18 return new UserModel();
19 }
20
21 public static function regular($identifier,$modelInstance=null){
22 return new FormLogin($identifier,$modelInstance,
23 ["message","login","password","remember","forget","submit","error"],
24 ["message"=>[["icon"=>"sign in"]],"input0"=>[["rules"=>"empty"]],"input1"=>[["inputType"=>"password","rules"=>"empty"]],"checkbox","link","submit"=>["green fluid"],"message2"=>[["error"=>true]]],
25 ["Connection","login","password","remember","forget","submit","error"],
26 ["Please enter login and password to connect","Login","Password","Remember me.","Forgot your password?","Connection"],
27 [0,2,4,5,6]);
28 }
29
30 public static function smallInline($identifier,$modelInstance=null){
31 $result=new FormLogin($identifier,$modelInstance,
32 ["login","password","submit"],
33 ["input0"=>[["rules"=>"empty"]],"input1"=>[["inputType"=>"password","rules"=>"empty"]],"submit"=>["green basic"]],
34 ["login","password","submit"],
35 ["","","Connection"],
36 [2]);
37 $result->addDividerBefore(0, "Connection");
38 return $result;
39 }
40
41 public static function small($identifier,$modelInstance=null){
42 $result=new FormLogin($identifier,$modelInstance,
43 ["login","password","submit"],
44 ["input0"=>[["rules"=>"empty"]],"input1"=>[["inputType"=>"password","rules"=>"empty"]],"submit"=>["green basic"]],
45 ["login","password","submit"],
46 ["Login","Password","Connection"],
47 [1,2]);
48 $result->addDividerBefore(0, "Connection");
49 return $result;
50 }
51
52 public static function attachedSegment($identifier,$modelInstance=null){
53 $result=self::regular($identifier,$modelInstance);
54 $result->fieldAsMessage("message",["icon"=>"sign in","attached"=>true]);
55 $result->addWrapper("message",null,"<div class='ui attached segment'>");
56 $result->addWrapper("error", null,"</div>");
57 return $result;
58 }
59}
__construct($identifier, $modelInstance=null, $fieldsOrder=[], $fieldsDefinition=[], $fields=[], $captions=[], $separators=[])
Definition FormLogin.php:13
static smallInline($identifier, $modelInstance=null)
Definition FormLogin.php:30
static small($identifier, $modelInstance=null)
Definition FormLogin.php:41
static attachedSegment($identifier, $modelInstance=null)
Definition FormLogin.php:52
static regular($identifier, $modelInstance=null)
Definition FormLogin.php:21