How can I check if a string contains another string instead of using "==" to compare the whole string?
Regards
How can I check if a string contains another string instead of using "==" to compare the whole string?
Regards
You can use .indexOf():
if(str.indexOf(substr) > -1) {
}
