Cjax Framework


Ajax Send inputs

Examples


PHP
<?php 

$ajax
->click("button1",$ajax->call("ajax.php?send_input/send_text/|text1|"));

$ajax->click("button2",$ajax->call("ajax.php?send_input/send_checkbox/|check1|"));

?>
Controller:
PHP
<?php 

class controller_send_input {

    function 
send_text$text )
    {

        
$ajax ajax();

        
$ajax->success("This message was sent: $text",30);
    }

    function 
send_checkbox$check )
    {
        
$ajax ajax();

        if(
$check) {
            
$ajax->success("Is checked..");
        } else {
            
$ajax->warning("Is not checked..");
        }
    }
}

?>

Try it







Previous Topic:  Previous Class    ·   Top of Page   ·   Demos Home   ·  

CodeIgniter  ·  Copyright © 2006 - 2012  ·  Cjax