javascript - Code works on jquery 1.8.3 but not work on 1.9.1 and up -


I have a code that works on 1.8.3 (After successfully blurring or focusing, SOFFIX has some Typed), but won does not work on 1.9.1 or higher

   & Lt; Input type = text class = "normal" & gt; & Lt; Br> & Lt; Input type = text class = "gen" & gt; & Lt; / Div & gt; $ ("#Mmm") ('Focus change change blur', '.general', function () {var myvar = $ (this); chorid = it.value; $ .ajax ({url: '/ echo / html /', success: function (data) , Status) {myvar.empty (.) ("Value", chorid + "maxffix");}})})   

on check-wide 1.8.3 / if you have version 1 9.1 or higher, the code stop works (if something is typed, the suffix is ​​not added)

you want to see who changed it. Important to you:

jQuery 1.6 has started the .prop () method to install and obtain properties on nodes and set properties to .attr () Usage is deprecated. However, the version up to 19 continues to use .attr () for specific conditions.

then replace .attr to .prop : ("Focus change change blur", '.gen', function () { var myvar = $ (this); coreid = this.value;

  $ ("# mmm") $ .ajax ({url: '/ echo / html /', success: function (Data, status) {myvar.empty (.) Prop ("value", chorid + "mysophikas")}}})})   

You will also see that if you include the jQuery Migrate plugin, then you .attr () myvar.val (chorid)

+ "MYSUFFIX");



Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -