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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T23:52:43+00:00 2026-06-12T23:52:43+00:00

Is there any advantages to developing one with WebSockets rather than AJAX? I went

  • 0

Is there any advantages to developing one with WebSockets rather than AJAX? I went through google and haven’t found a single example on how to make AJAX calls to a C# server.

Also how would I create session server side for players and be able to know which ajax call is from which player?

  • 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-12T23:52:45+00:00Added an answer on June 12, 2026 at 11:52 pm

    Your question is made up of several ones so I’ll answer them one by one

    1. Is there any advantages to developing one with WebSockets rather than AJAX?

    Yes, but you need to strongly consider your use case. WebSocket should be used if the webpage needs to pass a lot of messages to the server and vice versa. AJAX should be used for retrieval of data. As mentioned by Kolink, that means AJAX is suited well for turn-based games and WebSocket’s advantage is with dealing with real-time communication.

    There is also a middle ground called Comet. This technique uses AJAX to accomplish something close to WebSockets, but it represents an abuse of HTTP protocol and is one of the reasons WebSocket was created.

    The three diagrams below should further illustrate the differences. They are a representation of how these technologies are used if you need to create a bi-directional communication channel between the webpage visitor and your server:

    AJAX:

    enter image description here

    Comet:

    enter image description here

    WebSocket:

    enter image description here

    2. I went through google and haven’t found a single example on how to make AJAX calls to a C# server.

    Try either of these two:

    • Alchemy
    • XSockets

    Ooops, you asked about AJAX. I am not very familiar with C#, but the best way would probably be to have an ASP.NET script to which you make an AJAX call. There is nothing special that has to be done on the server side to support AJAX.

    3. Also how would I create session server side for players and be able to know which ajax call is from which player?

    This can be accomplished by authenticating each AJAX call with a client ID. Sometimes they’re also called tokens. If you use an existing implementation it is probably going to have a mechanism to do that.

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

Sidebar

Related Questions

Are there any advantages using box functions, such as array_map , rather than writing
Are there any advantages of using one over the other besides readability?
Is there any advantages/disadvantages to either of these statements over the other one: <?php
When developing for Alfresco, are there any advantages to using the MMT over Integrated
Are there any advantages or disadvantages to using multiple assignment in a statement? In
Are there any advantages of Loaders over Async task? Also, how to make loaders
Are there any inherent advantages or disadvantages when it comes to handling DDoS attacks
Is there any advantage of using XAMPP compiled with VC9 as compared to one
Are there any advantages of storing entire files in an RDBMS over storing the
Are there any advantages and/or disadvantages to using either JCache (JSR 107) or the

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.