[PHP] php, eclipse, dbg, oh my

2006-06-04 Thread Tod Thomas

Eclipse - 3.1.2
Linux   - 2.6.16-1.2111_FC4
PHP - 5.1.2, I built it.
DBG - 2.13.1, I tried the binary, then built it on my own
Apache  - 2.0.55, I built it. PHP is running as a module but I've 
configured Eclipse to use the standard PHP5 executable instead.



I wonder if anyone has gotten Eclipse debugging of PHP to work under 
Linux and if so what was used - dbg or some other tool?


I've read pretty much of the available documentation, and tried most of 
the contained suggestions but nothing has worked yet.  A lot of the 
suggestions are also geared towards windows users running Eclipse on 
that platform.


Everything seems to be firing up but I get no presentation in the 
debugger screen except for the console which indicates my program ran 
and all the breakpoints were ignored.


Any ideas?


Thanks - Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Metric Conversion Library

2006-05-29 Thread Tod Thomas
Before I write my own, is there a php math library that will perform US 
to metric conversions and the like?



Thanks - Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] xml to array

2006-02-05 Thread Tod Thomas

Brian V Bonini wrote:

On Fri, 2006-02-03 at 16:23, Richard Lynch wrote:


I've got my money on the XML spec REQUIRING an alphabetic start to
tagnames, and subsequent characters can be alphanumeric...

In other words, it doesn't work because 0 is not a valid XML tag.




Yeah, that was my instinct too... Just could not find anything to
confirm it after a quick browse through the spec. Though can you find
anything in the spec via a quick browse.. ;-)

However, after a closer look I still can't find (at least in plain
English) anything that says this is NOT OK. Though the parser does
return '[xml_error] = not well-formed (invalid token)'.

Good stuff

-Brian




Just a quick shot it the dark...

http://www.w3.org/TR/REC-xml/#NT-Name

Go up about a half page to this:

[Definition: A Name is a token beginning with a letter or one of a few 
punctuation characters, and continuing with letters, digits, hyphens, 
underscores, colons, or full stops, together known as name characters.] 
Names beginning with the string xml, or with any string which would 
match (('X'|'x') ('M'|'m') ('L'|'l')), are reserved for standardization 
in this or future versions of this specification


From quick read maybe if you wrap the numbers in quotes that might work?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP5 Build - test.php not working

2006-02-02 Thread Tod Thomas

Richard Lynch wrote:

On Mon, January 30, 2006 8:08 pm, Tod Thomas wrote:


I just built phpV5.1.2 with the same options I used to build php4:

./configure  --prefix=/opt/php5
--with-apxs2=/opt/apache/bin/apxs
--with-mysql=/opt/mysql
--disable-cgi --with-zlib

After make install I had libphp5.so in the ./apache/modules directory
as
expected.  I commented out my LoadModule directive for php4 and
uncommented out the directive for php5.  I copied php.ini-dist to
/opt/php5/lib/php.ini and restarted apache.

I expected the test.php page that displays the date, time and the
output
of phpinfo() to work.  Instead it just prints out all of the text,
never
interpreting the code.

When I switch it back to php4 everything works fine.  Neither the
access
or error logs display any problems.  ldd of libphp5.so shows everthing
as resolved.  The apache user owns that lib as well as liphp4.so so no
problems there.  httpd -t says everthing is syntactically correct.
I've
really changed nothing other than the library and its name in
httpd.conf.

What else could I be doing wrong?  Is there something I can try to
debug
and get it to tell me what's up?



I think your add-handler would only work for PHP as CGI...



#LoadModule php4_modulemodules/libphp4.so
LoadModule php5_modulemodules/libphp5.so
AddHandler php-script .php

These are the only php directives I have in my httpd.conf.  The only 
change I've made is to comment out the php4 and add the php5 directive. 
 The AddHandler never changed.  I also had not compiled php4 with cgi 
capabilities, the same as I did with php5 above.


I've heard from a trusted source that they had a lot of problems with 
php5, including mysql 4* not working with it and ended up reverting back 
the php4* series.  I'm considering that now but I thought that since 5 
has been out for a while; and since its oop capabilities have been 
improved, I would like to stick with it.


I'll continue to look into it...


Thanks - Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP5 Build - test.php not working - Solved

2006-02-02 Thread Tod Thomas

Tod Thomas wrote:

I just built phpV5.1.2 with the same options I used to build php4:

./configure  --prefix=/opt/php5
--with-apxs2=/opt/apache/bin/apxs
--with-mysql=/opt/mysql
--disable-cgi --with-zlib

After make install I had libphp5.so in the ./apache/modules directory as 
expected.  I commented out my LoadModule directive for php4 and 
uncommented out the directive for php5.  I copied php.ini-dist to 
/opt/php5/lib/php.ini and restarted apache.


I expected the test.php page that displays the date, time and the output 
of phpinfo() to work.  Instead it just prints out all of the text, never 
interpreting the code.


When I switch it back to php4 everything works fine.  Neither the access 
or error logs display any problems.  ldd of libphp5.so shows everthing 
as resolved.  The apache user owns that lib as well as liphp4.so so no 
problems there.  httpd -t says everthing is syntactically correct.  I've 
really changed nothing other than the library and its name in httpd.conf.


What else could I be doing wrong?  Is there something I can try to debug 
and get it to tell me what's up?



Thanks.


LoadModule php4_modulemodules/libphp4.so  - for php4
LoadModule php5_modulemodules/libphp5.so  - for php5
.
.
.
AddHandler php-script php- for php4
AddHandler php5-script php   - for php5   grrr


Thanks for everyone's comments.


Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP5 Build - test.php not working

2006-02-01 Thread Tod Thomas

Richard Correia wrote:

can you try httpd -v,
 
which all dynamic modules are listed?
 


Sorry I took so long.  -v just displays the version.  This provides what 
you asked for I think:


/httpd -e debug
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
access_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
actions_module

[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module alias_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module asis_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module auth_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
autoindex_module

[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module cgi_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module dir_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module env_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module imap_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
include_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
log_config_module

[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module mime_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
negotiation_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
setenvif_module
[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module 
userdir_module

[Tue Jan 31 18:11:38 2006] [debug] mod_so.c(248): loaded module php5_module


So its loading.  I wonder if its something in my php.ini?   I'm going to 
look.



Thanks - Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP 5 Backwards Compatability

2006-01-30 Thread Tod Thomas
Is their a list of portability problems to be aware of when switching 
from v4 to v5?  Maybe a table that compares the two?


Thanks.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP5 Build - test.php not working

2006-01-30 Thread Tod Thomas

I just built phpV5.1.2 with the same options I used to build php4:

./configure  --prefix=/opt/php5
--with-apxs2=/opt/apache/bin/apxs
--with-mysql=/opt/mysql
--disable-cgi --with-zlib

After make install I had libphp5.so in the ./apache/modules directory as 
expected.  I commented out my LoadModule directive for php4 and 
uncommented out the directive for php5.  I copied php.ini-dist to 
/opt/php5/lib/php.ini and restarted apache.


I expected the test.php page that displays the date, time and the output 
of phpinfo() to work.  Instead it just prints out all of the text, never 
interpreting the code.


When I switch it back to php4 everything works fine.  Neither the access 
or error logs display any problems.  ldd of libphp5.so shows everthing 
as resolved.  The apache user owns that lib as well as liphp4.so so no 
problems there.  httpd -t says everthing is syntactically correct.  I've 
really changed nothing other than the library and its name in httpd.conf.


What else could I be doing wrong?  Is there something I can try to debug 
and get it to tell me what's up?



Thanks.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP5 Build - test.php not working

2006-01-30 Thread Tod Thomas

Richard Correia wrote:

I think your webserver is not treating .php as script file.
 
AddType application/x-httpd-php .php
 
http://www.weberdev.com/Manuals/PHP/install.windows.apache2.html
 
The above instructions are for windows, but you will get the idea.
 
Thanks,

Rich



I thought about doing that but I already had an AddHandler directive 
that took care of php.  I expect if that was the problem it would have 
presented itself when I first installed php4.


But I tried it and got the same result.


Thanks - Tod

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php