 |
 | interpreting what is php code and is debuggable |  |
Joined: 28 Jun 2006 |
Posts: 92 |
|
|
 |
Posted: Tue Nov 14, 2006 12:05 pm |
|
 |
 |
 |
 |
Difference between lines containing debuggable PHP code and those that do not; improper detection of what is considered debuggable...
Example in the code block:
<div class="node<?php if ($sticky) { print " sticky"; } ?><?php if (!$status) { print " node-unpublished"; } ?>">
<?php if ($picture) {
print $picture;
}?>
|
the line:
has PHP code in it, but because it is not already containing with a <?php script block open tag occurring before the start of the line, the gui doesn't let me click on the line number to set a break point. I can get around it both by moving the <?php opening tag up a line or right-clicking and choosing "Toggle Breakpoint" and it works fine, but I think the debugger should be able to be set by clicking normally as well...
thanks
|
|
 |
 | |  |
Site Admin
Joined: 13 Jul 2003 |
Posts: 8361 |
|
|
 |
Posted: Tue Nov 14, 2006 6:35 pm |
|
 |
 |
 |
 |
there are no bugs with that:)
From php perspectives and from the IDE perspectives as well, all those code chunks are on the same line.
Since breakpoint can be set on a line, not on code chunk, it will be set to the line and trigger as soon as code is executed on that line.
To make code chunks distinguishable, put them on different lines or better don't use this approach altogether and switch to templates like Smarty  (just a recommendation)
|
_________________ The PHP IDE team
|
 |
 | simple bug, still persists |  |
Joined: 28 Jun 2006 |
Posts: 92 |
|
|
 |
Posted: Wed Feb 07, 2007 3:26 pm |
|
 |
 |
 |
 |
dmitri- I am certain this is a bug, and it still exists in the 4633 release. Here is a sample snippet of code that can be used to verify:
</a>
<a href="/functchooser.php" class="<?php echo((isCurrentPage("funct")) ? " selected" : ""); ?>">Functions
<div class="showhide">Functions, documents, and contact information organized by Function</div>
|
There are three lines above (browser-wrap may make it appear as more, but there are only three line breaks). The 2nd line contains a single-line php island. The expected behavior is that clicking into the gutter while the cursor is between the <? and ?> will set a red dot/breakpoint on the line. This doesn't happen. Instead, the cursor just hops to position column 1.
thanks
|
|
 |
 | |  |
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
|
|
|
|  |