Re: [PHP] php 5.0.5 segfaults apache2 on ubuntu, 5.0.4 ok
I think this could be related to your _destruct method Can't you just rely on the parent class destruct method? Sorry to be a bit vague, I'll look into it a little further. Jon I've just installed php 5.0.5 to newest ubuntu breezy and apache2 started (sometimes) segfaulting (teste two computers with ubuntu hoary and ubuntu breezy - same results). -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php 5.0.5 segfaults apache2 on ubuntu, 5.0.4 ok
Accessing this page means immeadiate apacha segfault and actual connection close. Anybody please test this on 5.0.5 and verify if it's reproducible. I am running PHP 5.0.5 on Apache 2 and get the following in my error log if I include the destruct method. Jon *** glibc detected *** /usr/local/apache/bin/httpd: free(): invalid pointer: 0x09bdca78 *** === Backtrace: = /lib/libc.so.6[0x2a1424] /lib/libc.so.6(__libc_free+0x77)[0x2a195f] /usr/local/apache/modules/libphp5.so(my_no_flags_free+0x16)[0x1284da6] /usr/local/apache/modules/libphp5.so(vio_delete+0x29)[0x12a20a9] /usr/local/apache/modules/libphp5.so(end_server+0x3a)[0x129e74a] /usr/local/apache/modules/libphp5.so(cli_advanced_command+0x129)[0x129e569] /usr/local/apache/modules/libphp5.so(mysql_close+0x4d)[0x12a079d] /usr/local/apache/modules/libphp5.so[0x11573b3] /usr/local/apache/modules/libphp5.so(zend_objects_store_call_destructors+0x45)[0x125f091] /usr/local/apache/modules/libphp5.so(shutdown_destructors+0x51)[0x1241f15] /usr/local/apache/modules/libphp5.so(zend_call_destructors+0x49)[0x124c8d9] /usr/local/apache/modules/libphp5.so(php_request_shutdown+0x3fa)[0x121acd6] /usr/local/apache/modules/libphp5.so[0x127d87e] /usr/local/apache/bin/httpd(ap_run_handler+0x3a)[0x80b6a1a] /usr/local/apache/bin/httpd(ap_invoke_handler+0x56)[0x80b6d92] /usr/local/apache/bin/httpd(ap_process_request+0x141)[0x809e929] /usr/local/apache/bin/httpd[0x809a36d] /usr/local/apache/bin/httpd(ap_run_process_connection+0x3a)[0x80c04c2] /usr/local/apache/bin/httpd[0x80b51ba] /usr/local/apache/bin/httpd[0x80b53a3] /usr/local/apache/bin/httpd[0x80b5436] /usr/local/apache/bin/httpd(ap_mpm_run+0x7b4)[0x80b5bf8] /usr/local/apache/bin/httpd(main+0x57f)[0x80baec7] /lib/libc.so.6(__libc_start_main+0xc6)[0x252de6] /usr/local/apache/bin/httpd(apr_dbm_get_usednames_ex+0xbd)[0x807bad1] === Memory map: [Fri Oct 21 16:00:59 2005] [notice] child pid 3808 exit signal Aborted (6) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] currency class?
Hi Does anyone know of a simple PHP Currency Class that is similar to the one in Java (java.util.currency)? I just need something that will provide methods such as getSymbol() and getDefaultFractionDigits() regards Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] novice: char to varchar
You can't mix CHAR and VARCHAR types in the same table. jon On Wednesday 18 May 2005 19:15, tony yau wrote: Hi all, I try to do the following: CREATE TABLE IF NOT EXISTS Invoice( PKey INTEGER, Received DATETIME, Cost DECIMAL(10,2), FileName VARCHAR(50), RefNum CHAR(10), PRIMARY KEY (PKey) ) TYPE=MyISAM COMMENT='Invoice Data'; but it keep generating RefNum VARCHAR(10) instead of CHAR(10) I don't understand, please help (or point me to RTFM page) Tony Yau -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Is it possible to save a file with UTF-8 encoding and noBOM using PHP?
1. First I want to know how to make the actual binary file that is written, to be encoded as UTF-8. This is my PRIMARY question. I think this part is the key. If the string originated from your text editor, then your text editor needs to be in UTF-8 mode. If you are importing the data from a file or database then you need to be sure that the data is UTF-8 encoded. If you know that the encoding is instead ISO-8859-1 then you can convert it to UTF-8 with the php function utf_encode. fwrite will then write out the bytes that you presented to it. I guess the same applies in reverse when you read the file back in to the application that will view the text. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Path to ImageMagick??
The two programmes you will probably use are called 'convert' and 'mogrify' Usually found in /usr/bin if you are running Linux. Cyril On Thursday 25 November 2004 13:35, Aaron Wolski wrote: Hey all, How can I find out the path ImageMagick on my server the php is running on? Need it for a software and I don't know where to look. Phpinfo() tells me nothing. Thanks! Aaron -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] session.use_trans_sid
Hello I have a site that has session.use_trans_sid = 1. It seems that the first time I visit a page when I open up my browser, URLs are getting rewritten even though a cookie IS being set. If I refresh or move on to another page, the problem goes away, i.e. no more session ids appended to URLs. I don't want to turn off trans_sid for this site because I want people to able to use it without cookies being set. For example ?php session_start(); ? html head body a href=index.phplink/a /body /html The first time I request the page, a cookie gets set, AND the URL gets rewritten. After that, no more URL rewrites. Can anyone point to where I might be going wrong, or this just an odd behaviour of session.use_trans_sid = 1 Cyril -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Help: Database Search
You might want to try looking up the syntax for left join queries. I think this might be what you are after. http://dev.mysql.com/doc/mysql/en/JOIN.html On Wednesday 10 November 2004 14:37, Stuart Felenstein wrote: I am creating a database search form and results. Running into a problem though. I have two form elements, both that are fed by tables that have int values (1, 2 , etc) my sql statement is such: SELECT vendorjobs.PostStart, vendorjobs.JobTitle, vendorjobs.Industry, vendorjobs.VendorID, vendorjobs.LocationCity, vendorjobs.TaxTerm FROM vendorjobs WHERE vendorjobs.Industry = '$Ind' AND Date_Sub(Curdate(), interval '$Days' day) = PostStart But if the user decides to only use one of the elements, then I don't want the query to return nothing because of the And in the where clause so I have these 2 statements that set a default value (shown here as 0 in the event one of the two elements aren't selected: (Having no luck as the form still only works correctly if I've set both elements) $Ind = 0; if (isset($_POST['Ind'])) { $Ind = (get_magic_quotes_gpc()) ? $_POST['Ind'] : addslashes($_POST['Ind']); } $Days = 0; if (isset($_POST['Days'])) { $Days = (get_magic_quotes_gpc()) ? $_POST['Days'] : addslashes($_POST['Days']); Thank you , Stuart -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] problem compiling with openssl support
Hi I cannot manage to compile openssl support into php. my configuration line is CPPFLAGS='-I/usr/local/include/' ./configure --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr --with-gettext-dir=/usr --with-gd --with-png-dir=/usr --with-zlib-dir=/usr --with-jpeg-dir=/usr --with-gd-native-ttf --enable-magic-quotes --enable-calendar --enable-ftp --enable-wddx --with-openssl=/usr configure always complains that it cannot find evp.h evp.h IS located in /usr/local/include/openssl I have tried a vairety of variations to try and get it to work. Perhaps I have not set CPPFLAGS properly or I need something else? hope someone can show me the way. Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] problem compiling with openssl support
cheers Adam, that now works Jon On Wednesday 17 December 2003 13:29, Adam Maas wrote: Jon Hill wrote: Hi I cannot manage to compile openssl support into php. my configuration line is CPPFLAGS='-I/usr/local/include/' ./configure --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr --with-gettext-dir=/usr --with-gd --with-png-dir=/usr --with-zlib-dir=/usr --with-jpeg-dir=/usr --with-gd-native-ttf --enable-magic-quotes --enable-calendar --enable-ftp --enable-wddx --with-openssl=/usr configure always complains that it cannot find evp.h evp.h IS located in /usr/local/include/openssl I have tried a vairety of variations to try and get it to work. Perhaps I have not set CPPFLAGS properly or I need something else? hope someone can show me the way. Jon Your last flag is incorrect. --with-openssl needs to be /usr/local It's looking in /usr/include for evp.h Adam -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] wddx in sessions
Hi I came across some strange session behaviour today using latest version of php under apache 1.3.29 on redhat 9. I am using a customer handler for the sessions, a simple mysql table. I am finding that the session data intermitently switches to wddx serialisation rather than the deault method. It appears to be random and I only noticed when I ever so often I got SQL errors due to the single quotes in the WDDX. There appeared to be no pattern to the behaviour. My php.ini file is set to php not wddx and I have not used ini_set in my script to alter the default. Has anyone seen anything similar? Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] php daemon
I have just been trying to work out the behaviour of running a php programm from BASH. If i execute ./my_program.php /var/log/mylog 21 and then terminate the controlling terminal I get a background process which has no controlling terminal, a parent process id of 1 and the process becomes a session leader and process group leader. Everything looks in order as far as this being a proper daemon. So, my question is, is this all correct and the same as running a daemon in say C? Just opening a discussion really to help in my education. regards Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] comparison efficieny
I am sure I read somewhere that doing the following if (false === $variable) was a better option than if ($variable === false) maybe it was a dream or is there something in this? Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php