php-console icon indicating copy to clipboard operation
php-console copied to clipboard

Sub-domains support

Open barbushin opened this issue 10 years ago • 7 comments

Add PhpConsole\Connector::setBaseDomain($domain) so authorization credentials and client/server cookies must be initialized to be available for all sub-domains.

barbushin avatar Apr 04 '14 08:04 barbushin

Thanks @barbushin. If I have time before you I'll digg into this, but I didn't look enough in the actual code to help quickly so I'm not sure I'll get to wok on this quickly

huafu avatar Apr 04 '14 11:04 huafu

I think tho here the problem are not only the cookies. What if I have a cross-domain enabled server on api.someserver.com and my frontend is at ui.anotherserver.com. There is no way to set a cookie for ANY domain ;-)

huafu avatar Apr 04 '14 11:04 huafu

I understand. So for now there is only one workaround - open all that domains in browser tab. PHP Console will initialize connection, so then it will works with any AJAX requests.

barbushin avatar Apr 04 '14 14:04 barbushin

Well as I explained in the issue #47 doing that does not resolve the issue even temporally :-s

huafu avatar Apr 04 '14 14:04 huafu

Ha, I got it, I am using Lagger and had ALSO php-console... Lagger seems to be too old :cry: and not compatible with the new php-console... Is Lagger kept by side? If yes, what do you suggest me to use instead?

huafu avatar Apr 07 '14 14:04 huafu

Yes, Lagger is very old :) but you can use it with PHP Console. There will be no conflict. Also, if you want to use something more new, I can send you my last Lagger modification. It's more lightweight and flexible. I'll send it to you on email today, and share on GitHub soon.

barbushin avatar Apr 07 '14 14:04 barbushin

That'd be cool. I have to not hide you that I began to look into monolog, tho it's a bit heavy, but I am interested by the browser console, the Rollbar, file logging, and some other modules like the computed handlers, ...

huafu avatar Apr 07 '14 19:04 huafu