[PHP-DB] $_SERVER
Is there a predefined variable that will tell me the resolution of the browser that is looking at my site? EXAMPLE 1024 X 768 OR 800 X 600 Ron
Re: [PHP-DB] $_SERVER
Ron Piggott (PHP) wrote: Is there a predefined variable that will tell me the resolution of the browser that is looking at my site? You have to do this through javascript, php can't capture that information. -- Postgresql php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] list field from .dbf
Rafael Ramdhani wrote: Dear All, i need convert my data from .dbf ( visual foxpro ) to mysql database first at all i open .dbf and list the field some error with function dbase_get_record it's not support list field ( memo type ) my list data have lost where field type is memo may help me to get field (memo) STW: http://forums.mysql.com/read.php?126,2051,9940 -- Postgresql php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] moving a selection of records from one table to another (identical in structure) table?
Hi all! What is the best/easiest way to use PHP to move a selection of MySQL records from one table to another table, which is in the same database and which has the same structure as the first table? Greetings, Evert -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] moving a selection of records from one table to another (identical in structure) table?
Hi Easiest way would be to have MySQL to do it, using an INSERT ... SELECT statement Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] moving a selection of records from one table to another (identical in structure) table?
Hi Easiest way would be to have MySQL to do it, using an INSERT ... SELECT statement ... and if you're moving (not just copying) deleting the selected records after of course. Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: moving a selection of records from one table to another (identicalin structure) table?
Evert wrote: Hi all! What is the best/easiest way to use PHP to move a selection of MySQL records from one table to another table, which is in the same database and which has the same structure as the first table? here's a stab at it (not tested): $ids_to_get(1,3,5,6,8); $q=mysql_query( 'select * from from_table where id='.join(' or id=',$ids_to_get).'' ); while($r=mysql_fetch_array($q)){ $fields=array(); foreach($r as $k=$v)$fields[]='`'.$k.'`='.addslashes($v); echo('insert into to_table set '.join(',',$fields).'br /'); # mysql_query('insert into to_table set '.join(',',$fields)); } obviously, first try the above to make sure the SQL looks right, before you uncomment the line that does the damage Kae -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: moving a selection of records from one table to another (identicalin structure) table?
Evert wrote: Hi all! What is the best/easiest way to use PHP to move a selection of MySQL records from one table to another table, which is in the same database and which has the same structure as the first table? here's a stab at it (not tested): $ids_to_get(1,3,5,6,8); $q=mysql_query( 'select * from from_table where id='.join(' or id=',$ids_to_get).'' ); while($r=mysql_fetch_array($q)){ $fields=array(); foreach($r as $k=$v)$fields[]='`'.$k.'`='.addslashes($v); echo('insert into to_table set '.join(',',$fields).'br /'); #mysql_query('insert into to_table set '.join(',',$fields)); } obviously, first try the above to make sure the SQL looks right, before you uncomment the line that does the damage Kae -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: moving a selection of records from one table to another (identical in structure) table?
Would you happen to have a nice little example-script for me/us? :-) Regards, Evert Niel Archer wrote: Hi Easiest way would be to have MySQL to do it, using an INSERT ... SELECT statement ... and if you're moving (not just copying) deleting the selected records after of course. Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Re: moving a selection of records from one table to another (identical in structure) table?
Hi Would you happen to have a nice little example-script for me/us? :-) yup, here's a little example: $condition = WHERE username LIKE 'm%' if (mysql_query(INSERT AuthCopy SELECT * FROM Auth $condition)) mysql_query(DELETE FROM Auth $condition); This assumes the two tables are identical with regard to column order/type but not name, and that you want to copy and remove the data from the first table. The whole operation is performed by the MySQL server, so requires almost zero processing by PHP and should be faster. However, it also means you don't get to verify each insert as it is made, but that should not be a major problem. Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] OCI calls with segmentation fault
I am running on that server Entrp. Oracle10g (installed on the server )on SLES 9 SUSE Linux with apache_1.3.35/ php-4.4.2 Web visitors retrieve datahttp://www.codecomments.com/PHP_Programming/message1053354.html#from the web by php calls through oci cobnnection from 10g release2 PHP is configured with the following parameters './configure' '--prefix=/opt/oracle/php' '--with-apxs=/opt/oracle/apache/bin/apxs' '--with-config-file-path=/opt/oracle/apache/conf' '--enable-safe-mode' '--enable-session' '--with-oci8=/opt/oracle/product/10gR2' '--enable-sigchild' '--with-zlib-dir' '--with-unixODBC=shared,/usr' Apache is configured ./configure --enable-module=so --prefix=$HOME/apache --with-port= I found in the apachehttp://www.webservertalk.com/Apache_Server_configuration_support_54.htmerror log the following entries [Mon Sep 11 10:47:32 2006] [notice] child pid 6758 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 10:49:21 2006] [notice] child pid 7287 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 10:53:45 2006] [notice] child pid 7387 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 10:53:46 2006] [notice] child pid 7276 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 10:56:16 2006] [notice] child pid 7334 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 10:59:21 2006] [notice] child pid 8138 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 11:01:08 2006] [notice] child pid 6883 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 11:06:04 2006] [notice] child pid 8102 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 11:07:22 2006] [notice] child pid 8392 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 11:07:22 2006] [notice] child pid 8652 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache [Mon Sep 11 11:16:18 2006] [notice] child pid 8915 exit signal Segmentation fault (11), possible coredump in /opt/oracle/apache --- i have done gdb this mu output: [EMAIL PROTECTED]:~/apache/bin gdb ~/apache/bin/httpd ~/apache/core GNU gdb 6.3 Copyright 2004 Free Softwarehttp://www.codecomments.com/PHP_Programming/message1053354.html#Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copieshttp://www.codecomments.com/PHP_Programming/message1053354.html#of it under certain conditions. Type show copyinghttp://www.codecomments.com/PHP_Programming/message1053354.html# to see the conditions. There is absolutely no warranty for GDB. Type show warranty for details. This GDB was configured as i586-suse-linux...Using host libthread_db library /lib/libthread_db.so.1. Core was generated by `/opt/oracle/apache/bin/httpd'. Program http://www.codecomments.com/PHP_Programming/message1053354.html#terminated with signal 11, Segmentation fault. warning: current_sos: Can't read pathname for load maphttp://www.codecomments.com/PHP_Programming/message1053354.html#: Input/output error Reading symbols from /usr/lib/libInternalSymbols.so...done. Loaded symbols for /usr/lib/libInternalSymbols.so Reading symbols from /lib/i686/libm.so.6...done. Loaded symbols for /lib/i686/libm.so.6 Reading symbols from /lib/libcrypt.so.1...done. Loaded symbols for /lib/libcrypt.so.1 Reading symbols from /opt/oracle/product/10gR2/lib/libexpat.so.0...done. Loaded symbols for /opt/oracle/product/10gR2/lib/libexpat.so.0 Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /lib/i686/libc.so.6...done. Loaded symbols for /lib/i686/libc.so.6 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /lib/i686/libpthread.so.0...done. Loaded symbols for /lib/i686/libpthread.so.0 Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 Reading symbols from /opt/oracle/apache/libexec/libphp4.so...done. Loaded symbols for /opt/oracle/apache/libexec/libphp4.so Reading symbols from /lib/libz.so.1...done. Loaded symbols for /lib/libz.so.1 Reading symbols from /lib/libresolv.so.2...done. Loaded symbols for /lib/libresolv.so.2 Reading symbols from /lib/libnsl.so.1...done. Loaded symbols for /lib/libnsl.so.1 Reading symbols from /opt/oracle/product/10gR2/lib/libclntsh.so.10.1...done. Loaded symbols for /opt/oracle/product/10gR2/lib/libclntsh.so.10.1 Reading symbols from /opt/oracle/product/10gR2/lib/libnnz10.so...done. Loaded symbols for /opt/oracle/product/10gR2/lib/libnnz10.so #0 zend_hash_find (ht=0x0, arKey=0x81c38bc resp_charset, nKeyLength=13, pData=0xbfffae74) at /opt/oracle/php-4.4.2/Zend/zend_hash.h:196 196 while (arKey arEnd) { (gdb) bt #0 zend_hash_find
[PHP-DB] Search engine
Has anyone wrote a search engine for the web site? I am wondering if someone has the time to help me walk through doing this. Ron