[PHP] Get the string between custom delimiters
Is there a nice easy function that could be used to get a sub string that lies in between two other sub strings in one big string. For example... get the text that lies in between title and /title (without the quotes) in the code of a web page. I'm after a function like: string getstring_between_customdelimiters(string source, string open_delimiter, sting close_delimiter) Or something that could be easily be used in that manner. Case insensitive if possible! Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Temporary directory for GD functions
We use Php4 with the dynamic graphic functions (GD). Our server is Apache on windows NT. One of the graphic function (imagePNG)creates a temporary file in the directory c:/. We would like to know if it is possible to have this file created in an other directory (ex : c:/temp). Thanks for your help. Sarto Beaudoin Professeur Departement d'informatique College du Vieux-Montreal -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] why isn't get_browser() not working?
hello. i'm trying to detect what browser version is there...i'm using get_browser() as it was documented: $t = get_browser(); var_dump($t); and all i can get like output is: bool(false) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] session array :-/
Hi, I'm having trouble with a two dimensional array with sessions. Following is an example of my code which is split between three pages. ### myFunctions.php ### function addToMyArray($newStuff) { global $myArray; $myArray[]=array(id=$newStuff[myId],name=$newStuff[name]); } ### mainPage.php ### session_start(); include(myFunctions.php); $myArray=array(); session_register(myArray); // add some stuff to myArray here to highlight the prob $myArray[]=array(id=1,name=gabby); $myArray[]=array(id=2,name=marla); .. // if conditions meet addToMyArray($HTTP_POST_VARS); // code to open myOtherWindow.php in a new window. // code to submit a form whos action is PHP_SELF ### myOtherWindow.php ### session_start(); // code to display contents of myArray -- Now on first call to addToMyArray() I have three elements two that I added directly and one via the function call. Now if the function gets called again there is still only 3 elements .. two that I added directly and the third one from the latest function call. The element from the first call has simply vanished !!! And that's my problem, why is the element vanishing ??? Thanx, Christian -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PHP4, APACHE, SCO INFORMIX
Hi Everyone, Firstly, apologies for cross posting but I wanted to make sure this got to the relevant people. I am continually getting people asking me off list for information regarding building the above combination. I don't mind as it's encouraging to see PHP spreading to this type of platform. All I ask is that if anyone requires help then please direct it to the PHP-Install list so others may benefit from the replies given. I will try to compile a complete install guide when I get time and perhaps one of the PHP associated sites would be able to host it. It maybe an idea for others to contribute with their particular build so that a centrally managed install guide could be set up and perhaps free up some of the traffic on the lists? Best regards, - Paul - -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Loading PHP module on Win98
The dbase module you are trying to install does not match the version of php. If you get the extension from the same distribution as the php modules then it should work. You can get the full distribution zip for 4.0.4pl1 from the downloads page at www.php.net at the moment. You may be able to get 4.0.5 later today if all goes to plan. Cheers PS When you do get it working you still may have problems since you have configured PWS to use the ISAPI module which you may find to be pretty unstable. I would advise use of the CGI version of PHP if things are a bit flakey. -- Phil Driscoll Dial Solutions +44 (0)113 294 5112 http://www.dialsolutions.com http://www.dtonline.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Split Weirdness.
Why does this work : $categorySplit = split(,, $row['category']); while (list($key, $value) = each ( $categorySplit )) { $categoryArray[$value] = 1; } But this not : while (list($key, $value) = each ( split(,, $row['category']) )) { $categoryArray[$value] = 1; } I keep getting Maximum execution time of 30 seconds exceeded errors. Thanks in advance. Nick. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] backends
Anybody here make their own news scripts? If so would you mind giving me a download url or sending it to me? I would appreciate anything like that. Thanks. -chris
Re: [PHP] backends
hmm? you want our own scripts? you want to run some sort of script repository ? anyway, you can always check my site from time to time for new scripts... -elias http://eassoft.cjb.net chris herring [EMAIL PROTECTED] wrote in message 002701c0d157$0883f700$26b2fea9@socialoutkast">news:002701c0d157$0883f700$26b2fea9@socialoutkast... Anybody here make their own news scripts? If so would you mind giving me a download url or sending it to me? I would appreciate anything like that. Thanks. -chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PHP 4.0.3 : Sessions history.back() : a solution ?
Well, I suppose it's a well known problem, but I haven't found a solution yet... As you know, when you don't use sessions, you can use the back button of your browser, or the javascript commande history.back(). In the same time, you don't have to put some nocache header to have your dynamic pages refreshed when it change. Well. This very good. The back button use cache, but when you reload a page, it never take it from the cache (except the images). But when you use session, it's got wrong (as you can see, my English is a little bit approximate) With the session_cache_limiter at nocache in the php.ini, in most case, the back button don't work anymore. And if I set the session_cache_limiter to private, the back button work fine, but on the other hand, when you reload a page, it take it from the cache, until you make a hard reload. Not cool. :+/ So, somebody can explain me why the fact of using sessions change the functioning of the cache ? And is there a solution ? Thanks a lot. :+) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] cannot use a full URL in a 401 ErrorDocument directive --- ignoring!
Hello, big,big problem ! What is this in my httpd.error.log! My only different to an other surfer is i've installed php4 on this machine snooter -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Loading PHP module on Win98
Dunno, it sounds silly, but just assuming... Does it happen that you know Micheal Driscoll? He works for Land Rover UK? Phil Driscoll [EMAIL PROTECTED] wrote in message 008001c0d153$debbbc30$0c01a8c0@philsntserver">news:008001c0d153$debbbc30$0c01a8c0@philsntserver... The dbase module you are trying to install does not match the version of php. If you get the extension from the same distribution as the php modules then it should work. You can get the full distribution zip for 4.0.4pl1 from the downloads page at www.php.net at the moment. You may be able to get 4.0.5 later today if all goes to plan. Cheers PS When you do get it working you still may have problems since you have configured PWS to use the ISAPI module which you may find to be pretty unstable. I would advise use of the CGI version of PHP if things are a bit flakey. -- Phil Driscoll Dial Solutions +44 (0)113 294 5112 http://www.dialsolutions.com http://www.dtonline.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] crypting a database
There al RC4 crypt/decrypt class here: Class Made By Mukul Sabharwal [[EMAIL PROTECTED]] http://www.devhome.net/php/ On October 21, 2000 kind regards, bill hollett Augusto Cesar Castoldi wrote: Hi, Anyone have some function to crypt and text then decrypt? regards, Augusto Cesar Castoldi -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] phpMyAdmin user administration script for you
If any of you use phpMyAdmin a while back when the new version came out I designed a User Admin for it. Which makes adding new users and assigning them permissions a simple 3 second job You can check it out at http://www.2tonecafe.com/scripts/useradmin/ Regards, Ian LeBlanc Web Development Rask, Inc. - www.rask.com Phone: (727) 517-2000 Fax: (727) 517-2001 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] why isn't get_browser() not working?
-Original Message- From: elias [mailto:[EMAIL PROTECTED]] Sent: Monday, April 30, 2001 1:05 PM To: [EMAIL PROTECTED] Subject: [PHP] why isn't get_browser() not working? hello. i'm trying to detect what browser version is there...i'm using get_browser() as it was documented: $t = get_browser(); var_dump($t); and all i can get like output is: bool(false) According to http://php.net/manual/en/function.get-browser.php, the get_browser() function looks up its information in a browscap.ini file. I'd start by making sure that you actually have a browscap.ini, and that your copy of PHP is configured properly to be able to locate it. --- Mark Roedel ([EMAIL PROTECTED]) || There cannot be a crisis next week. Systems Programmer / WebMaster || My schedule is already full. LeTourneau University ||-- Henry Kissinger -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Get the title from an HTML page
I'll be loading the contents of an HTML page into a variable and I need to get the title of the from that variable. Basically I need to ge the text from in between the title tags. Any ideas? Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] LDAP Authentication
Hello, I am trying ot understand how could a PHP script authenticate against a LDAP tree (NDS) that is not in the same host? Anyone has an example about that? TIA Rom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Best Practice-HTML In Database
-Original Message- From: John Monfort [mailto:[EMAIL PROTECTED]] Sent: Sunday, April 29, 2001 10:40 PM To: [EMAIL PROTECTED] Subject: [PHP] Best Practice-HTML In Database Hello everyone, I'm curious. Which is the better practice? 1) Insert the HTML page (...HTML code) in the database ? or 2) Insert a URL in the database field, that points to the HTML page? why? Will you ever want to do database-ish things with the contents of the page? (Allow somebody to search for words or phrases in the body, for example?) --- Mark Roedel ([EMAIL PROTECTED]) || There cannot be a crisis next week. Systems Programmer / WebMaster || My schedule is already full. LeTourneau University ||-- Henry Kissinger -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] About MS SQL
Hi all !! I'm trying to connecto to MS SQL Database I receive this error MSG Fatal error: Call to undefined function: mssql_connect() in C:\Inetpub\wwwroot\myphp\sqltest.php on line 13 The line 13 is $Conn=mssql_connect(,,); Thanks in advanced !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Problem with Sablot/PHP4
I want to parse XML with XSL for XHTML output with PHP4 and I have two problems: (1) How to make XSLT for output in ISO-8859-2 instead of UTF-8? I tried in different ways but Sablotron always returned errors. (2) How to get more usefull informations about errors. For instance, if I have any syntax error in xsl file my browser get only useless information: Fatal error: msgtype: error file.php on line 51 (where the number is only for xslt_process($xslData, $xmlData, $result)) -- Yarek -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] About MS SQL
Think you might need to enable the ms sql server module in the php.ini file. -- Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / Hassan Arteaga [EMAIL PROTECTED] wrote in message 7F548E90E63BD1118E4600609707771F8BEFF9@goliath">news:7F548E90E63BD1118E4600609707771F8BEFF9@goliath... Hi all !! I'm trying to connecto to MS SQL Database I receive this error MSG Fatal error: Call to undefined function: mssql_connect() in C:\Inetpub\wwwroot\myphp\sqltest.php on line 13 The line 13 is $Conn=mssql_connect(,,); Thanks in advanced !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] About MS SQL
Thaks Romulo..but I think I have MS SQL the only problem that I talking about MS SQL 2000..What can I do ? ___ ;Windows Extensions ;Note that MySQL and ODBC support is now built in, so no dll is needed for it. ; extension=php_mssql70.dll _ Thanks !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] About MS SQL
Ok...I have to try with the ODBC functions ? Thanks !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] recipients list
recipients list Regards, Ian LeBlanc Web Development Rask, Inc. - www.rask.com Phone: (727) 517-2000 Fax: (727) 517-2001 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Php + mysql - How to turn off threaded client code
Dear All, I have been trying to install php-4.0.4pl1 on RH 6.2 with mysql-3.23.37. I have loaded mysql-3.23.37-1.i386.rpm, mysql-client-3.23.37-1.i386.rpm and mysql-devel-3.23.37-1.i386.rpm. Everything goes well except until libphp4.so is loaded by apache. Then apache dumps. If I comment this line containing libphp4.so reference, apache works fine. I have seen from the FAQs(4.5) that this problem can be corrected if you recompile from the source rpm and remove the switch in the spec file that turns on the threaded client code. Can anyone give me some more details how this is to be done? regards Vimal -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] why isn't get_browser() not working?
You have a browsecap.ini file and it is in the correct location? At 11:04 AM 4/30/01 -0700, elias wrote: hello. i'm trying to detect what browser version is there...i'm using get_browser() as it was documented: $t = get_browser(); var_dump($t); and all i can get like output is: bool(false) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PHP 4.0.3 : Sessions history.back() : a solution ?
There is a functions called session_cache_limiter(). Use this function before you output anything (or use ob_start(), if you would like) Regards, -- Yasuo Ohgaki Matthieu Brunet [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Well, I suppose it's a well known problem, but I haven't found a solution yet... As you know, when you don't use sessions, you can use the back button of your browser, or the javascript commande history.back(). In the same time, you don't have to put some nocache header to have your dynamic pages refreshed when it change. Well. This very good. The back button use cache, but when you reload a page, it never take it from the cache (except the images). But when you use session, it's got wrong (as you can see, my English is a little bit approximate) With the session_cache_limiter at nocache in the php.ini, in most case, the back button don't work anymore. And if I set the session_cache_limiter to private, the back button work fine, but on the other hand, when you reload a page, it take it from the cache, until you make a hard reload. Not cool. :+/ So, somebody can explain me why the fact of using sessions change the functioning of the cache ? And is there a solution ? Thanks a lot. :+) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] About MS SQL
For example if my SQL installation files are in c:\MSSQL what is the right configuration ? extension_dir=c:\MSSQL; Now I just made the job with ODBC functions but I would like to use SQL function !! thanks !!! -Original Message- From: Romulo Pereira [mailto:[EMAIL PROTECTED]] Sent: Monday, April 30, 2001 11:38 AM To: [EMAIL PROTECTED] Subject: RE: [PHP] About MS SQL Hello, Your php.ini is not configured correctilly. That is what is doing the php to do not include the MsSQL functions to the php api. Open your php.ini file and find (and correct) the section below: ; ; Paths and Directories ; ; ... extension_dir=./extensions; Your scripts should work then. Have fun, Rom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] lex error in make of PHP_4.0.2/Zend
Hi, I got problem while building PHP on Solaris8/SPARC. I tried buildconf, then configure and then make. I got stuch at make. But giving here the output of buildconf and configure also as it may help you to help me. moon:/workspace/trial/installserver/php_4.0.2/Zend 134 % \rm aclocal.m4 configure moon:/workspace/trial/installserver/php_4.0.2/Zend 135 % buildconf buildconf: created or modified aclocal.m4 buildconf: created or modified configure moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % configure loading cache ./config.cache checking for a BSD compatible install... ./../install-sh -c checking whether build environment is sane... yes checking whether make sets ${MAKE}... (cached) yes checking for working aclocal... found checking for working autoconf... found checking for working automake... found checking for working autoheader... found checking for working makeinfo... missing checking whether build environment is sane... yes checking whether to enable maintainer-specific portions of Makefiles... no checking for gcc... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) works... yes checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) is a cross-compiler... no checking whether we are using GNU C... (cached) no checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc accepts -g... (cached) yes checking how to run the C preprocessor... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc -E checking for flex... (cached) lex checking for flex... (cached) lex checking for yywrap in -ll... (cached) yes checking lex output file root... (cached) lex.yy checking whether yytext is a pointer... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to accept ANSI C... (cached) none needed checking for bison... (cached) bison -y checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc and cc understand -c and -o together... (cached) yes checking for ANSI C header files... (cached) yes checking bison version... 1.28 (ok) checking for limits.h... (cached) yes checking for malloc.h... (cached) yes checking for string.h... (cached) yes checking for unistd.h... (cached) yes checking for stdarg.h... (cached) yes checking for sys/types.h... (cached) yes checking for signal.h... (cached) yes checking for unix.h... (cached) no checking for dlfcn.h... (cached) yes checking for size_t... (cached) yes checking return type of signal handlers... (cached) void checking for dlopen in -ldl... (cached) yes checking for dlopen... (cached) yes checking for uint... (cached) yes checking for ulong... (cached) yes checking for vprintf... (cached) yes checking for 8-bit clean memcmp... (cached) yes checking for working alloca.h... (cached) yes checking for alloca... (cached) yes checking for memcpy... (cached) yes checking for strdup... (cached) yes checking for getpid... (cached) yes checking for kill... (cached) yes checking for strtod... (cached) yes checking for strtol... (cached) yes checking for finite... (cached) yes checking whether sprintf is broken... (cached) no checking for finite... (cached) yes checking for isfinite... (cached) no checking for isinf... (cached) no checking for isnan... (cached) yes checking whether fp_except is defined... (cached) no checking host system type... sparc-sun-solaris2.8 checking build system type... sparc-sun-solaris2.8 checking for ranlib... (cached) ranlib checking for non-GNU ld... (cached) /usr/ucb/ld checking if the linker (/usr/ucb/ld) is GNU ld... (cached) no checking for BSD-compatible nm... (cached) /usr/ccs/bin/nm -p checking whether ln -s works... (cached) yes loading cache ./config.cache within ltconfig checking whether we are using GNU C... no checking for object suffix... o checking for executable suffix... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to produce PIC... -KPIC checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc PIC flag -KPIC works... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.o... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.lo... no checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc static flag -Bstatic works... none checking if the linker (/usr/ucb/ld) is GNU ld... no checking whether the linker (/usr/ucb/ld) supports shared libraries... yes checking command to parse /usr/ccs/bin/nm -p output... ok checking how to hardcode library paths into programs... immediate checking for /usr/ucb/ld option to reload object files... -r checking dynamic linker characteristics... solaris2.8 ld.so checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for objdir... .libs creating libtool loading cache ./config.cache checking whether to
Re: [PHP] About MS SQL
from what i recall there is a line (to enable ms sql server support) in the php.ini file already that just needs uncommenting. have a look right through the file...there's one for sql server 6.5 and one for 7. -- Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / Hassan Arteaga [EMAIL PROTECTED] wrote in message 7F548E90E63BD1118E4600609707771F8BF005@goliath">news:7F548E90E63BD1118E4600609707771F8BF005@goliath... For example if my SQL installation files are in c:\MSSQL what is the right configuration ? extension_dir=c:\MSSQL; Now I just made the job with ODBC functions but I would like to use SQL function !! thanks !!! -Original Message- From: Romulo Pereira [mailto:[EMAIL PROTECTED]] Sent: Monday, April 30, 2001 11:38 AM To: [EMAIL PROTECTED] Subject: RE: [PHP] About MS SQL Hello, Your php.ini is not configured correctilly. That is what is doing the php to do not include the MsSQL functions to the php api. Open your php.ini file and find (and correct) the section below: ; ; Paths and Directories ; ; ... extension_dir=./extensions; Your scripts should work then. Have fun, Rom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Command Line
how do access arguments if I run a script from the command line example php myscript.php arg1, arg2 thanks randy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: RE: RE: [PHP] About MS SQL
I did it ..But nothing Thanks !!! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] lex error in make of PHP_4.0.2/Zend
You are best off using flex instead of your system lex. You can download it from ftp.gnu.org Andi At 07:59 AM 4/30/2001 -0700, Surinder Singh wrote: Hi, I got problem while building PHP on Solaris8/SPARC. I tried buildconf, then configure and then make. I got stuch at make. But giving here the output of buildconf and configure also as it may help you to help me. moon:/workspace/trial/installserver/php_4.0.2/Zend 134 % \rm aclocal.m4 configure moon:/workspace/trial/installserver/php_4.0.2/Zend 135 % buildconf buildconf: created or modified aclocal.m4 buildconf: created or modified configure moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % configure loading cache ./config.cache checking for a BSD compatible install... ./../install-sh -c checking whether build environment is sane... yes checking whether make sets ${MAKE}... (cached) yes checking for working aclocal... found checking for working autoconf... found checking for working automake... found checking for working autoheader... found checking for working makeinfo... missing checking whether build environment is sane... yes checking whether to enable maintainer-specific portions of Makefiles... no checking for gcc... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) works... yes checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) is a cross-compiler... no checking whether we are using GNU C... (cached) no checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc accepts -g... (cached) yes checking how to run the C preprocessor... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc -E checking for flex... (cached) lex checking for flex... (cached) lex checking for yywrap in -ll... (cached) yes checking lex output file root... (cached) lex.yy checking whether yytext is a pointer... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to accept ANSI C... (cached) none needed checking for bison... (cached) bison -y checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc and cc understand -c and -o together... (cached) yes checking for ANSI C header files... (cached) yes checking bison version... 1.28 (ok) checking for limits.h... (cached) yes checking for malloc.h... (cached) yes checking for string.h... (cached) yes checking for unistd.h... (cached) yes checking for stdarg.h... (cached) yes checking for sys/types.h... (cached) yes checking for signal.h... (cached) yes checking for unix.h... (cached) no checking for dlfcn.h... (cached) yes checking for size_t... (cached) yes checking return type of signal handlers... (cached) void checking for dlopen in -ldl... (cached) yes checking for dlopen... (cached) yes checking for uint... (cached) yes checking for ulong... (cached) yes checking for vprintf... (cached) yes checking for 8-bit clean memcmp... (cached) yes checking for working alloca.h... (cached) yes checking for alloca... (cached) yes checking for memcpy... (cached) yes checking for strdup... (cached) yes checking for getpid... (cached) yes checking for kill... (cached) yes checking for strtod... (cached) yes checking for strtol... (cached) yes checking for finite... (cached) yes checking whether sprintf is broken... (cached) no checking for finite... (cached) yes checking for isfinite... (cached) no checking for isinf... (cached) no checking for isnan... (cached) yes checking whether fp_except is defined... (cached) no checking host system type... sparc-sun-solaris2.8 checking build system type... sparc-sun-solaris2.8 checking for ranlib... (cached) ranlib checking for non-GNU ld... (cached) /usr/ucb/ld checking if the linker (/usr/ucb/ld) is GNU ld... (cached) no checking for BSD-compatible nm... (cached) /usr/ccs/bin/nm -p checking whether ln -s works... (cached) yes loading cache ./config.cache within ltconfig checking whether we are using GNU C... no checking for object suffix... o checking for executable suffix... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to produce PIC... -KPIC checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc PIC flag -KPIC works... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.o... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.lo... no checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc static flag -Bstatic works... none checking if the linker (/usr/ucb/ld) is GNU ld... no checking whether the linker (/usr/ucb/ld) supports shared libraries... yes checking command to parse /usr/ccs/bin/nm -p output... ok checking how to hardcode library paths into programs... immediate checking for /usr/ucb/ld option to reload object files... -r checking dynamic linker characteristics... solaris2.8 ld.so checking if libtool supports shared libraries... yes checking whether to build shared
Re: [PHP] lex error in make of PHP_4.0.2/Zend
By the way, while you're at it get bison too (instead of YACC :) Andi At 07:59 AM 4/30/2001 -0700, Surinder Singh wrote: Hi, I got problem while building PHP on Solaris8/SPARC. I tried buildconf, then configure and then make. I got stuch at make. But giving here the output of buildconf and configure also as it may help you to help me. moon:/workspace/trial/installserver/php_4.0.2/Zend 134 % \rm aclocal.m4 configure moon:/workspace/trial/installserver/php_4.0.2/Zend 135 % buildconf buildconf: created or modified aclocal.m4 buildconf: created or modified configure moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % moon:/workspace/trial/installserver/php_4.0.2/Zend 136 % configure loading cache ./config.cache checking for a BSD compatible install... ./../install-sh -c checking whether build environment is sane... yes checking whether make sets ${MAKE}... (cached) yes checking for working aclocal... found checking for working autoconf... found checking for working automake... found checking for working autoheader... found checking for working makeinfo... missing checking whether build environment is sane... yes checking whether to enable maintainer-specific portions of Makefiles... no checking for gcc... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) works... yes checking whether the C compiler (/usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc ) is a cross-compiler... no checking whether we are using GNU C... (cached) no checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc accepts -g... (cached) yes checking how to run the C preprocessor... (cached) /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc -E checking for flex... (cached) lex checking for flex... (cached) lex checking for yywrap in -ll... (cached) yes checking lex output file root... (cached) lex.yy checking whether yytext is a pointer... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to accept ANSI C... (cached) none needed checking for bison... (cached) bison -y checking whether /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc and cc understand -c and -o together... (cached) yes checking for ANSI C header files... (cached) yes checking bison version... 1.28 (ok) checking for limits.h... (cached) yes checking for malloc.h... (cached) yes checking for string.h... (cached) yes checking for unistd.h... (cached) yes checking for stdarg.h... (cached) yes checking for sys/types.h... (cached) yes checking for signal.h... (cached) yes checking for unix.h... (cached) no checking for dlfcn.h... (cached) yes checking for size_t... (cached) yes checking return type of signal handlers... (cached) void checking for dlopen in -ldl... (cached) yes checking for dlopen... (cached) yes checking for uint... (cached) yes checking for ulong... (cached) yes checking for vprintf... (cached) yes checking for 8-bit clean memcmp... (cached) yes checking for working alloca.h... (cached) yes checking for alloca... (cached) yes checking for memcpy... (cached) yes checking for strdup... (cached) yes checking for getpid... (cached) yes checking for kill... (cached) yes checking for strtod... (cached) yes checking for strtol... (cached) yes checking for finite... (cached) yes checking whether sprintf is broken... (cached) no checking for finite... (cached) yes checking for isfinite... (cached) no checking for isinf... (cached) no checking for isnan... (cached) yes checking whether fp_except is defined... (cached) no checking host system type... sparc-sun-solaris2.8 checking build system type... sparc-sun-solaris2.8 checking for ranlib... (cached) ranlib checking for non-GNU ld... (cached) /usr/ucb/ld checking if the linker (/usr/ucb/ld) is GNU ld... (cached) no checking for BSD-compatible nm... (cached) /usr/ccs/bin/nm -p checking whether ln -s works... (cached) yes loading cache ./config.cache within ltconfig checking whether we are using GNU C... no checking for object suffix... o checking for executable suffix... (cached) no checking for /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc option to produce PIC... -KPIC checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc PIC flag -KPIC works... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.o... yes checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc supports -c -o file.lo... no checking if /usr/dist/share/devpro,v4.0/5.x/SC4.0/bin/cc static flag -Bstatic works... none checking if the linker (/usr/ucb/ld) is GNU ld... no checking whether the linker (/usr/ucb/ld) supports shared libraries... yes checking command to parse /usr/ccs/bin/nm -p output... ok checking how to hardcode library paths into programs... immediate checking for /usr/ucb/ld option to reload object files... -r checking dynamic linker characteristics... solaris2.8 ld.so checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to
Re: RE: RE: [PHP] About MS SQL
you might have to restart your webserver/php if it's apache you might need to recompile it or something...i've not compiled php into apache before...am using it as a cgi...so i'm not sure -- Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / Hassan Arteaga [EMAIL PROTECTED] wrote in message 7F548E90E63BD1118E4600609707771F8BF00A@goliath">news:7F548E90E63BD1118E4600609707771F8BF00A@goliath... I did it ..But nothing Thanks !!! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: RE: RE: [PHP] About MS SQL
No..is on Win98 with Persnal Web Server PC. Regards !! -Original Message- From: Matthew Ralston [mailto:[EMAIL PROTECTED]] Sent: Monday, April 30, 2001 12:32 PM To: [EMAIL PROTECTED] Subject: Re: RE: RE: [PHP] About MS SQL you might have to restart your webserver/php if it's apache you might need to recompile it or something...i've not compiled php into apache before...am using it as a cgi...so i'm not sure -- Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / Hassan Arteaga [EMAIL PROTECTED] wrote in message 7F548E90E63BD1118E4600609707771F8BF00A@goliath">news:7F548E90E63BD1118E4600609707771F8BF00A@goliath... I did it ..But nothing Thanks !!! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 30 Apr 2001 15:35:27 -0000 Issue 658
php-general Digest 30 Apr 2001 15:35:27 - Issue 658 Topics (messages 50824 through 50867): Best Practice-HTML In Database 50824 by: John Monfort 50825 by: Michael Hall 50826 by: Donald Goodwill 50848 by: Mark Roedel suggestion needed about du command run on PHP 50827 by: Mark Lo \(3\) why isn't get_browser() not working? 50828 by: elias 50845 by: Mark Roedel 50856 by: Joe Sheble (Wizaerd) session array :-/ 50829 by: Christian PHP4, APACHE, SCO INFORMIX 50830 by: Paul Gardiner Re: Loading PHP module on Win98 50831 by: Phil Driscoll 50839 by: elias Split Weirdness. 50832 by: Nick Davies 50834 by: Zak Greant backends 50833 by: chris herring 50835 by: elias PHP 4.0.3 : Sessions history.back() : a solution ? 50836 by: Matthieu Brunet 50857 by: Yasuo Ohgaki cannot use a full URL in a 401 ErrorDocument directive --- ignoring! 50837 by: Markus Held Security Issue 50838 by: Jim Persson Re: how to include() a string 50840 by: Zeev Suraski Re: crypting a database 50841 by: bill phpMyAdmin user administration script for you 50842 by: Ian LeBlanc Get the string between custom delimiters 50843 by: Matthew Ralston Temporary directory for GD functions 50844 by: Sarto Beaudoin Get the title from an HTML page 50846 by: Matthew Ralston LDAP Authentication 50847 by: Romulo Pereira About MS SQL 50849 by: Hassan Arteaga 50851 by: Matthew Ralston 50852 by: Hassan Arteaga 50853 by: Hassan Arteaga 50858 by: Hassan Arteaga 50860 by: Matthew Ralston 50862 by: Hassan Arteaga 50865 by: Matthew Ralston 50866 by: Hassan Arteaga Problem with Sablot/PHP4 50850 by: Yarek recipients list 50854 by: Ian LeBlanc Php + mysql - How to turn off threaded client code 50855 by: Vimal Uppal lex error in make of PHP_4.0.2/Zend 50859 by: Surinder Singh 50863 by: Andi Gutmans 50864 by: Andi Gutmans Command Line 50861 by: Randy Johnson Checking query suceeded 50867 by: Jordan Elver Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- Hello everyone, I'm curious. Which is the better practice? 1) Insert the HTML page (...HTML code) in the database ? or 2) Insert a URL in the database field, that points to the HTML page? why? Any help will be appreciated. Btw, thank you all for helping with my previous questions. ==FOLLOW-UP ==- = PHP Ultradev Browser Model == === FYI For those who care about the PHP-Ultradev Server Model (PHAKT). I finally got it to work. Everything works for MySQL. However, you have to make some manual changes for it to work with MS Access. The changes are as follow: 1) You have to add the 'Access' or 'ODBC' Connection Type, in the server model's CONNECTION File (accessed via Modify-Connection-New). To do so: a) open (from the Ultradev Configuration folder) Connection-PHP-Win-Connection_php_adodb.htm b) add the value pairs access/access, and/or odbc/odbc, to the dropdown list for 'Connection Type'. Without this, you can only select MySQL as the connection type. This means that ADOBD will use the wrong drivers to connect to your DB. 2) There is an ERROR in the ADODB ODBC configuration file. The ODBC file has a format error in the ODBC connection call. (Site Root Folder -ADODB-adodb-odbc.inc.php) The file tries to connect (to the DB) with $dbh = odbc_connect ('$hostname', $username,$password); That is an error. The correct format is $dbh = odbc_connect ('$DSN_NAME', $username, $password); You do not need to specify the host, for an ODBC connection. That information is already listed in the DSN description. Once that's done. You'll be able to use Ultradev with PHP. I hope that helped. -John Again, thanks to everyone who helped me find this extension. Don't forget my new question :) see above. __John Monfort_ _+---+_ P E P I E D E S I G N S www.pepiedesigns.com The world is waiting, are you ready? -+___+- If you ever need to update the HTML, option 2 will be a lot easier. Mick On Sun, 29 Apr 2001, John Monfort wrote: Hello everyone, I'm curious. Which is the better practice? 1) Insert the HTML page (...HTML code) in the database ? or 2) Insert a URL in the database field, that points
RE: [PHP] Get the title from an HTML page
You can find a function that does that at http://www.zend.com called Get Title Tag in the Code Gallery under the HTML catagory. -Original Message- From: Matthew Ralston [mailto:[EMAIL PROTECTED]] Sent: Monday, April 30, 2001 9:25 AM To: [EMAIL PROTECTED] Subject: [PHP] Get the title from an HTML page Basically I need to ge the text from in between the title tags. Any ideas? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] RE: Get the title from an HTML page
$title = substr(stristr($filetext, title), 7); $title = substr($title , 0, strpos($title , /title)); Tim Ward Senior Systems Engineer Please refer to the following disclaimer in respect of this message: http://www.stivesdirect.com/e-mail-disclaimer.html -Original Message- From: Matthew Ralston [mailto:[EMAIL PROTECTED]] Sent: 30 April 2001 14:25 To: [EMAIL PROTECTED] Subject: Get the title from an HTML page I'll be loading the contents of an HTML page into a variable and I need to get the title of the from that variable. Basically I need to ge the text from in between the title tags. Any ideas? Thanks, Matt [EMAIL PROTECTED] www.mralston.co.uk / -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] help me :)
Hello, i'm new in php but i have very difficult exercise i must make hierarchical menu witch can be released for example so : First i will get main menu : for example menu1, menu2, menu3... and these menu will have links (this must be released with a href=...) to others submenu : sub1, sub2, sub3 (each menu can have more than one sub menu), and these submenus will go deeper and deeper (depends from some parameters) so - the question is How to make recursive menu ? (menu mus be repaint after any click...) (I have an idea to make function that will produce recursive arrays...) P.S.sorry for poor english :) sincerely, Arvys.
[PHP] php 4.04pl1 ldap
Is LDAP support default or are there any ./configure options I need to know ? David
Re: [PHP] Command Line
Randy Johnson [EMAIL PROTECTED] wrote: how do access arguments if I run a script from the command line example php myscript.php arg1, arg2 They'll be located in the global array $argv[]. Include ?php phpinfo(); ? in your script to see how to access them. -- Steve Werby President, Befriend Internet Services LLC http://www.befriend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] php 4.04pl1 ldap
Walgamotte, David [EMAIL PROTECTED] wrote: Is LDAP support default or are there any ./configure options I need to know Take a look at './configure --help'. You need to configure --with-ldap. -- Steve Werby President, Befriend Internet Services LLC http://www.befriend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Update statement?
hey i'm working on a shopping cart..but have hit a snag whit this statement.. function modify_quantity($table, $session, $itemid, $quantity) { $sql = UPDATE $table SET quantity='$quantity' WHERE session='$session' AND itemid='$itemid'; mysql_query($sql); } if there is a value in the db field quantity then after the statement is executed it is set to 0 here is my calling code. if ($action == uq || $action == Update ){ modify_quantity($table,$session,$itemid,$quanity); } and the requested url. http://www.harborfresh.com/retail/cart.php?itemid=21591quantity=5action=Update any ideas? ~kurth -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Sort Question
Hello, I am doing a dir list of an ftp and using sort to sort the dir list alphabetically. What I am using now sorts it alphabetically but it sorts the capital letters then the lower case so a capital Z would come before a lower case a The Code I am using is: sort($complete_list); return $complete_list; Does someone know how I can sort an array alphabetically with the case insensitive sort? Thank You Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Checking query suceeded
Hi, If I'm doing more than one query on a page what is the best way to check if they all succeeded with out using transactions? TIA, Jord -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Update statement?
Kurth Bemis [EMAIL PROTECTED] wrote: function modify_quantity($table, $session, $itemid, $quantity) { $sql = UPDATE $table SET quantity='$quantity' WHERE session='$session' AND itemid='$itemid'; mysql_query($sql); Add 'echo $sql;' here (no quotes) and look at the output. If the RHS of quantity= is zero, then $quantity passed to modify_quantity is zero and that's the problem. if there is a value in the db field quantity then after the statement is executed it is set to 0 I think that $quantity is the problem. -- Steve Werby President, Befriend Internet Services LLC http://www.befriend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Update statement?:SOLVED
At 01:03 PM 4/30/2001, Steve Werby wrote: I hate the letter i :-) it was missing when i passed quantity to the function ~kurth Kurth Bemis [EMAIL PROTECTED] wrote: function modify_quantity($table, $session, $itemid, $quantity) { $sql = UPDATE $table SET quantity='$quantity' WHERE session='$session' AND itemid='$itemid'; mysql_query($sql); Add 'echo $sql;' here (no quotes) and look at the output. If the RHS of quantity= is zero, then $quantity passed to modify_quantity is zero and that's the problem. if there is a value in the db field quantity then after the statement is executed it is set to 0 I think that $quantity is the problem. -- Steve Werby President, Befriend Internet Services LLC http://www.befriend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] replace functions add \
Hello, I have a strange problem. I tried ereg_rplace and str_replace: $to_test = 'This is a test'; $to_test = str_replace (test,little test,$to_test); echo $to_test; the result is: This is a \little test Why does this happen? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP]OT, but dual-boot operating system question
Beware if you're using WinNT or Windows 2000. Neither one plays nice with LILO. At 01:41 PM 4/30/2001 -0400, Toby Miller wrote: Your safest bet would probably be to look into RedHat Linux. It's a fairly straight forward Linux distribution. It also includes the LILO boot loader which is one way to boot into more than one operating system on the same machine. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] COM
Hi all !! I have components i made in Visual Basic 6.0 and I would like to use with PHP. I need examples how to create intance from VB COM component... What function I have to use ? com_load - ??? com_invoke - ??? com_propget - ??? com_get - ??? com_propput - ??? com_propset - ??? com_set - ??? Thanks in advanced !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
Actually, not using a programming language is the point of template, since I do not want to expose anything other than some template 'variables' to the template. Steve At 5/1/2001 12:36 AM, Michael Kimsal wrote: Why not just use PHP in the template? That's kinda what it was made for. On Sun, 29 Apr 2001, Steven Haryanto wrote: Does anyone know a rather advanced template solution in PHP? At least one that supports loop and if (like HTML::Template), and directives/commands would be nice (like Perl's Template Toolkit). I am currently rolling my own, but still not happy with the result of the design. I'd be happy to use one that is already out there. Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] php suck
On Sunday 29 April 2001 12:54, idban secandri wrote: i found this when surfing this morning http://www.phpsucks.net/ The site www.phpsucks.net is running Apache/1.3.17-twelveHTTP (Unix) PHP/4.0.4pl1 on Linux. is it just me or is it a mirror of the old php site with the text 'Hyped text Bloatcessor' ? but there are a aspsucks.com, cfsucks.com (if that ever points to cold fusion), perlsucks.com (which is a pro-php site), lifesucks.com, wifesucks.com, isucks.com, sucks.com and god knows what sucks and sucks not dot-com. so I wouldn't exacly be offended if anyone though anything sucked dot com cause everyone thinks it sucks no matter how good it is :) -- php developer / CoreTrek AS| Besides, I think [Slackware] sounds Sandnes / Rogaland / Norway| better than 'Microsoft,' don't you? (By web: http://www.moijk.net/ | Patrick Volkerding) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
No, you're asking for something with loops and IFs. That's a programming language. On Tue, 1 May 2001, Steven Haryanto wrote: Actually, not using a programming language is the point of template, since I do not want to expose anything other than some template 'variables' to the template. Steve At 5/1/2001 12:36 AM, Michael Kimsal wrote: Why not just use PHP in the template? That's kinda what it was made for. On Sun, 29 Apr 2001, Steven Haryanto wrote: Does anyone know a rather advanced template solution in PHP? At least one that supports loop and if (like HTML::Template), and directives/commands would be nice (like Perl's Template Toolkit). I am currently rolling my own, but still not happy with the result of the design. I'd be happy to use one that is already out there. Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
See the philosophy behind HTML::Template for explanation on this: http://www.perlmonth.com/features/template/template.html?issue=11 Not everything with loops and IFs is a programming language. I would probably call PDF or RTF a programming language too if it were. Steve At 5/1/2001 01:10 AM, Michael Kimsal wrote: No, you're asking for something with loops and IFs. That's a programming language. On Tue, 1 May 2001, Steven Haryanto wrote: Actually, not using a programming language is the point of template, since I do not want to expose anything other than some template 'variables' to the template. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
I understand completely what you're getting at already, but PHP is designed to do what you're asking to do. I know there are valid reaons for stripped down implementations, but can't think of too many. And actually, I would consider RTF or PDF to be languages unto themselves. There's a full syntax to use to get specific results, and if you're throwing conditionals in there, or variables, it's hard to see how it's not a language. Maybe not full-featured, but a language nonetheless. On Tue, 1 May 2001, Steven Haryanto wrote: See the philosophy behind HTML::Template for explanation on this: http://www.perlmonth.com/features/template/template.html?issue=11 Not everything with loops and IFs is a programming language. I would probably call PDF or RTF a programming language too if it were. Steve At 5/1/2001 01:10 AM, Michael Kimsal wrote: No, you're asking for something with loops and IFs. That's a programming language. On Tue, 1 May 2001, Steven Haryanto wrote: Actually, not using a programming language is the point of template, since I do not want to expose anything other than some template 'variables' to the template. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] can someone debug this vote.php script for me?
Its just a warning error. You can get rid of it by defining the variable, or just change your error settings to not report warnings. -- phill Joe Truong [EMAIL PROTECTED] wrote in message 9ce21h$s1n$[EMAIL PROTECTED]">news:9ce21h$s1n$[EMAIL PROTECTED]... can some one debug this script for me... it say's Warning: Undefined variable: total in PHP_poll.php on line 63 thanxz alot!!! ?php // En: Begin PHP Code /*** ***\ * PHP Poll Version 1.0 * * Copyright 2000 Frederic TYNDIUK (FTLS) All Rights Reserved. * * E-Mail: [EMAIL PROTECTED] Script License: GPL * * Created 02/28/2000 Last Modified 02/28/2000 * * Scripts Archive at: http://www.ftls.org/php/ * ***/ // Necessary Variables: $RESULT_FILE_NAME = poll_data.txt; // En: Absolute path and name to file contain poll data. $QUESTION = How do you like this Script?; // En: Question Text. $ANSWER = array(Love it!, Like it!, Its okay.., I dislike it, I hate it..); // En: All answer. $IMG_DIR_URL = ./vote; // En: URL Directory of poll graphs. $REVOTE_TIME = 3600; // En: Time (second) after people can revote, use cookies. // End Necessary Variables section /*** ***/ if (!isset($vote) !isset($result)) { echo FORM METHOD=\POST\\n; echo TABLE CELLSPACING=0 CELLPADDING=2 BORDERCOLOR=#00 BORDER=1TRTDTABLE WIDTH=\100%\ BORDER=0\n; echo TRTH colspan=\3\$QUESTION/TH/TR\n; while (list($key, $val) = each($ANSWER)) { echo TRTD width=\2%\/TDTD align=\left\ width=\96%\INPUT TYPE=\radio\ NAME=\answer\ VALUE=\$key\ $val/TDTD width=\2%\/TD/TR\n; } echo TRTD align=\center\ colspan=\3\INPUT TYPE=\Submit\ NAME=\vote\ VALUE=\ Vote \\n; echo INPUT TYPE=\Submit\ NAME=\result\ VALUE=\ Result \/TD/TR\n; echo /TABLE/TD/TR/TABLE/FORM; } else { $file_array = file($RESULT_FILE_NAME); // or error(Can not open \$RESULT_FILE_NAME); // En: Save result if ($answer count($ANSWER) $vote) { if (count($file_array) count($ANSWER)) { $file_array = array(0\n, 0\n, 0\n, 0\n, 0\n, 0\n, 0\n, 0\n, 0\n, 0\n); } $old_answer = $file_array[$answer]; $old_answer = preg_replace(/\n\r*/, , $old_answer); $file_array[$answer] = ($old_answer + 1).\n; $file = join('', $file_array); $fp = fopen($RESULT_FILE_NAME, w); //or error(Can not write \$RESULT_FILE_NAME); flock($fp, 1); fputs($fp, $file); flock($fp, 3); fclose($fp); } // En: Display result while (list($key, $val) = each($file_array)) { $total += $val; } echo h2PHP Poll vote results :/h2; echo TABLE CELLSPACING=0 CELLPADDING=2 WIDTH=400 BORDERCOLOR=#00 BORDER=1; echo trthWhat/ththPercentage/ththVotes/th/tr; while (list($key, $val) = each($ANSWER)) { $percent = $file_array[$key] * 100 / $total; $percent_int = floor($percent); $percent_float = number_format($percent, 1); $fp += $percent_float; echo trtd $ANSWER[$key] /tdtdimg height=9 src=\$IMG_DIR_URL/vote_left.gif\; echo img height=9 width=\$percent_int\ src=\$IMG_DIR_URL/vote_middle.gif\; echo img height=9 src=\$IMG_DIR_URL/vote_right.gif\ $percent_float % /td; echo tdCENTER$file_array[$key]/CENTER/td/tr; } echo /TABLEbr; } ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
Maybe this is what you are looking for http://www.thewebmasters.net/php/FastTemplate.phtml - Original Message - From: Steven Haryanto [EMAIL PROTECTED] To: Michael Kimsal [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Monday, April 30, 2001 11:40 AM Subject: Re: [PHP] template solutions? See the philosophy behind HTML::Template for explanation on this: http://www.perlmonth.com/features/template/template.html?issue=11 Not everything with loops and IFs is a programming language. I would probably call PDF or RTF a programming language too if it were. Steve At 5/1/2001 01:10 AM, Michael Kimsal wrote: No, you're asking for something with loops and IFs. That's a programming language. On Tue, 1 May 2001, Steven Haryanto wrote: Actually, not using a programming language is the point of template, since I do not want to expose anything other than some template 'variables' to the template. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
At 5/1/2001 01:43 AM, Michael Kimsal wrote: I understand completely what you're getting at already, but PHP is designed to do what you're asking to do. I know there are valid reaons for stripped down implementations, but can't think of too many. Clean separation of content and presentation? That is one strong point (for some people anyway). Ease of use? I want to let *other people* customize the web page to some extent, but surely do not want to require them to learn PHP. Security? I do not want other people to have access to the PHP runtime (where they can do nasty things like stealing my database password, etc). PHP currently does not support any restricted execution of user code whatsoever. For some applications, sometime I don't even want people to *know* that I am using PHP. And actually, I would consider RTF or PDF to be languages unto themselves. There's a full syntax to use to get specific results, and if you're throwing conditionals in there, or variables, it's hard to see how it's not a language. Maybe not full-featured, but a language nonetheless. I agree. But you said earlier, programming language. Programming languages are used to create *programs*. These perhaps can be loosely called document languages. -- sh -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] timezones
I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Link Color Questions
No you don't :) a href=http://www.domain1.com;font color=blueurl1/font/a a href=http://www.domain2.com;font color=redurl2/font/a a href=http://www.domain3.com;font color=yellowurl3/font/a a href=http://www.domain4.com;font color=greenurl4/font/a --Joe On Sun, Apr 22, 2001 at 04:18:51PM -0500, Jeff Oien wrote: You need to use style sheets: http://www.awlonline.com/cseng/titles/0-201-41998-X/liebos/ http://www.builder.com/Authoring/CSS/?tag=st.bl.7258.dir1.bl_CSS http://www.wdvl.com/Authoring/Style/Sheets/ Jeff Oien Hi, I would like to know how to make different link in different color on one page. etc. www.domain1.com in blue color www.domain2.com in red color www.domain3.com in orange color Thank you for your help Mark -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] Joe Stump [EMAIL PROTECTED] It is impossible to love and be wise. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
At 5/1/2001 01:43 AM, Fabian Raygosa wrote: Maybe this is what you are looking for http://www.thewebmasters.net/php/FastTemplate.phtml Nope. I was looking for a template that supports loops and IFs. Someone pointed me to php dreamtime: http://www.phptemplates.org/ which is a cool project, by the way. Btw, I think I might need some extra tags to my template language so I'm going to hack this on by myself at the time being. Thanks, Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Link Color Questions
Joe Stump wrote: No you don't :) a href=http://www.domain1.com;font color=blueurl1/font/a a href=http://www.domain2.com;font color=redurl2/font/a a href=http://www.domain3.com;font color=yellowurl3/font/a a href=http://www.domain4.com;font color=greenurl4/font/a On Sun, Apr 22, 2001 at 04:18:51PM -0500, Jeff Oien wrote: You need to use style sheets: http://www.awlonline.com/cseng/titles/0-201-41998-X/liebos/ http://www.builder.com/Authoring/CSS/?tag=st.bl.7258.dir1.bl_CSS http://www.wdvl.com/Authoring/Style/Sheets/ Jeff Oien The FONT tag has been depreciated. It still works, for backwards compatibility, but StyleSheet is the way to go. -- W | | I haven't lost my mind; it's backed up on tape somewhere. | ~ Ashley M. Kirchner mailto:[EMAIL PROTECTED] . 303.442.6410 x130 SysAdmin / Websmith . 800.441.3873 x130 Photo Craft Laboratories, Inc. .eFax 248.671.0909 http://www.pcraft.com . 3550 Arapahoe Ave #6 .. . . . . Boulder, CO 80303, USA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] GD and arrays
Hello, I have the following case. I am working on a PHP script which contains an array. Now I want to include a PHP created picture, which is a .php file (gd, now further called as the picture.php file). Till so far, everything is ok. The picture is created following as wished. Now , I want to include values in the picture.php file, which make use of an array which is used in the program above. - I am not able to get any array accessed in the picture.php file! P.S. I am able to access single values in the picture.php. I am also able to list out values of the araay in the script who calls the picture-php file. Can anybody give me a clue, how I can access the array in the picture.php ? Am I doing something wrong, or is this a bug (in that case I prefere a workaround). Regards, Mike Wes [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
On Mon, 30 Apr 2001 13:56:20 -0500, Joe Stump ([EMAIL PROTECTED]) wrote: I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. you could use gmmktime() instead and add or subtract the offset. $offsets=array( PST=1000, // not actual values EST=-2000, ); $localtime=gmmktime()+$offsets[$timezone]; putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] - --- One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
This is how I do it: in DB: usertable username,etc,tzone where tzone = EST,PST,MNT,CNT when the user logs in just grab the tzone, register it in the session. Also make them constants, so you know if the server is in CA, then EST = 10800 now when they do something, all you have to do is calc the time. Like result = mktime() - EST Is this what you were talking about? Jon - Original Message - From: Joe Stump [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 30, 2001 2:56 PM Subject: [PHP] timezones I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
I would use gmktime() to create a UTC timestamp stored in the database, and then use the knowledge about each users timezone to convert this information when showing it. - Frank I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Sort an array
Hello, Is there a way to sort an array alphabetically? Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
On Monday, April 30, 2001, at 12:02 PM, Steven Haryanto wrote: Security? I do not want other people to have access to the PHP runtime (where they can do nasty things like stealing my database password, etc). PHP currently does not support any restricted execution of user code whatsoever. in httpd.conf VirtualHost 192.168.3.8 DocumentRoot /usr/local/www/thisUser ServerName thisUser.myServer.com php_value include_path /usr/local/www/thisUser/inc php_value open_basedir /usr/local/www/thisUser /VirtualHost You could do a lot to control your users abilities/privleges in this way. Dave Goodrich Director of Interface Development Reality Based Learning Company 9521 NE Willows Road, Suite 100 Redmond, WA 98052 Toll Free 1-877-869-6603 ext. 237 Fax (425) 558-5655 [EMAIL PROTECTED] http://www.rblc.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
Thanks to everyone who sent in the info. The problem is as follows: 1.) the mktime()'s are stored as PST in the DB. 2.) we have users ALL OVER the world - is there a place to find all of the timezones at? --Joe On Mon, Apr 30, 2001 at 12:11:55PM -0700, Mark Maggelet wrote: On Mon, 30 Apr 2001 13:56:20 -0500, Joe Stump ([EMAIL PROTECTED]) wrote: I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. you could use gmmktime() instead and add or subtract the offset. $offsets=array( PST=1000, // not actual values EST=-2000, ); $localtime=gmmktime()+$offsets[$timezone]; putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] - --- One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] Joe Stump [EMAIL PROTECTED] Dyslexics of the world -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
I was not referring to safe mode. In other languages like Perl or Python, safe execution means that if I execute some code (or eval a code string supplied by user), I can restrict what kinds of operation is valid for it, or what kinds of variables are available to it. In PHP, if I have my database password in a global var $dbpass, I cannot prevent this code: eval('echo $dbpass'); from printing my database password. Well of course you could do unset($dbpass) or even unset($GLOBALS) or save it to somewhere else... But still I cannot even prevent things like this: eval('echo 1/0'); from stopping my own program because it generates an error that I cannot trap. Well, actually there is error handlers... Perhaps you can get your way around to make eval() more secure, but still I prefer not to trust a code string from user to be eval()'ed by my PHP script. Just letting a user modify a template and changing the look of a page is sufficient for me, since that is all the user is supposed to gain access to. Regards, Steve At 5/1/2001 02:23 AM, Dave Goodrich wrote: On Monday, April 30, 2001, at 12:02 PM, Steven Haryanto wrote: Security? I do not want other people to have access to the PHP runtime (where they can do nasty things like stealing my database password, etc). PHP currently does not support any restricted execution of user code whatsoever. in httpd.conf VirtualHost 192.168.3.8 DocumentRoot /usr/local/www/thisUser ServerName thisUser.myServer.com php_value include_path /usr/local/www/thisUser/inc php_value open_basedir /usr/local/www/thisUser /VirtualHost You could do a lot to control your users abilities/privleges in this way. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
http://www.worldtimeserver.com/ has them all..then you can just assign your constants to them in a way that makes sense to you - Original Message - From: Joe Stump [EMAIL PROTECTED] To: Mark Maggelet [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, April 30, 2001 3:24 PM Subject: Re: [PHP] timezones Thanks to everyone who sent in the info. The problem is as follows: 1.) the mktime()'s are stored as PST in the DB. 2.) we have users ALL OVER the world - is there a place to find all of the timezones at? --Joe On Mon, Apr 30, 2001 at 12:11:55PM -0700, Mark Maggelet wrote: On Mon, 30 Apr 2001 13:56:20 -0500, Joe Stump ([EMAIL PROTECTED]) wrote: I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. you could use gmmktime() instead and add or subtract the offset. $offsets=array( PST=1000, // not actual values EST=-2000, ); $localtime=gmmktime()+$offsets[$timezone]; putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] - --- One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] Joe Stump [EMAIL PROTECTED] Dyslexics of the world -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] suggestions for binary data in database
On Fri, Apr 27, 2001 at 03:24:36PM +0200, Ray Hilton wrote: However, on the site, i am currently storing images in the database, purely because i can. But i wonder, how much will the server load be affected when pulling binary data out of the database? compared to the file system? i assume its going to be quite a lot higher. DO you reckon it would be better to scrap that and store the images on the file system? Yes, I certainly reckon that. Using the database can make organizing them easier, but I usually find it pretty easy to store images on the file system and only put the directory structure, filename in the database. It is much easier on the database too. -- Jason Stechschulte [EMAIL PROTECTED] -- Unix is like a toll road on which you have to stop every 50 feet to pay another nickel. But hey! You only feel 5 cents poorer each time. -- Larry Wall in [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] timezones
On Mon, 30 Apr 2001 14:24:20 -0500, Joe Stump ([EMAIL PROTECTED]) wrote: Thanks to everyone who sent in the info. The problem is as follows: 1.) the mktime()'s are stored as PST in the DB. they still could be just make your pst offset be 0 and every timezone offset be the difference in hours between them and pst*3600 2.) we have users ALL OVER the world - is there a place to find all of the timezones at? good luck, there's tons and some of them are wacky or don't honor daylight saving time. --Joe On Mon, Apr 30, 2001 at 12:11:55PM -0700, Mark Maggelet wrote: On Mon, 30 Apr 2001 13:56:20 -0500, Joe Stump ([EMAIL PROTECTED]) wrote: I have a quick question regarding timezones ... On the local side a record is inserted into the DB by someone in Michigan, while the server rests in CA. Thus a three hour difference. The local mktime() will create a timestamp for say 9:00am when in reality it was entered at 12:00noon in MI. I have 2 character timezones for all my users so it should be easy to convert the two. you could use gmmktime() instead and add or subtract the offset. $offsets=array( PST=1000, // not actual values EST=-2000, ); $localtime=gmmktime()+$offsets[$timezone]; putenv() won't work because of the fact that the timestamp created will be 9:00 no matter what timezone you put it in. So what needs to be done is some recognition that 10800 seconds needs to be added to adjust the PST timestamp to an EST timestamp. Are there any functions out ther that do this? --Joe Joe Stump [EMAIL PROTECTED] -- --- --- One is taught by experience to put a premium on those few people who can appreciate you for what you are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] Joe Stump [EMAIL PROTECTED] - --- Dyslexics of the world -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] template solutions?
At 5/1/2001 03:05 AM, Dave Goodrich wrote: In PHP, if I have my database password in a global var $dbpass, I cannot prevent this code: eval('echo $dbpass'); Never put your DBPass into a GLOBAL ;^) Hm, perhaps creating a function do_connect('hostname','user','pass') is safer? Good idea. Agreed, it's not worth your time and hassle to try and predict every possible circumstance a user might try. Have you thought about some SSI and a few Javascripts? depending on what you mean by changing the look of a page it might be easier. Mm. I still prefer a template, thank you :) A stupid question but I gotta ask, have you looked through freshmeat? lots of stuff like this done in Perl, Python, PHP. Yes, I have done a search on freshmeat and sourceforge for php templates. Btw, there are eazytemplates and php dreamtime that I've been told that supports ifs and loops. That's nice. Thanks to everybody who responded. Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] String Type Unknown
I have this string: 0ffac0ffed0005737200146a6176612e7574696c2e50726f7065727469657339120f fd07a70363e0ff980200014c000864656661756c74737400164c6a6176612f7574696c2f5072 6f706572746965733b787200136a6176612e7574696c2e486173687461626c65130ffbb0f252 14a0ffe40ffb803000246000a6c6f6164466163746f724900097468726573686f6c64787 03f48770800030002740005696d61676574004a3c494d47205352433d226 87474703a2f2f6d6564696162616e6b2e656476656e74757265732e636f6d2f656476656e7475726 5732f6c6162732f627269636b735f7765622e6a7067223e740004746578747402024974206973206 96d706f7274616e7420746f20656d70686173697a652074686174206120666163696c697461746f7 220646f6573206e6f74206e65656420746f20626520616e2065787065727420696e2074686520766 172696f7573207375626a6563742061726561732c206275742073686f756c64206265636f6d65206 6616d696c6961722077697468207468652070726f6a6563747320616e64206d6174657269616c732 0746861742073747564656e74732077696c6c20626520646f696e672c20616e64206265206177617 265206f6620686f7720746f206765742068656c70206f72206c6f6f6b207570207465726d7320616 e6420616e73776572732e2020496e20706172746963756c61722c2066616d696c696172697479207 769746820746865204c45474f3c7375703e267265673b3c2f7375703e20656c656d656e747320697 320686967686c79207265636f6d6d656e6465642e20205043532068617320646576656c6f7065642 06120736570617261746520636f7572736520666f637573696e67206f6e2074686520757365206f6 620746865204c45474f3c7375703e267265673b3c2f7375703e206d6174657269616c732e2020416 c6c20666163696c697461746f72732073686f756c64207363686564756c652074696d6520746f207 4616b652074686973206164646974696f6e616c20636f757273652e7870 And I don't know what type it is. It is it a binary string? Can I convert it to text and if so, how? Thank You, Nathan Cook [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Creating Graphs
Hi try this http://www.aditus.nu/jpgraph/index.php Jarry Uzytkownik Mike Mike [EMAIL PROTECTED] napisal w wiadomosci [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, I was wonder if anyone knows of a place where I can get a good tutorial about making graphs for beginners using php. If so please let me know. Thank you --Mike __ Do You Yahoo!? Yahoo! Auctions - buy the things you want at great prices http://auctions.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Creating Graphs
Check out Leon Atkinsons Core PHP Programming. He has a couple good examples on using pie charts and bar charts. - Original Message - From: Mike Mike [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 30, 2001 11:39 AM Subject: [PHP] Creating Graphs Hello, I was wonder if anyone knows of a place where I can get a good tutorial about making graphs for beginners using php. If so please let me know. Thank you --Mike __ Do You Yahoo!? Yahoo! Auctions - buy the things you want at great prices http://auctions.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] HELP! String Output Limit
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Niko Spyridonos) wrote: I am trying to display a variable that contains more than 255 characters but the output stops at approx. 255. I tried to find what restricts it. Couldn't find anything. I tried the echo, printf commands even I tried using flush() just in case there was some buffer left. Is the variable's content being pulled from a database? The fact that it's 255 chars sounds like it's coming from a char or varchar field set to its maximum length. -- CC -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] help me :)
Arvydas, I did something like this using a tree structure, using stacks. Each item on the stack could have 1 to 3 properties: Name, Parent, URL. If the object on the stack has only a Name property (i.e. Parent and URL are empty) it is assumed that this item is a root node. If the item has a Name and a Parent, is is a child node to the parent, and if it has a Name, Parent and URL, then it is a leaf node to the parent. For example: FolderA FolderB --FolderB(1) --FolderB(2) --ItemB(2)(1) I push onto my stack directory items that have the following properties: AddDirItem(FolderA) AddDirItem(FolderB) AddDirItem(FolderB(1), FolderB) AddDirItem(FolderB(2), FolderB) AddDirItem(ItemB(2)(1), FolderB(2), http://itemb21.whatever) Then, you loop through all of the items, setting the root items as the top of the tree, and continue nesting subitems until you get to a new root item. If you want, I can send you the PHP objects I used to implement this in a dynamic tree. It works quite well, and is extensible to 'n', where 'n' is the number of items allowed due to system/browser constraints. Cheers, Jason Arvydas [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, i'm new in php but i have very difficult exercise i must make hierarchical menu witch can be released for example so : First i will get main menu : for example menu1, menu2, menu3... and these menu will have links (this must be released with a href=...) to others submenu : sub1, sub2, sub3 (each menu can have more than one sub menu), and these submenus will go deeper and deeper (depends from some parameters) so - the question is How to make recursive menu ? (menu mus be repaint after any click...) (I have an idea to make function that will produce recursive arrays...) P.S.sorry for poor english :) sincerely, Arvys. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Problems with sprintf and swapping variables
Ok.. now I hope that somebody can help with this one... I'm trying to write a form field on a webpage that makes data entry of ever changing fields easy.. In otherwords: Enter Style: You might enter: Hello %s, how are you today.. I am fine.. I here you are turning %d. Now this works when you pass sprintf($text, $name, $age); but if you in the text say. Happy %2/$d'th birthday %1/$s. like the docs says your supposed to do it doesn't work and all you see is: Happy $d'th birthday $s. What is up with this.. if you use %2/%d it sort of works, but it throws all my other variables out of whack.. any help with this would be appreciative.. later, Ed McLain [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Browser Detection
Hi, Is it possible with PHP (3.0.16) to detect which browser a user has and then load an image based on the browser type? I've found the get_browser() command in the manual, but it doesn't look like that does what I want, or I could just be looking at it wrong. Has anyone tried this before? and if so, could you provide some assistance. Thank you -Tim -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Sort an array
The PHP online manual is very easy to use. Start at http://www.php.net/array and you'll find all the functions that act on array downl the left side of your browser, including a fantastically rich set of sort options. Miles At 12:19 PM 4/30/01 -0700, Brandon Orther wrote: Hello, Is there a way to sort an array alphabetically? Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] COM
Unfortunately VB 6.0 com components do not like to work outside of their ASP and VB bases. I've heard of a few people trying it, but I heard it was very difficult. I'd help more, but I've never used PHP with com, only with ASP Chris Anderson aka Null PHP Developer / Nulltech PHP-GTK Grunt / gtk.php.net STA-DoD, TO and DDay Administrator / www.stronger.org DOD Co-Owner / www.dayofdefeat.com Zeroping Staff Member / www.zeroping.com Volition Programmer / www.Volition-net.com - Original Message - From: Hassan Arteaga [EMAIL PROTECTED] To: Php (E-mail) [EMAIL PROTECTED] Sent: Monday, April 30, 2001 1:57 PM Subject: [PHP] COM Hi all !! I have components i made in Visual Basic 6.0 and I would like to use with PHP. I need examples how to create intance from VB COM component... What function I have to use ? com_load - ??? com_invoke - ??? com_propget - ??? com_get - ??? com_propput - ??? com_propset - ??? com_set - ??? Thanks in advanced !!! -- M. Sc. Hassan Arteaga Rodríguez Microsoft Certified System Engineer Network Admin, WEB Programmer FUNDYCS, Ltd [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PHP 4.0.5 is out (output compression)
At 12:12 AM +0300 5/1/01, Zeev Suraski wrote: - Implemented high-performance zlib-based output compression - see zlib.output_compression INI directive. (Zeev) is this different from ob_gzhandler()? if so, how is it different? thanks. -aaron -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Best Practice-HTML In Database
Yes, I will need to provide searching capabilities. Basically, I'm creating an online referencing system with a db backend. A user will be able to search for a manual, and/or browse to a particular section of the manual. It's similar to the online PHP manual...at least, in concept. So, in the long run, which will be more beneficial: 1) HTML code inside the db fields? or 2) HTML URL inside the field? __John Monfort_ _+---+_ P E P I E D E S I G N S www.pepiedesigns.com The world is waiting, are you ready? -+___+- On Mon, 30 Apr 2001, Mark Roedel wrote: -Original Message- From: John Monfort [mailto:[EMAIL PROTECTED]] Sent: Sunday, April 29, 2001 10:40 PM To: [EMAIL PROTECTED] Subject: [PHP] Best Practice-HTML In Database Hello everyone, I'm curious. Which is the better practice? 1) Insert the HTML page (...HTML code) in the database ? or 2) Insert a URL in the database field, that points to the HTML page? why? Will you ever want to do database-ish things with the contents of the page? (Allow somebody to search for words or phrases in the body, for example?) --- Mark Roedel ([EMAIL PROTECTED]) || There cannot be a crisis next week. Systems Programmer / WebMaster || My schedule is already full. LeTourneau University ||-- Henry Kissinger -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PHP 4.0.5 is out
Is anyone else having problems with the Windows binary zip? I've downloaded it a couple times and it keeps saying that it's corrupt. Thanks! Shawn Sellars -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Please review our coding standards [ ideas ]
Steve, I am wondering what your reason is for item 4.2. Security, or otherwise? Personally, I like having various file extensions, for sorting files by content type. Thanks for putting this up here. Kirk -Original Message- From: Steven Haryanto [mailto:[EMAIL PROTECTED]] Subject: [PHP] Please review our coding standards [ ideas ] 4. File organization 4.2 All PHP libraries and include files, is named with '.php' extension (ie. no '.lib', '.inc', etc.). Test scripts is named with '.phpt' extension. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] XML Parsing
I am posting information to a credit card processing server. This is done over HTTPS (with cURL) and seems to work fine. I get the response that I want from the server, which consists of an XML doc with about 20 tags and their corresponding values. I have gone through the mailing list and manuals, yet I still can't seem to figure out how to get each piece of the XML doc into their own variables. Here is the code I am using: $server = https://www.creditcard.com;; $path = xmlhttps/xtrans.asp; $ch = curl_init(); $requestedurl = $server . /$path; curl_setopt($ch, CURLOPT_URL, $requestedurl); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $xmlstring); curl_setopt($ch, CURLOPT_RETURNTRANSFER,0); curl_close ($ch); This replies (as it should) with an XML doc like this: RESPONSESERVICECC/SERVICESERVICE_TYPEDEBIT/SERVICE_TYPESERVICE_SU BTYPEAUTH/SERVICE_SUBTYPESERVICE_FORMAT1010/SERVICE_FORMATTERMINAL_I DPC-/TERMINAL_IDPIN1234/PINTRANSACTION_INDICATOR7/TRANSACTION_ INDICATORAMOUNT5/AMOUNTACCOUNT_NUMBER1234/ACCOUNT_NUMBEREXPIRATION 1202/EXPIRATIONFIRST_NAMEMichael/FIRST_NAMELAST_NAMEConley/LAST_NA MEADDRESSPO BOX 59/ADDRESSCITYAuburn/CITYSTATECA/STATEPOSTAL_CODE95604/POSTAL_C ODECOUNTRYUSA/COUNTRYPHONE/PHONEOPERATORSomebody/OPERATORCURRE NCY_CODE840/CURRENCY_CODETERMINAL_ID/TERMINAL_IDUSER_DATA_0/USER_D ATA_0USER_DATA_1/USER_DATA_1USER_DATA_2/USER_DATA_2USER_DATA_3/U SER_DATA_3USER_DATA_4/USER_DATA_4USER_DATA_5/USER_DATA_5USER_DATA_ 6/USER_DATA_6USER_DATA_7/USER_DATA_7USER_DATA_8/USER_DATA_8USER_ DATA_9/USER_DATA_9VERBOSE_RESPONSE/VERBOSE_RESPONSESERVICE_PROVIDER 10/SERVICE_PROVIDERTRANSACTION_ID03509KQEGVHMGED4/TRANSACTION_IDLOCAL _TIME172823/LOCAL_TIMELOCAL_DATE04302001/LOCAL_DATEEXCHANGE_RATE1/ EXCHANGE_RATEMRC00/MRCARC00/ARCRESPONSE_TEXTNO MATCH/RESPONSE_TEXTAPPROVAL_CODEVITAL6/APPROVAL_CODEAVS_RESPONSEN/A VS_RESPONSECOMMERCIAL_RESPONSE0/COMMERCIAL_RESPONSE/RESPONSE What I need to do now is get certain parts of the return string. How do I assign the value in the APPROVAL_CODE tags to the variable $approvalcode? I also need to get several other parts of the XML string assigned to variables so that I can use them elsewhere. I can't seem to figure out how to do this. I know that I need to change the CURLOPT_RETURNTRANSFER to 1 to allow the information to be placed somewhere other than the screen for processing, but after that I am not sure how to do this. I have gone through the mailing lists and through the docs online, but I'm having no luck. Any help is appreciated. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Writing a file with break lines
How can I write a file like list.txt, I get a lot of information from mysql, and I have to put with line of mysql in this txt file. (rewrite). How can I do that? I tried to put \n but it didn't worked. regards, Augusto Cesar Castoldi -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Executing a PL/SQL Function
Here is the code: $stmt = OCIParse($conn,BEGIN prontolog.pc_int.pedido(:p_cgc_lweb, :p_id_cliente, :p_id_pedido, :p_id_transp, :p_contrato, :p_dt_emissao, :p_dt_chegada, :p_dt_entrega, :p_vl_frete, :c_nome, :c_fone1, :c_fone2, :c_fax, :c_email, :c_endereco_f, :c_bairro_f, :c_cep_f, :c_cidade_f, :c_estado_f, :c_nome_e, :c_endereco_e, :c_bairro_e, :c_cep_e, :c_cidade_e, :c_estado_e, :p_id_conpag, :v_observa); END;); OCIBindByName($stmt, :p_cgc_lweb, $p_cgc_lweb, 150); OCIBindByName($stmt, :p_id_cliente, $p_id_cliente, 150); OCIBindByName($stmt, :p_id_pedido, $p_id_pedido, 150); . . . $p_cgc_lweb = 04284227000167; $p_id_cliente = 29334988800; $p_id_pedido = 0001; $p_id_transp = 00926551000180; $p_contrato = numero do contrato da transportadora; $p_dt_emissao = date(Y-m-d H:i:s); $p_dt_chegada = date(Y-m-d H:i:s); . . . OCIExecute($stmt); print (($v_observa)); prontolog is the schema pc_int is the package pedido is the function And this is the exacly output ---//--- Warning: OCIStmtExecute: ORA-06550: line 1, column 7: PLS-00221: 'PEDIDO' is not a procedure or is undefined ORA-06550: line 1, column 7: PL/SQL: Statement ignored in /www/htdocs/mariamercado/teste.phtml on line 64 (()) ---//--- Can I execute functions ? If yes, what may be wrong ? Thank you very much, -- Marcelo Dias de Toledo N-Web E-Commerce - http://www.nweb.com.br mailto:[EMAIL PROTECTED] Phone: 55 71 341-8474 - Fax: 55 71 341-8480 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] XML Parsing
http://www.php.net/manual/en/ref.xml.php and http://www.phpbuilder.com/columns/joe2907.php3 great palces to get you started on XML parseing try the second one first as it jumps right into it with xpat. phpbuilder also has stuff for the DOM XML as well. - Original Message - From: Michael Conley [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 30, 2001 3:21 PM Subject: [PHP] XML Parsing I am posting information to a credit card processing server. This is done over HTTPS (with cURL) and seems to work fine. I get the response that I want from the server, which consists of an XML doc with about 20 tags and their corresponding values. I have gone through the mailing list and manuals, yet I still can't seem to figure out how to get each piece of the XML doc into their own variables. Here is the code I am using: $server = https://www.creditcard.com;; $path = xmlhttps/xtrans.asp; $ch = curl_init(); $requestedurl = $server . /$path; curl_setopt($ch, CURLOPT_URL, $requestedurl); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $xmlstring); curl_setopt($ch, CURLOPT_RETURNTRANSFER,0); curl_close ($ch); This replies (as it should) with an XML doc like this: RESPONSESERVICECC/SERVICESERVICE_TYPEDEBIT/SERVICE_TYPESERVICE_SU BTYPEAUTH/SERVICE_SUBTYPESERVICE_FORMAT1010/SERVICE_FORMATTERMINAL_I DPC-/TERMINAL_IDPIN1234/PINTRANSACTION_INDICATOR7/TRANSACTION_ INDICATORAMOUNT5/AMOUNTACCOUNT_NUMBER1234/ACCOUNT_NUMBEREXPIRATION 1202/EXPIRATIONFIRST_NAMEMichael/FIRST_NAMELAST_NAMEConley/LAST_NA MEADDRESSPO BOX 59/ADDRESSCITYAuburn/CITYSTATECA/STATEPOSTAL_CODE95604/POSTAL_C ODECOUNTRYUSA/COUNTRYPHONE/PHONEOPERATORSomebody/OPERATORCURRE NCY_CODE840/CURRENCY_CODETERMINAL_ID/TERMINAL_IDUSER_DATA_0/USER_D ATA_0USER_DATA_1/USER_DATA_1USER_DATA_2/USER_DATA_2USER_DATA_3/U SER_DATA_3USER_DATA_4/USER_DATA_4USER_DATA_5/USER_DATA_5USER_DATA_ 6/USER_DATA_6USER_DATA_7/USER_DATA_7USER_DATA_8/USER_DATA_8USER_ DATA_9/USER_DATA_9VERBOSE_RESPONSE/VERBOSE_RESPONSESERVICE_PROVIDER 10/SERVICE_PROVIDERTRANSACTION_ID03509KQEGVHMGED4/TRANSACTION_IDLOCAL _TIME172823/LOCAL_TIMELOCAL_DATE04302001/LOCAL_DATEEXCHANGE_RATE1/ EXCHANGE_RATEMRC00/MRCARC00/ARCRESPONSE_TEXTNO MATCH/RESPONSE_TEXTAPPROVAL_CODEVITAL6/APPROVAL_CODEAVS_RESPONSEN/A VS_RESPONSECOMMERCIAL_RESPONSE0/COMMERCIAL_RESPONSE/RESPONSE What I need to do now is get certain parts of the return string. How do I assign the value in the APPROVAL_CODE tags to the variable $approvalcode? I also need to get several other parts of the XML string assigned to variables so that I can use them elsewhere. I can't seem to figure out how to do this. I know that I need to change the CURLOPT_RETURNTRANSFER to 1 to allow the information to be placed somewhere other than the screen for processing, but after that I am not sure how to do this. I have gone through the mailing lists and through the docs online, but I'm having no luck. Any help is appreciated. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Programming PHP in a modular way
Hello, I am a newi in PHP. Currently I am creating my first site. I would like to programm it modularly. I tryed it, but I came to the point, that I have everything in one file with a huge amount of tables. What would be the best way to build a site with a navigation on the left and content on the right. The question is.. what is the proper syntax to open the next content from the menu. Open it in the same file, or open a new one?? Thanks Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Recive Mail
Where is the option to recive mail? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PHP 4.0.5 is out (output compression)
Yes it is, it's much more efficient. Zeev At 01:05 1/5/2001, Aaron Tuller wrote: At 12:12 AM +0300 5/1/01, Zeev Suraski wrote: - Implemented high-performance zlib-based output compression - see zlib.output_compression INI directive. (Zeev) is this different from ob_gzhandler()? if so, how is it different? thanks. -aaron -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- Zeev Suraski [EMAIL PROTECTED] CTO co-founder, Zend Technologies Ltd. http://www.zend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PHP 4.0.5 is out
Apparently the zip is indeed broken. We'll try to get a fixed one up there soon. Sorry for the hassle, Zeev At 01:21 1/5/2001, SHAWN wrote: Is anyone else having problems with the Windows binary zip? I've downloaded it a couple times and it keeps saying that it's corrupt. Thanks! Shawn Sellars -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- Zeev Suraski [EMAIL PROTECTED] CTO co-founder, Zend Technologies Ltd. http://www.zend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Arranging lists
Hi, I've got a select box that gets vaules from a DB, now I want these value to be displayed in a certain order that's NOT relating to their id nor in alphabetical order .. can some one suggest a way this might be done?? At present my select box looks like this : form name=select method=post action=machine.php select name=system size=1 ?php $query =SELECT DISTINCT system FROM 1machine ORDER BY system; $result = mysql_query($query); while($row = mysql_fetch_array($result)){ echo 'option value='.$row[system].''.$row[system].'/optionbr'; } ? /select input type=submit name=select value=select /form Peter Houchin [EMAIL PROTECTED] = _ __ /\ /_/_/_\/ |_/ \ /_/_/___ __ __ __ / \ \_/_/_\ /_/ /_/ /_/ /_/ \ _ / ___\_\_\/ /_/_/_/ /_//\/_/\_/ \/\_/ \_//_/_/ /_/_/_/ /_/ \/_/v /_/_/_/_/ /_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ /_/_ _/_/ __ __ __ /_/ __ __ /_/_/_/_/ /_/_/_/ /_/ /_/ /_/ /_/\_\/_//_/_/_/ /_/ \_\ /_/ _/ /_//\/_/ /_/ /_/__\_\ /_/___ _\_\_\ /_/\_\/_/_/_/ /_/ \/_/ /_/ /_/\_\/_/_/_//_/_/_/ = Telephone : (03) 9329 1455 Facsimile : (03) 9329 6755 * We rent the dot in .COM! **
Re: [PHP] Arranging lists
You'll have to assign some sort of order to them using an integer tag column or something similar... and then order by that when you select That's my best suggestion. -Brian http://www.zaam.com Peter Houchin [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi, I've got a select box that gets vaules from a DB, now I want these value to be displayed in a certain order that's NOT relating to their id nor in alphabetical order .. can some one suggest a way this might be done?? At present my select box looks like this : form name=select method=post action=machine.php select name=system size=1 ?php $query =SELECT DISTINCT system FROM 1machine ORDER BY system; $result = mysql_query($query); while($row = mysql_fetch_array($result)){ echo 'option value='.$row[system].''.$row[system].'/optionbr'; } ? /select input type=submit name=select value=select /form Peter Houchin [EMAIL PROTECTED] = _ __ /\ /_/_/_\/ |_/ \ /_/_/___ __ __ __ / \ \_/_/_\ /_/ /_/ /_/ /_/ \ _ / ___\_\_\/ /_/_/_/ /_//\/_/\_/ \/\_/ \_//_/_/ /_/_/_/ /_/ \/_/v /_/_/_/_/ /_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ /_/_ _/_/ __ __ __ /_/ __ __ /_/_/_/_/ /_/_/_/ /_/ /_/ /_/ /_/\_\/_//_/_/_/ /_/ \_\ /_/ _/ /_//\/_/ /_/ /_/__\_\ /_/___ _\_\_\ /_/\_\/_/_/_/ /_/ \/_/ /_/ /_/\_\/_/_/_//_/_/_/ = Telephone : (03) 9329 1455 Facsimile : (03) 9329 6755 * We rent the dot in .COM! ** -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Help: Logging Into Sites (webgames)
I want to log into a game and access a page and parse it. To Log into the game, youd have to use a form, so how do I do this in PHP? If anyone has any ideas, or information, please help. ~Fred [EMAIL PROTECTED] ICQ 19551338 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Help: Logging Into Sites (webgames)
Fred [EMAIL PROTECTED] wrote: I want to log into a game and access a page and parse it. To Log into the game, youd have to use a form, so how do I do this in PHP? Using CURL functions you can post to a URL and grab the output. You have to compile PHP --with-curl after installing CURL first. You can also use fsockopen(). -- Steve Werby President, Befriend Internet Services LLC http://www.befriend.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]