Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9133899
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T08:33:57+00:00 2026-06-17T08:33:57+00:00

As an example, the chat site Omegle always displays on its homepage the current

  • 0

As an example, the chat site Omegle always displays on its homepage the current number of users online, which I am able to extract with this python script using the headless HTMLUnit Webdriver in Selenium:

from selenium import webdriver    
driver = webdriver.Remote(desired_capabilities=webdriver.DesiredCapabilities.HTMLUNITWITHJS)
driver.get('http://www.omegle.com/')
element = driver.find_element_by_id("onlinecount")
print element.text.split()[0]

The output is like:

22,183

This number is dynamically generated and updated periodically by a script, and I want to read just this dynamically updated content at intervals without repeatedly loading the entire page with driver.get. What Selenium Webdriver method or functionality will let me do that?

This article seems like a relevant lead, though it led me nowehere.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T08:33:58+00:00Added an answer on June 17, 2026 at 8:33 am

    This is untested, but I think the following might work:

    from selenium import webdriver    
    from time import sleep
    driver = webdriver.Remote(desired_capabilities=webdriver.DesiredCapabilities.HTMLUNITWITHJS)
    driver.get('http://www.omegle.com/')
    interval = 10  #or whatever interval you want
    while True:
        element = driver.find_element_by_id("onlinecount")
        print element.text.split()[0]
        sleep(interval)
    

    I think if you find the element after it’s been altered, it will give you the new value.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Am creating a Facebook like chat application.(Say for example am chatting with 4 users)
Lets say you have a site where users may open chat rooms. Once a
I've modified the bluetooth chat example from the SDK demos to be able to
I got the chat example working from Atmosphere, and now I want to get
I am looking at the websocket-chat example. It unveils much, but I still cannot
I have been using the Bluetooth chat example for transferring data over Bluetooth from
I'll try to explain this with an example. I'm writing a chat application. There
I'm trying to implement simple Comet chat example and for this I implemented Long
There is a great example of a chat app using Server-Sent Events by Konstantin
I've been basing this code off the Bluetooth Chat example. It worked when it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.