Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.


    To learn more about how to use our BBCode feature, please click here.

    Thank you, Code Forum.

JavaScript Multi-user ringing bell

RJForbes

New Coder
Hi there!

I'm definetely an amatuer when it comes to JV (& Perl). I was hoping to create a CSS ringing bell with multi-users. Where if one user hits a button to ring the bell, the bell rings for everyone viewing the page, rather than simply the user who is hitting the button.

I was just hoping for some direction from forum-goers here in codeforum.org with regards to how you would go about programming a 'multi-user' object that interacts with everyone viewing the page. Because I'm not sure quite how to describe a 'multi-user' function, I've found it difficult to search resources specific to this kind of challenge.

If I have an idea as to what I could use to implement this, I can dive into that.

Thanks in advance!

Richard.
 
Hi RJForbes,
Without having much experience in web development, I would say that you would have to use PHP on the server side and AJAX with JS on the client side. Using AJAX, the client will be able to ask the server if the bell has been ringed, without refreshing the page.
With PHP, you can make the server keep track of wheter the bell is currently ringed or not.
 

New Threads

Buy us a coffee!

Back
Top Bottom