Jump to content
UBot Underground

Any Selenium Example Used In Ubot?


Recommended Posts

Hi,

 

I'm struggling for many days now to run a simple Python script that requires selenium to open an HTML page. Do you guys have any script example to share so I can compare and see what is not working with mine? 

This is my script (I'm not even sure if it's the way to do it. I didn't find any newbie-friendly documentation so far, so I improvised):

define $Python file path {
    return("E:\\Dropbox2\\Dropbox\\Ubot\\Ubot\\Python\\WPy-3702\\python-3.7.0\\python.exe")
}
define Command Python {
    run python($plugin function("ExecutePython.dll", "Execute From Code", "import selenium
from selenium import webdriver
from selenium.webdriver.chrome.options import Options

chrome_options = Options()

chrome_options.add_argument(\"--start-maximized\")
chrome_options.add_argument(\"user-data-dir=selenium\")

driver = webdriver.Chrome(\'C:\\Users\\home\\VisualCodeProjects\\chromedriver.exe\', chrome_options=chrome_options)


driver.get(\"https://my.outbrain.com/login\")", $Python file path()))
}
Command Python()

Thanks in advance,

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...