Hi Sir,
i have already read the documentation.
It's not logic what you said.
you told me to write:
>  $session = new Session("localhost", 1984, "admin", "admin");
and to run baseX server with 8984 port

ok, i'm following you.
but my php files are not on local pc. they are in other server and i want to execute them from there.
what you told me is correct if i just want to call php file remotely when it is place in the same server with BaseX server.
This is what i have:

- 1 hosting server (i bought a space with a domain name): i have put my php file+ baseX php  client in this sever.
- My Pc (running BaseX server on 8984 port) i have already made a NAT in my router and everyone can access my pc with public IP of my router
So my problem is how to run my php file to execute xquery query in my pc which contain BaseX.

I'm doing all that becaue my hosting server do not allow me to install BaseX on it.
and i do not want to put my php file in my pc, because it must be executed in hosting server,
only the part of xquery query must be send to my pc to be executed.

I don't know if i have described well my problem.
Thank you 




De : Christian Grün <christian.gruen@gmail.com>
À : Mohamed kharrat <med_khr@yahoo.fr>
Cc : BaseX <basex-talk@mailman.uni-konstanz.de>
Envoyé le : Mercredi 15 juin 2016 10h02
Objet : Re: [basex-talk] question about http server

>  $session = new Session("PUBLIC_IP", 8984, "admin", "admin");

And like I said: Read our documentation ;) You are using the HTTP port
instead of the database port.

> That's why i'm looking to someone to test it in his own server with his own
> ip to find the problem.

Wouldn’t help.




> ________________________________
> De : Christian Grün <christian.gruen@gmail.com>
> À : Mohamed kharrat <med_khr@yahoo.fr>
> Cc : BaseX <basex-talk@mailman.uni-konstanz.de>
> Envoyé le : Mercredi 15 juin 2016 8h49
>
> Objet : Re: [basex-talk] question about http server
>
> You need to use 8984 for the HTTP Server and 1984 for the database
> server. – Please find some more details in our documentation, I hope
> this gives you some more insight.
>
>
> On Wed, Jun 15, 2016 at 9:45 AM, Mohamed kharrat <med_khr@yahoo.fr> wrote:
>> in the actual script, it's configured at 8984 port  for remote testing.
>> But i have used 1984 port when i have tested locally, it's working of
>> course.
>> What i'm looking for is the test remotely
>>
>>
>> ________________________________
>> De : Christian Grün <christian.gruen@gmail.com>
>> À : Mohamed kharrat <med_khr@yahoo.fr>
>> Cc : BaseX <basex-talk@mailman.uni-konstanz.de>
>> Envoyé le : Mercredi 15 juin 2016 6h28
>>
>> Objet : Re: [basex-talk] question about http server
>>
>> Are you sure that your code works locally? You seem to address the BaseX
>> server with the HTTP address (8984), and you should probably use 1984.
>> Am 15.06.2016 2:51 vorm. schrieb "Mohamed kharrat" <med_khr@yahoo.fr>:
>>
>> Anyone can please try to execute the file remotely?
>>
>> ________________________________
>> De : Mohamed kharrat <med_khr@yahoo.fr>
>> À : Christian Grün <christian.gruen@gmail.com>
>> Cc : "basex-talk@mailman.uni-konstanz.de"
>> <basex-talk@mailman.uni-konstanz.de>
>> Envoyé le : Mardi 7 juin 2016 17h47
>> Objet : Re: [basex-talk] question about http server
>>
>> can you please now see in attachement the php file containing the
>> connexion
>> of baseX ?
>> it do not work for me, it show me (cannot communicate with server)
>>
>>
>>
>> ________________________________
>> De : Christian Grün <christian.gruen@gmail.com>
>> À : Mohamed kharrat <med_khr@yahoo.fr>
>> Cc : "basex-talk@mailman.uni-konstanz.de"
>> <basex-talk@mailman.uni-konstanz.de>
>> Envoyé le : Mardi 7 juin 2016 17h39
>> Objet : Re: [basex-talk] question about http server
>>
>> It both works for me.
>>
>> A little hint: Better try to avoid posting private URLs to the list.
>>
>>
>> On Tue, Jun 7, 2016 at 6:27 PM, Mohamed kharrat <med_khr@yahoo.fr> wrote:
>>> Can you please try this 2 adress and tell me what you get?
>>>
>>> http://197.0.28.226:8984
>>>
>>> and
>>> http://197.0.28.226:80
>>>
>>> Thanks
>>>
>>> ________________________________
>>> De : Christian Grün <christian.gruen@gmail.com>
>>> À : Mohamed kharrat <med_khr@yahoo.fr>
>>> Cc : "basex-talk@mailman.uni-konstanz.de"
>>> <basex-talk@mailman.uni-konstanz.de>
>>> Envoyé le : Mardi 7 juin 2016 11h07
>>> Objet : Re: [basex-talk] question about http server
>>>
>>> Hi Mohamed,
>>>
>>> This sounds like a general port issue, it’s probably not strictly
>>> related to BaseX. Did you check your firewall?
>>>
>>> Regards,
>>> Christian
>>>
>>>
>>> On Mon, Jun 6, 2016 at 5:23 PM, Mohamed kharrat <med_khr@yahoo.fr> wrote:
>>>> Hi,
>>>> i have setted my pc as server over TinyWeb
>>>> i have everything ok.
>>>> i opened in  my pc  8984 port.
>>>> if i execute my php file containing xquery query locally, it works but
>>>> if i execute it remotely over the ip and port, it show me this message:
>>>> can't communicate with server.
>>>>
>>>> Anyone have an idea about that?
>>>>
>>>> Thanks
>>>>
>>>
>>>
>>
>>
>>
>>
>>
>>
>
>