At 10:03 AM -0700 3/31/09, Dennis sent email regarding Re: PHP 
Formatting, Syntax Checking, Pasting Non-Breaking S:
>On Mar 31, 2009, at 9:18 AM, Warren Michelsen wrote:
>
>>  Does BBEdit have the ability to format and syntax check php code as 
>>  it does html code?
>
>No, but syntax checking can be easily added:
>
>http://daringfireball.net/2003/12/php_syntax_checking_in_bbedit

I've been playing with the php syntax check that is called from the 
command line (via the script linked above) and it usually gets the 
line number wrong. Sometimes high, sometimes low. I think that 
comments, or perhaps lines without a ";" confuse it.

All the script does is get the error message from the CLI syntax 
checker and report it. It's usually wrong on my code, which includes 
comments.

The script does this:
                                set errors_found to true
                                set msg to paragraph 2 of err_text
                                set line_num to (last word of msg as integer)

As noted, line_num is usually off by 1-3 lines. At least it's in the 
ballpark...

FWIW, my php:
php -v
PHP 5.2.6 (cli) (built: Jul 17 2008 23:04:49)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "BBEdit Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a specific feature request or would like to report a suspected (or 
confirmed) problem with the software, please email to "[email protected]" 
rather than posting to the group.
-~----------~----~----~----~------~----~------~--~---

Reply via email to