I want to access the yellow highlighted span tag value give in the image below:
I tried the following in chrome console but it gives undefined
value as follows:
Where am I getting wrong? How do I solve this? How do I get the span value?
I want to access the yellow highlighted span tag value give in the image below:
I tried the following in chrome console but it gives undefined
value as follows:
Where am I getting wrong? How do I solve this? How do I get the span value?
You need to use:
$('#id_frame').contents().find('#queuedBetTotal').text();
You should also know that if the iframe source is pointing to a different domain, due to security reasons, you will not be able to access the contents of this iframe in javascript.
$('iframe').contents().find('#queuedBetTotal').html(); if you don't have id means you can use the tag name.