NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Ability to exclude specific PHP files from debugging session


Joined: 14 Apr 2006
Posts: 33
Reply with quote
I have an upload monitor script that runs via AJAX every 750ms as the file is uploading, needless to say when I'm debugging this spawns a new debugger instance every time the script runs, which when uploading a 2MB file is rather a lot (really causes a lot of pain!)

What would be good is if there was a way via the IDE to tell PHPEd NOT to debug this file. It still wants to run, but just not in debugging mode, thus when the upload finishes and runs the form's action PHP file, the debugger starts up again.

_________________
Regards

Steve.
View user's profileFind all posts by MGSteveSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8334
Reply with quote
You need to avoid debug session for the script that you don't want to debug. In this case, just append DBGSESSID=-1 argument to the URL and it won't trigger the debugger.

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


Joined: 14 Apr 2006
Posts: 33
Reply with quote
dmitri wrote:
You need to avoid debug session for the script that you don't want to debug. In this case, just append DBGSESSID=-1 argument to the URL and it won't trigger the debugger.
Yeah, but its fired automatically then I'd need to edit the Javascript source which fires off the Ajax request... I'd rather not do that if possible, reduces the chances of forgetting to remove the change when a site goes live...

_________________
Regards

Steve.
View user's profileFind all posts by MGSteveSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8334
Reply with quote
Then uncheck "stop on the first line" in the debugger settings and all the sessions in the background will start and complete transparently.

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


Joined: 14 Apr 2006
Posts: 33
Reply with quote
dmitri wrote:
Then uncheck "stop on the first line" in the debugger settings and all the sessions in the background will start and complete transparently.
But what happens if you want to debug the script that fires when the file upload has completed!? I just want to skip the script that runs that checks the progress of the file upload and returns the progress stats to the html page, these requests go along as the file is uploading. Problem is at 750ms gaps you end up with nearly 100 requests queued up by the time the file upload completes!

Ah! Just realised, but if I put a breakpoint at the start of the file that runs when the upload is complete (i.e. the form's action) then it would stop on the breakpoint, but as long as there aren't any breakpoints set in the upload progress check file then that would simply run ....

I'll give it a try, nice one!

_________________
Regards

Steve.
View user's profileFind all posts by MGSteveSend private message
Ability to exclude specific PHP files from debugging session
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