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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T11:52:22+00:00 2026-05-23T11:52:22+00:00

So I have another project that I built a few months ago. It currently

  • 0

So I have another project that I built a few months ago. It currently uses jquery with ajax and makes a call to a php script every 30 seconds. The php script queries mysql and passes back the results to display. In this application the person has the ability to add/edit/remove records from the db and when they do the list of results from the db needs to update the list they see. So far it seems to do the job, but looking down the road the db will get bigger and it will need to be more in real time, meaning not just refresh every 30 seconds but as instantaneous as possible.

Would socket.io be the answer to this? Would I simply use socket.io with nodejs to create a server and emit events to query my db and return the results to display? Then on the client side just have a function that calls the server socket script like every second? Would that be the correct path to using socket.io? If so would there be a concern with this process if I ran it every second with regards to server resources?

  • 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-23T11:52:22+00:00Added an answer on May 23, 2026 at 11:52 am

    Would socket.io be the answer to this?

    My answer is that socket.io / node.js is much better at dealing with real-time applications then PHP in the current form.

    Then on the client side just have a
    function that calls the server socket
    script like every second?

    In node.js you should not poll ask for the information, but instead you should have the information pushed(use redis pubsub or node.js events for that) to you. I advice you to have a look at a pubsub snippet from me on stackoverflow.com to explain myself a little bit. For the code to work you will need to install socket.io 0.6.x(0.6.18) because the latest socket.io 0.7.x has a slightly different API.

    If so would there be a concern with
    this process if I ran it every second
    with regards to server resources?

    Like I said before use pubsub semantics. You could for example use:

    • redis pubsub
    • events
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a .NET project which references another assembly that is built outside of
I have a very old project that includes the source from another project directly,
I have an RMI server that is using a class from another project. I
I have a maven project A which uses jar files of another project B
I have built a few custom applications that run on WSS 3 using the
I have a project that I am developing built off CodeIgniter. The main part
I have a an installer that is created from a setup project and built
I have an ASP.NET web application project which references another project called ModusCore (or
I build a project in C#. From another project I have 5 DLLs. Is
I have a project which I am trying to use in another new project,

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.