Follow Me:

Sunday, 30 November 2014

Contains() Property in javascript.,it is working fine in Mozila Firebox only.It will not support Chrome Browser,Internet Browser,Safari,Opera browser.


Mozila Browser :


  var ClearFilterValue  = 'family Schools';
    if(ClearFilterValue.contains("family")== true) {
   alert('Success');
    } 
  

Chorme & Mozila Firebox Browser :

    The below javascript index() properity will working for both chrome and mozile firbox.It is functionality similar to contains property.

var ClearFilterValue  = 'family Schools';
alert(ClearFilterValue.indexOf("family") != -1);

var n  =   str.indexOf("family"); 
if(n >= 0) { 
    alert(success); 
}


Categories: , ,

6 comments:

  1. So happy to be given a privilege to post a comment here. You have a wonderful site. Thank you for the effort to publish this.

    www.gofastek.com

    ReplyDelete

  2. Thanks for posting this useful content, Good to know about new things here, Let me share this, . linux training in pune

    ReplyDelete
  3. Some investors who are due to retire from their job are interested to invest their money in buying properties located in overseas market with the hope of earning huge profits.
    Project Information

    ReplyDelete