NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
problem with AJAX


Joined: 01 Jul 2011
Posts: 7
Reply with quote
Hello,

I've just moved from ZEND IDE to phpEd, and phpED is far much better that ZEND IDE!!

I've just found a small bug, which has a workaround.

If you select "debug next page" and "debug session", from IE9, you expect the next page to be launched from the IDE in debug mode.
For instance, if I have a link in a web page to another web page, then If I click the link, it should launch the IDE with the targeted page.
I confirm it works.

Now If I have a button that call a PHP page with AJAX; I would expect the same.
It does not work. The page is called without the IDE/debugger.

I've found a workaround.
You press refresh, then you press the button.
The "refresh" will just refresh the current web page (BTW without the debug mode wich is strange as I have selected "debug next page", probably the current page is not seen as a "next page" ).
When you press the button, it launches the targeted php page in the IDE.

Did you notice the same?

thanks
rod
View user's profileFind all posts by webrodSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
I think it does not matter you work with IE 9 or IE 6. The problem is that the browser events aren't fired upon refresh or ajax (HTTPXml) requests. Without these events, toolbar does not see that you're loading the page/or xml, so it does add debugger cookie and the session won't trigger as a result.
I'll check what can be done in the next version. Meanwhile, please contact support ( http://www.nusphere.com/contact_us ) and provide simple samples demonstrating the problem.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 01 Jul 2011
Posts: 7
Reply with quote
ok thanks, I will do it.

I'm sure you can find a solution, because it is working well with the debug toolbar of IDE.
FYI I also had problems with the "debug session" checkbox.
Sometimes, it may happen that it is not possible to leave this mode. You can unselect this option from the toolbar, but still each page starts the debug mode from the IDE.
Restarting the brwoser, or deleting the cache/cookies or restarting apache and so on does not fix this issue.
Only a restart of the PC fix the issue.

Thanks
Rod
View user's profileFind all posts by webrodSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Rod, It's not necessary to turn PC off to get cookies cleaned. Just close browser process and all cookes won't survive.
Closing a window may not help because temporary cookies belong to process, not to window.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 01 Jul 2011
Posts: 7
Reply with quote
dmitri wrote:
Rod, It's not necessary to turn PC off to get cookies cleaned. Just close browser process and all cookes won't survive.
Closing a window may not help because temporary cookies belong to process, not to window.


I didn't say that I turned the PC off to clean the cookies.

I said that I cleaned off the cookies (using from IE "internet options" ->"browsing history" -> delete...) and it didn't solve the issue.
So the issue is not link to the cookies.

Then I said that the only way to fix the issue is to restart the PC.

Thx
Rod
View user's profileFind all posts by webrodSend private message
Guru master

Joined: 24 Jul 2009
Posts: 737
Reply with quote
Occasionally I do have problems getting the debugger to kick in, so I temporarily add a DebugBreak() to work around the problem. Some people don't like using DebugBreak() in their code as it will cause the PHP code to load on a system without DBG installed, but use with care and it certainly works well.

I think NuSphere DBG uses session cookies and they probably would not be cleared by deleting browser history. Exiting all instances of the browser should clear session cookies and that certainly works for me with all the browsers that I use. For example, having two separate Internet Explorer windows means session cookies may stay active if either one of those remains open.
View user's profileFind all posts by plugnplaySend private message


Joined: 01 Jul 2011
Posts: 7
Reply with quote
plugnplay wrote:
Occasionally I do have problems getting the debugger to kick in, so I temporarily add a DebugBreak() to work around the problem. Some people don't like using DebugBreak() in their code as it will cause the PHP code to load on a system without DBG installed, but use with care and it certainly works well.

I think NuSphere DBG uses session cookies and they probably would not be cleared by deleting browser history. Exiting all instances of the browser should clear session cookies and that certainly works for me with all the browsers that I use. For example, having two separate Internet Explorer windows means session cookies may stay active if either one of those remains open.


in my stuation, I closed all the IE instances, and still have the problem.
I will test what you said.
Hope they can fix this bug.

Thanks
Rod
View user's profileFind all posts by webrodSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Deleting cookies should help, but it's NOT what would be addressed to NuSphere

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 27 Jul 2011
Posts: 6
Location: Northern VA
Reply with quote
I made StopDBG.php
Code:
<?
header('Set-Cookie: DBGSESSID=false; path=/; expires=saturday, 25-Sep-99 12:12:30 gmt;');  //not sure you need expires date
setcookie("DBGSESSID",false,0,'/');
unset($_COOKIE['DBGSESSID']);
?>


This worked for me, I had the same issue. DebugBreak() didn't help with this issue.
View user's profileFind all posts by intellilogicSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Did you try to turn off Run->Debug session?
Essentially it does the same on the client and works good for IE and embedded Mozilla.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website
problem with AJAX
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic