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

  • Home
  • SEARCH
  • 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 8929079
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T08:35:42+00:00 2026-06-15T08:35:42+00:00

I am new to web programming with Java. I have a Client/Server written (in

  • 0

I am new to web programming with Java. I have a Client/Server written (in Java) and I want updates from the Client to be sent from the Server to a web interface for a user to view. The timing of the updates will be random, but I want to be able to dynamically update a web page with new data without the browser having to refresh.

Hope this makes sense:

I’ve tried creating a Servlet that Observes (implements Observer) my Server (which extends Observable) for updates (Strings), however I don’t know how to dynamically add these to a browser window. I have tried printing directly from the Servlet using PrintWriter out = response.getWriter(); in the doGet() method, but response.getWriter() is unavailable in the Servlet’s update() method.

My initial thoughts were to use a JSP page (I need to eventually incorporate HTML/CSS) that receives the Observer updates from the Server but I’m not sure.

I’ve done some research into Comet/PUSH, but I’m not sure if this is what I need – perhaps a bit overkill? Any advice on how to achieve what I’m after would be greatly appreciated.

  • 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-15T08:35:43+00:00Added an answer on June 15, 2026 at 8:35 am

    The most common way to do this is for the client to poll the server for changes. Use an AJAX request on the client side to poll an endpoint on your server.

    You will then need to use JQuery / Javascript to update your web page with the new data retrieved from the AJAX request.

    I would suggest using JQuery in theb rowser and using the AJAX function: http://api.jquery.com/jQuery.ajax/

    It allows you to do a callback after the request and in that call back you can update the content of your web page with the data retrieved from the request.

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

Sidebar

Related Questions

I'm new to Web java programming. I want to create a simple JSF modular
I am fairly new to web programming, I have mainly used java to create
I am new in java programming. I have write a small web program using
I'm new to Java-based web programming and am trying to learn JSF from the
I'm very new to web-application programming with Java. I have two questions. First: I
I am new to web programming and Visual Web Developer. I have made a
I am new to web programming,learning VBScript.I want to display few text boxes in
I am new to web programming...I have been asked to create a simple Internet
I'm new to Web programming! I try to make an app (something like Client
I'm new to Django and Web programming in general. Have googled but could not

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.