Using APE with PHP

I'm a little confused about how APE (Ajax Push Engine) works.

  • How do you know what kind of connection you need to make to make sure that the user is right from the PHP application?
  • Is this an apache extension? Independent server? Etc ...

Some explanations would be awesome, thanks!

+4
source share
2 answers

APE uses an independent HTTP / Comet server, which allows, for example, long polling. It requires some configuration on the Apache server running next to it. It uses javascript as a server structure for module development.

In the client part, it uses the javascript framework, which receives information sent by the APE server, processes data and sends user requests. When the page loads, a new client is created using var client = new APE.Client(); , and from this moment the client connects to the server.

More info here

+5
source

Regarding 1) You cannot directly click on a user.

What you can do with PHP is called "built-in push". Basically you need to call the FROM PHP command on the APE server, passing the information you want to publish to ALONG, with som information for the APE WHOM server to enter the data.

This requires you to track registered users on the APE server (preferably through a username / login). APE itself does not have any login information for connected users, you need to create some functions for this.

A blog post about what's around this topic can be found here: http://www.xosofox.de/2010/10/ape-user-handling/

+1
source

Source: https://habr.com/ru/post/1342726/


All Articles