Permalink
Browse files

Variable optimisations

  • Loading branch information...
1 parent 1fda45c commit 2204bab001ce7a4b04c644b9479be63724140a89 @jaseemabid jaseemabid committed Oct 16, 2011
Showing with 8 additions and 10 deletions.
  1. +3 −3 editprofile.html
  2. +5 −7 feedback.html
View
@@ -66,9 +66,9 @@
});
$('span#feedbackFormSubmitPasswd').click(function() {
- var p = $('input#pWord1').attr('value');
- var p1 = $('input#pWord1').attr('value');
- var p2 = $('input#pWord2').attr('value');
+ var p = $('input#pWord1').attr('value'),
+ p1 = $('input#pWord1').attr('value'),
+ p2 = $('input#pWord2').attr('value');
if( p1 !== p2) {
alert("Enter the same password");
} else if ( p1.length < 6 ) {
View
@@ -24,17 +24,16 @@
$(this).parent().children().removeClass('hilite');
$(this).addClass('hilite');
$('div#feedback div.content .panel').fadeOut("fast").fadeIn("");
- var numb = $("div#feedback ul.links li").index(this);
- var type = $("div#feedback ul.links li").eq(numb).attr('type');
- var desc = $("div#feedback ul.links li").eq(numb).attr('desc');
+ var numb = $("div#feedback ul.links li").index(this),
+ type = $("div#feedback ul.links li").eq(numb).attr('type'),
+ desc = $("div#feedback ul.links li").eq(numb).attr('desc');
$('input#fType').attr('value',type);
$('textarea#fDesc').attr('placeholder',desc);
});
-
$('span#feedbackFormSubmit')
.click(function() {
- var fb = $(this).parent();
- var feedback = {} ;
+ var fb = $(this).parent(),
+ feedback = {} ;
feedback.type = $('input#fType').attr('value');
feedback.fname = $('input#fName').attr('value');
feedback.desc = $('textarea#fDesc').attr('value');
@@ -53,7 +52,6 @@
} , "json" );
}
});
-
$('div#darkenScreenObject').click(function(){
hideFeedback();
});

0 comments on commit 2204bab

Please sign in to comment.