Codigo ejemplo :
Código: Seleccionar todo
<?php
include( "config.php" );
include( TWEB_PATH . 'core.php' );
$oWeb = new TWeb('TEST TGET');
$oWeb->lAwesome = true;
$oWeb->Activate();
$oWnd = new TWindow('main', 10, 10, '45%', '40%');
$oBar = new TBar( $oWnd );
$oBar->AddButton( 'bLoad', 'Url', 'Load()' , IMAGE_PATH . 'refresh-black-16.png', 'Load' );
$oBar->AddButton( 'bSalir', 'Salir', 'DoForo()' , IMAGE_PATH . 'logout-black-16.png', 'Salir' );
$oGet = new TGet( $oWnd, 'get1', 60, 10, '', 200, 30 );
$oGet->cPlaceHolder = 'Get1';
$oGet->SetColorFocus( 'rgb(204, 255, 255)' );
$oGet->IconAction('test1()', 'fa-search', 'black');
$oGet = new TGet( $oWnd, 'get2', 100, 10, '', 200, 30 );
$oGet->cPlaceHolder = 'Get2';
$oGet->BtnAction('test2()', 'fa-search', 'black');
$oWnd->Activate();
$oWeb->End();
?>
<script>
function test1() {
JMsgInfo("Test con Icon");
}
function test2() {
JMsgInfo("Test con Button");
}
function Load() {
url_redirect( { url: './url_test.php', method: 'post', data: {}, newtab : true } );
}
function DoForo() {
location.href = 'http://avcsistemas.com/foro';
}
</script>