Jquery com conflito
Olá amigos do forum,
Estou desenvolvendo uma página de formulário onde estou utilizando 2 Jquery para ter um campo de data e um textarea com editor HTML porem quando um funciona o outro desativa.
Estou colocando o código abaixo
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Painel | Personal Traveler</title>
<link href="lib/css/estilo.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" type="text/css" href="lib/css/MooEditable.css">
<link rel="stylesheet" href="[http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css](http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css)" />
<script src="lib/jquery/mootools.js"></script>
<script src="lib/jquery/MooEditable.js"></script>
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
<script type="text/javascript">
window.addEvent('domready', function(){
$('textarea-1').mooEditable();
// Post submit
$('theForm').addEvent('submit', function(e){
alert($('textarea-1').value);
return true;
});
});
</script>
<script>
jQuery.noConflict();
$(function() {
$( "#datepicker" ).datepicker({
showOn: "button",
buttonImage: "lib/imagens/ico-calendar.png",
buttonImageOnly: true
});
});
</script>
</head>
<body>
<div id="topo">
<div id="topo-container"> <a href="home.php"><img src="lib/imagens/logo-traveler.png" width="248" height="73" /></a>
<div id="bt-topo">
<nav id="menu-topo">
<ul>
<li><a href="cadastro-admin.php">Admin</a></li>
<li><a href="cadastro-destino.php">destinos</a></li>
<li><a href="cadastro-destino.php">Participantes</a></li>
<li><a href="cadastro-coordenador.php">coordenadores</a></li>
<li><a href="cadastro-agenda.php">agenda</a></li>
<li><a href="cadastro-layout.php">Dicas da viagem</a></li>
</ul>
</nav>
</div>
<div id="bem-vindo">Olá <?php echo $row['AD_UsuarioLogin']; ?> , você esta conectado! | <a href="#">Sair</a> </div>
</div>
</div>
<?php include('header.php'); ?>
<script language="javascript"><!-- chama a função (nomeform) -->
function valida_dados (nomeform)
{
if (nomeform.data.value=="")
{
alert ("Qual é o dia?");
return false;
}
if (nomeform.hora.value=="")
{
alert ("Está faltando a hora!");
return false;
}
if (nomeform.detalhe.value=="")
{
alert ("Cadastras informações sobre o evento.");
return false;
}
return true;
}
</script>
<div id="container">
<div id="container-add">
<section class="form-add">
<form name="signup" method="post" action="gravando-agenda.php">
<br />
<h3>Cadastro da Agenda</h3>
<br />
<div id="form-data">Data: <br /> <input type="data" id="datepicker" name="data" value="<?php echo $AG_Data; ?>" /></div>
<div id="form-hora">Hora: <br /> <input type="hora" name="hora" /></div>
Detalhes: <textarea name="detalhe" rows="10" id="textarea-1"></textarea>
<br />
<input type="submit" name="submit" value="Cadastrar">
<input name="reset" type="reset" value="Limpar" />
<br /><br /><br />
</form>
</section>
</div>
</div>
</body>
</html>
É possível colocar 2 jquery na mesma pagina?
Obrigado pela ajuda!
Discussão (5)
Carregando comentários...