Have been playing around with Selenium Webdriver and i would like to extract certain information from a webpage. Below is the source code for webdriver
import os
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
PROJECT_ROOT = os.path.abspath(os.path.dirname(__file__))
DRIVER_BIN = os.path.join(PROJECT_ROOT, "/usr/local/bin/chromedriver")
driver = webdriver.Chrome ("/usr/local/bin/chromedriver")
browser = webdriver.Chrome(executable_path = DRIVER_BIN)
browser.get('https://www.abuseipdb.com/check/95.47.155.87')
I would like to extract the value 91% from this particular website and save it into a variable. Will need a solutions that are able to extract the % value out even if it's not 91%. Below are the html code.
<p>This IP was reported <b>222</b> times. Confidence of Abuse is <b>91%</b>: <a href="/faq.html#confidence" style="float: right; font-weight: bold;" class=text-muted>?</a></p>