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 6468989
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T05:56:29+00:00 2026-05-25T05:56:29+00:00

I am trying to get into the web push technology so I started looking

  • 0

I am trying to get into the web push technology so I started looking around. I have basically found 2 technologies, that is Websockets and SSE. After ruling out Websockets because of lack of perl support, I wanted to try out the more native SSE-approach.

Now, trying to get SSE to work is a real pain in the arse. Every documentation has conflicting information and there does not seem to be a general consensus on how SSE works. Some say hat you need an <event-listen src="events.pm"> tag, others say you only need an EventSource JS object. Even with the EventSource object, I found around 4 possible implementations and none of them seem to work.

Here is what I have. I have an events.pm, which uses mod-perl. If you call that file, it returns data: I haz a websocket. That is sent with the content-type application/x-dom-event-stream.

The HTML and JS files have been rewritten so often with different implementations that I have given up on them. Can you guys please give me a working example?

Also: I do not understand how you can send specific messages to the client. Sending a predefined message seems to be fine. However, if I imagine a situation where someone sends me a message, I do not understand how exactly that information (‘there is a new message for you’) is transmitted to that exact browser that needs that information. Every post I found on this is vague at best.

EDIT

Basically, what I need is a way to say ‘hey, are you allowed to get this notification? show me your id/session/token first!’ on a per connected client basis. I wonder if it is at all possible with SSE.

  • 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-05-25T05:56:30+00:00Added an answer on May 25, 2026 at 5:56 am

    I would say that Server-sent events are described pretty good in Stream Updates with Server-Sent Events article, namely the Event Stream Format. With Firefox 6 SSEs are now supported by majority of modern browsers (unfortunately except IE).

    I do not understand how you can send specific messages to the client.
    Sending a predefined message seems to be fine. However, if I imagine a
    situation where someone sends me a message, I do not understand how
    exactly that information (‘there is a new message for you’) is
    transmitted to that exact browser that needs that information.

    Clients are connected with the SSE server by keep-alive event stream, uni-directional connection which isn’t closed until browser/tab is closed, user invokes close method or network connection is lost.

    Basically, what I need is a way to say ‘hey, are you allowed to get
    this notification? show me your id/session/token first!’ on a per
    connected client basis. I wonder if it is at all possible with SSE.

    This kind of authentication logic would be required to do on the server side, so it’s dependent on the language or platform you are using. Unless there is library for that in your environment you would probably have to write it.

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

Sidebar

Related Questions

I am trying to get data into a web application that runs in a
I am just trying to get into python, but I've found it very difficult
I'm a long time C++/Java developer trying to get into Python and am looking
I'm trying to implement Facebook authentication into my web project. I've managed to get
I am trying to get used to web development and one thing that eluded
I'm trying to get into Java web development but seem to be running into
I'm trying to get data from a web-page into my sidebar gadget via: $.get(http://localhost/index.php,
I am trying to get into web development, specially interested building the front-end, UI
I'm trying to get my build number into the web.config of an ASP.Net MVC
Im trying to get into some basic JavaFX game development and I'm getting confused

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.