Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: substr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: substr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: substr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: substr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Deprecated: substr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/project-web/jquery4php/lib/YepSua/Labs/RIA/jQuery4PHP/YsJQueryBuilder.php on line 127
Ui theme 1
<?php //For use the plugins YsJQuery::usePlugin(YsJQueryConstant::PLUGIN_JQVALIDATE); YsJQuery::usePlugin(YsJQueryConstant::PLUGIN_JQFORM); ?> <button id="btnOpenDialog">Show Demo</button> <?php echo YsUIDialog::initWidget('dialogId','style="display:none" title="Basic dialog"') ?> <form class="cmxform" id="commentForm" method="post" action="examples/response/commentResponse.php"> <div id="response"> <fieldset> <legend>Please provide your name, email address (wont be published) and a comment</legend> <p> <label for="cname" id="lblCName">Name:</label> <input id="cname" name="name" /> <input id="checkInput" type="checkbox" name="checkInput" /> <p> <label for="cemail">E-Mail (required)</label> <input id="cemail" name="email" /> </p> <p> <label for="curl">URL (optional)</label> <input id="curl" name="url" class="url" value="" /> </p> <p> <label for="ccomment">Your comment (required)</label> <textarea cols="2" rows="2" id="ccomment" name="comment"> </textarea> </p> <p align="center"> <input class="submit" type="submit" value="Submit"/> </p> </fieldset> <p>Requires form plugin</p> </div> </form> <?php echo YsUIDialog::endWidget() ?> <?php echo YsJQuery::newInstance() ->onClick() ->in('#btnOpenDialog') ->execute( YsUIDialog::build('#dialogId') ->_modal(true) ->_width(670) ->_height('auto') ->_buttons(array( 'Ok' => new YsJsFunction('alert("Hello world")'), 'Close' => new YsJsFunction(YsUIDialog::close('this'))) ), YsJQValidate::validate('#commentForm') ->_rules( array('name' => array('required' => "#checkInput:checked", 'minlength' => 2), 'email' => array('required' => true, 'email' => true), 'url' => array('url' => true), 'comment' => 'required') ), YsJQForm::clearForm()->in('#commentForm'), YsJQForm::ajaxForm()->in('#commentForm')->_target('#response') ) ?> <?php echo YsJQuery::click() ->in('#checkInput') ->handler( YsJsFunction::execute( YsJQuery::html("Name (required, at least 2 characters):")->in('#lblCName') ->condition( // <--> condition(condition,failureCallback) YsJQuery::is(':checked')->in("this"), // <- Condition YsJQuery::html("Name:")->in('#lblCName') // <- On failure Condition ) ) ) ->execute() ?>