samedi 31 janvier 2015

Need help on a simple Jquery practice


I've just started to practice Jquery at these days. Could you please have a take look at the below link and give me some advise on how to validate my input for only jpeg extension.



$('#submit').click( function() {
var val = $('#URL').val();


if(val !== "") {
$('#URL').val(function (){
$('#frame').fadeOut(800, function(){
$(this).css({backgroundImage: "url("+val+")"});
$(this).fadeIn(800);
});

});
}
else{
$('#lightbox, #feedback').slideDown(700, function(){
$("body").click(function() {
$('#lightbox, #feedback').slideUp(700);
return false;
});
});
}
return false;


Thanks in advance.


Regards.


Özgün





Aucun commentaire:

Enregistrer un commentaire