Setar combo pelo .text() do option – jQuery 19 Jan 2012 por admin em jQuery (1) comentário Apenas repositório mesmo:
Copiar formulario, ao selecionar select 22 Sep 2010 por admin em Javascript (2) comentários <html> <head> <script type="text/javascript"> function id( el ){ return document.getElementById( el ); } function copia_apaga( copia, value ){ return copia=='copia' ? value : ''; } function copia_motorista( copia ) { id('nome_motorista').value = copia_apaga( copia, id('nome_proprietario').value ); id('carteira_motorista').value = copia_apaga( [...]
Label de Option da tag select 14 Jul 2010 por admin em Javascript Nenhum comentário <html> <head> <script type="text/javascript"> function label_option( el ) { var label = el.options[ el.selectedIndex ].text; alert( label ); } window.onload = function() { document.getElementById( 'teste' ).onchange = function() { label_option( this [...]
Combobox dinâmico com cadastro AJAX 07 Apr 2010 por admin em AJAX (2) comentários Cara, não é ‘algo comum’, mas achei interessante essa dúvida, e resolvi montar. Em funcionamento: http://www.wbruno.com.br/scripts/form-cidade.php config.inc.php <?php header("Content-Type: text/html; charset=ISO-8859-1"); //Evitando cache de arquivo header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); header('Last Modified: '. gmdate('D, d M Y H:i:s') .' GMT'); header('Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0'); header('Pragma: no-cache'); header('Expires: 0'); session_start(); ///* define('SERVIDOR', [...]