Jump to content

JQuery .html() question


RIRedinPA

Recommended Posts

The return is a string, right? So I should be able to do a str.IndexOf("something") on it, right?

 

var userlinks = $(".userlinks").html();
	//var indexnum = userlinks.IndexOf("Filter Records");
	console.log(userlinks);
	if (userlinks.IndexOf("Filter Records") == -1) { 

                ...

 

I keep getting: userlinks.IndexOf is not a function

Link to comment
https://forums.phpfreaks.com/topic/225962-jquery-html-question/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.