[PHP] Re: connect
look at http://www.phpbuilder.com/columns/siddarth2228.php3 for a good tutorial. -- Best regards, George Nicolae IT Manager ___ X-Playin - Professional Web Design www.x-playin.f2s.com Gendeng [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... halo... i want to know about connect to database. can php (for windows) connect to MS Access ?. Mpu Strees IncrediMail - Email has finally evolved - Click Here -- 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] Select box won't display in Netscape 4.xx
Dear Edwin! Yes, I have had this problem before ... My problem was, that I a line in my style sheets, which could not be solved by NS. (I think it was border?) Yours, Martin I'm developing a website for multiple browsers. In Netscape 4.xx (both Win98 and Linux versions), the php-scripts display the select boxes in my forms only as plain text. I cannot make any selections. In other browsers (NS 6 and IE5), it works fine. Anyone seen this behavior before? - Dipl.-Ing. Martin Schichl SCC Software, Communication Consulting GmbH Co KEG Grottenhofstr. 3, A-8053 Graz Tel. +43/(0)316/265-205, Fax +43/(0)316/265-234 [EMAIL PROTECTED], http://scc.co.at -- 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] Select box won't display in Netscape 4.xx
Did you forget the FORM /FORM tags? Jerry -Original Message- From: Martin Schichl [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 9:57 AM To: Edwin Boersma; [EMAIL PROTECTED] Subject: Re: [PHP] Select box won't display in Netscape 4.xx Dear Edwin! Yes, I have had this problem before ... My problem was, that I a line in my style sheets, which could not be solved by NS. (I think it was border?) Yours, Martin I'm developing a website for multiple browsers. In Netscape 4.xx (both Win98 and Linux versions), the php-scripts display the select boxes in my forms only as plain text. I cannot make any selections. In other browsers (NS 6 and IE5), it works fine. Anyone seen this behavior before? - Dipl.-Ing. Martin Schichl SCC Software, Communication Consulting GmbH Co KEG Grottenhofstr. 3, A-8053 Graz Tel. +43/(0)316/265-205, Fax +43/(0)316/265-234 [EMAIL PROTECTED], http://scc.co.at -- 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] The information contained in this email is confidential and may be legally privileged. It is intended solely for the addressee. Access to this email by anyone else is unauthorized. If you are not the intended recipient, any form of disclosure, production, distribution or any action taken or refrained from in reliance on it, is prohibited and may be unlawful. Please notify the sender immediately. The content of the email is not legally binding unless confirmed by letter bearing two authorized signatures. -- 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] New Indian PHP User Group Mailing List
Hello Kind folks First apologies for a slightly off topic posting Second - There is now an active Indian PHP User Group. The mailing list is hosted at YahooGroups: http://groups.yahoo.com/group/in-phpug To subscribe, please send a blank message to [EMAIL PROTECTED] The list aims to cater to newbies and gurus alike (from the Indian sub-continent in particular and the world in general ;-) But the approach will more of teaching to fish rather than giving a fish Thanks for your patience Cheer Dr Tarique Sani -- == PHP Applications for E-Biz : http://www.sanisoft.com The Ultimate Ghazal Lexicon: http://www.aaina-e-ghazal.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] connect MS Access
yes you can connect via ODBC. - Original Message - From: Matt Friedman [EMAIL PROTECTED] To: 'gendeng' [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, January 02, 2002 3:32 AM Subject: RE: [PHP] connect MS Access Please do not send html emails to this list. Send only plain text emails. Matt Friedman -Original Message- From: gendeng [mailto:[EMAIL PROTECTED]] Sent: Tuesday January 1, 2002 8:23 PM To: [EMAIL PROTECTED] Subject: [PHP] connect MS Access halo... i want to know about connect to database. can php (for windows) connect to MS Access. Mpu Strees IncrediMail - Email has finally evolved - Click Here -- 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] php newbie
hi i am new in php ,i just wanted to ask before i begin learning php ,well can i design php on my personal computer or i need a server to design php ,and the second question is do i need a specific program to design php or i can use my html editor for that -- 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 newbie
To test your PHP scripts you do need a server with PHP. It's very easy to setup one on to you local machine + there is many completely free ones. Niklas -Original Message- From: Fady Fouad Shehata [mailto:[EMAIL PROTECTED]] Sent: 31. joulukuuta 2001 4:34 To: [EMAIL PROTECTED] Subject: [PHP] php newbie hi i am new in php ,i just wanted to ask before i begin learning php ,well can i design php on my personal computer or i need a server to design php ,and the second question is do i need a specific program to design php or i can use my html editor for that -- 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 newbie
To design, you just need a text editor (or html editor) Martin At 13:24 02.01.02 +0200, Niklas Lampén wrote: To test your PHP scripts you do need a server with PHP. It's very easy to setup one on to you local machine + there is many completely free ones. Niklas -Original Message- From: Fady Fouad Shehata [mailto:[EMAIL PROTECTED]] Sent: 31. joulukuuta 2001 4:34 To: [EMAIL PROTECTED] Subject: [PHP] php newbie hi i am new in php ,i just wanted to ask before i begin learning php ,well can i design php on my personal computer or i need a server to design php ,and the second question is do i need a specific program to design php or i can use my html editor for that -- 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] - Dipl.-Ing. Martin Schichl SCC Software, Communication Consulting GmbH Co KEG Grottenhofstr. 3, A-8053 Graz Tel. +43/(0)316/265-205, Fax +43/(0)316/265-234 [EMAIL PROTECTED], http://scc.co.at -- 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 newbie
Yep, but you can't do much without testing your scripts. Niklas -Original Message- From: Martin Schichl [mailto:[EMAIL PROTECTED]] Sent: 2. tammikuuta 2002 13:37 To: [EMAIL PROTECTED]; Php-General Subject: RE: [PHP] php newbie To design, you just need a text editor (or html editor) Martin At 13:24 02.01.02 +0200, Niklas Lampén wrote: To test your PHP scripts you do need a server with PHP. It's very easy to setup one on to you local machine + there is many completely free ones. Niklas -Original Message- From: Fady Fouad Shehata [mailto:[EMAIL PROTECTED]] Sent: 31. joulukuuta 2001 4:34 To: [EMAIL PROTECTED] Subject: [PHP] php newbie hi i am new in php ,i just wanted to ask before i begin learning php ,well can i design php on my personal computer or i need a server to design php ,and the second question is do i need a specific program to design php or i can use my html editor for that -- 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] - Dipl.-Ing. Martin Schichl SCC Software, Communication Consulting GmbH Co KEG Grottenhofstr. 3, A-8053 Graz Tel. +43/(0)316/265-205, Fax +43/(0)316/265-234 [EMAIL PROTECTED], http://scc.co.at -- 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] Extract a string from a string
I've got a search script, where you can search for a string and it will return links to the HTML files that contain the string. I've also written a function, where it will highlight each instance of the searched string by using: $asdf = fopen($logfile, r); $contents = fread($asdf,filesize($logfile)); fclose($asdf); $contents=stri_replace($hi,b style=\color:black;background-color:#FFCC66\.$hi./b, $contents); echo $contents; (stri_replace because I wrote a function to do that) Where $hi is the string that is to be highlighted. Of course, if the user searched for HI, and Hi was found, it would show up as a highlighted HI, becuase it only uses $hi as the highlighted word, not the original string. I'm fairly sure that I could do this with ereg functions, but I've spent too long looking and now it just about makes me sick just looking at it. Pleeease, can anybody help? -qartis -- 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 2 Jan 2002 11:55:50 -0000 Issue 1087
php-general Digest 2 Jan 2002 11:55:50 - Issue 1087 Topics (messages 79189 through 79214): Re: Oracle 79189 by: Martin Towell Hosting provider... 79190 by: Matt Moreton 79191 by: Kurt Lieber 79193 by: steph.philedom2k.com 79203 by: Boaz Yahav Mysql Curdate problem 79192 by: Andras Kende connect MS Access 79194 by: gendeng 79195 by: Matt Friedman 79209 by: Paul Roberts Re: Session troubles 79196 by: Sean LeBlanc Get PHP Configuration 79197 by: Larentium 79198 by: Adam Baratz 79199 by: Daniel Grace Re: How to convert integers representations of a date to a date format variable 79200 by: Daniel Grace Re: Need some Linux/Apache help 79201 by: Brian Clark URGENT-PDF 79202 by: Chamarty Prasanna Kumar connect 79204 by: gendeng 79205 by: George Nicolae Re: Select box won't display in Netscape 4.xx 79206 by: Martin Schichl 79207 by: Jerry Verhoef (UGBI) New Indian PHP User Group Mailing List 79208 by: Tarique Sani tarique.sanisoft.com php newbie 79210 by: Fady Fouad Shehata 79211 by: Niklas Lampén 79212 by: Martin Schichl 79213 by: Niklas Lampén Extract a string from a string 79214 by: qartis 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] -- ---BeginMessage--- there's the OCI* or ORA_* functions depending on the version of oracle you're using. -Original Message- From: Phillip B. Bruce [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 10:54 AM To: PHP Subject: [PHP] Oracle Hi, Has any one on this list worked with Oracle, Apache and PHP. My apache is configured for apache and working with mysql. Just wondered if there is any docs on connecting to Oracle in the same manner mysql is being done? -- *** Phillip B. Bruce *** *** http://pbbruce.home.mindspring.com *** *** [EMAIL PROTECTED] *** *** *** *** Have you ever noticed? Anybody going slower than*** *** you is an idiot, and anyone going faster than you*** *** is a maniac. - George Carlin*** -- 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] ---End Message--- ---BeginMessage--- Im looking to change my hosting provider. ...something that isnt going to break the bank, is feature full, supports mysql, php etc etc and doesnt limit your bandwidth usage! I need about 100+ mb's of space, and possibly the ability to run a background process. Can anyone here suggest a good provider that meets the above criteria? Thanks Matt. ---End Message--- ---BeginMessage--- On Tuesday 01 January 2002 04:19 pm, Matt Moreton wrote: Can anyone here suggest a good provider that meets the above criteria? Asked and answered about 4 billion times in the archives. Might check there. --kurt ---End Message--- ---BeginMessage--- I use hostrocket. They seem to meet most of your criteria, but as with many hosts they do not offer unlimited bandwidth. Personally, I stay away from hosts that say they offer unlimited bandwidth (there's usually a catch). Has one of the best Control Panels IMO. Includes PHP, MySQL, Perl, subdomain support, unlimited emails, more than enough hard drive space (350 MB+), and more. Support includes trouble ticketing and a support forum. I use the forum to discuss things with fellow customers than problems with my site as support through the trouble ticket system is pretty efficient. I get very fast responses from technical support (One time they responded within less than 5 minutes of me sending a ticket in with a solution). You may want to check out their forum and see what other clients have to say also. - Original Message - From: Matt Moreton [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, January 01, 2002 4:19 PM Subject: [PHP] Hosting provider... Im looking to change my hosting provider. ..something that isnt going to break the bank, is feature full, supports Myql, php etc etc and doesnt limit your bandwidth usage! I need about 100+ mb's of space, and possibly the ability to run a background process. Can anyone here suggest a good provider that meets the above criteria? Thanks Matt. ---End Message--- ---BeginMessage--- Check out : http://www.weberdev.com/index.php3?GoTo=phenominet/prices.htm This is your
Re: [PHP] Re: Generate Alphabet
Bogdan Stancescu [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... 2. print $letter++ -- why doesn't this evaluate to b at the first loop when it's already 'a'? Ok, this I may be able to explain because it's neither print ++$letter nor print ($letter++), but I wouldn't have trusted this syntax to work this way a million years! $foo++ is 'postfix', ++$foo is 'prefix' This means that the addition of 1 occurs AFTER (hence post) the expression's value is returned, not before. In other words, it's equivalent to this: print $foo; $foo = $foo + 1; not this: $foo = $foo + 1; print $foo; -- Daniel Grace -- 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] Connect to IBM DB2
To connect to Microsoft SQL 7 I'm using the following script which works fine: ?php $query=SELECT * FROM DB1; $queryupd=UPDATE DB1 SET dateval='20010101' where dateval='2101'; $hostname = dbserver; $username = username; $password = pwd; $dbName = DB; mssql_connect($hostname,$username,$password) or die(DATABASE FAILED TO RESPOND.); mssql_select_db($dbName) or DIE(Table unavailable); $result2 = MSSQL_QUERY($queryupd); // Execute Update Statment $result = MSSQL_QUERY($query); // Execute Select Statment $number = MSSQL_NUM_ROWS($result); $i=0; if($number == 0) print No data?; elseif($number 0){ print Number of rows: $numberBR; while($i $number){ $dateval = mssql_result($result,$i,dateval); echo TRTDFONT color=#112266$dateval/FONT/TD; $i++;} } ? Now, how to connect to a DB2 database server without ODBC ? My config is: Web Server: IIS on windows 2000 Server Database Server: IBM DB2 V7.1 on windows 2000 Server PHP4 for windows Thanks. Jerry -- 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] Internal working of function()
If you have lots (let's say 100 or 200) of functions() in PHP does this slow everything down a lot? How is the interal working of a function? Warm regards, Emile Bosch -- 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] XSLT in PHP
Hi List, XSLT seems to be such an hot topic these days now i tried it out and i find it cool too. But is there anyway how i can make XSLT less strict? When i make a stylesheet XSLT is too picky..I can't make an XSLT stylesheet very fast because you have to close everything correct etc.. When i design a template i cannot do.. blah tralala br = ERROR has to be br/ /blah And so are there a numerous things that have to be done.. Is there someway how i can turn that strictness thingie of? Warm regards, EMile Bosch -- 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] Boolean SQL query builder
I'm in the process of coding a db search engine, and am spending excessive amounts of time putting together a SQL 'query builder' function which will turn this: mon* NOT monkey [AND/OR queries also] ...into this: SELECT * FROM table WHERE field LIKE 'monk%' AND NOT field = 'monkey' Basically, my thinking was that this will have been done many times before, and be available readily on Hotscripts or the PHP Resource Index.. but all I've managed to turn up so far is phpSQLbool (http://sourceforge.net/projects/phpsqlbool/) which is, by the author's admission, not very complete at the moment. So... has anyone written a similar function that will do the above? :) Many 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]
RE: [PHP] Session troubles
I agree. Perhaps make a feature request that disallows session starting if save_handler=user and you haven't defined a session handler?Then it could spit out a more correct error message. Jaime Bozza -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 01, 2002 8:32 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-31 09:23, Jaime Bozza wrote: Sean, From your php error_log, it's saying the following: Failed to write session data (user) which sounds like it's having problems writing to the user-defined session handler. Are you using a user-defined session handler? If not, make sure your php.ini file has: session.save_handler = files And *NOT*: session.save_handler = user That will make a big difference. Good eye. That was it. I *did* have it as user because I was trying to do my own user-defined session handler, and then stepped back and was just trying to get the simpler case to work, w/o changing it back. Thanks, it works now! Now, I just need to see if I can get my session_handler working... It's too bad the error message isn't more descriptive for this, BTW... -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Saturday, December 29, 2001 1:21 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-29 12:56, David Jackson wrote: Sean -- Don't know if this help but here's what I just worked for me. What ver. of PHP are you using? It seem to me that 3.x.x needs PHPLIB: http://sourceforge.net/projects/phplib to handle sessions? -- David Jackson --- sean.php --- ?php include(seaninc.php); ? --- seaninc.php -- ?php session_start(); session_register(i); $i++; echo $i; ? I'm using 4.0.6. I believe session handling was added as part of standard 4.x, right (if configured to compile it)? Some more info: I tried with Konqueror, as I know a cookie needs to be sent during the session_start() phase - I did get a dialog pop-up asking if I wanted to accept the cookie, but I still got the error: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 It says line 2 because I deleted some white space and commented out code thas was before session_start(). I set logging errors on, and sent it to syslog. Here's what it says: Dec 29 12:12:57 free httpd: PHP Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 Dec 29 12:12:57 free httpd: PHP Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0 But /tmp exists, and is world writeable: free# ls -ld /tmp drwxrwxrwt 16 root wheel 1024 Dec 29 12:14 /tmp On 12-29 09:59, Miles Thompson wrote: Sean, What's going on in incl.php. Are you issuing a session_start()? No, I was not. What if it's rearranged like so, as I understand you have to register the session variable before using it. include(incl.php); session_start(); session_register(mine); $mine++; echo $mine; No dice, either. Actually, I had tried several permutations of the order before posting. :) There's the divide and conquer approach too. What do you see if you comment out the include, then issue a phpinfo() and a die()? Okay, I tried commenting out include, resulting in this code: session_start(); session_register(i); $i++; echo $i; When I run the above, I get this: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 6 Which is getting somewhere, in a way. Line 6 is session_start(); What part from phpinfo() output were you interested in? Or did you want to see all of it? Thanks for the help. HTH and Merry Christmas / Happy New Year - Miles Thompson On Friday 28 December 2001 11:26 pm, Sean LeBlanc wrote: I asked this on php-install list, but got no response so here goes... I simply cannot get session to work correctly. Here's the test script: include(incl.php); session_start(); $mine++; session_register(mine); echo $mine; incl.php includes code to save/retrieve session information to/from DB. It calles session_set_save_handler at the end. What happens is I get an error because it is trying to read the variable out and I get a DB error, but my session writing routine is never called...I know, because I have a print in there. And of course, the var doesn't increment upon refreshes - it remains 1. I've seen this before, and it was fixed, but I forget how it was done, as I didn't actually implement the solution (I hear and I forget, I do and I remember, I guess). About my system:
[PHP] array_multisort?
Hi List, I'm having a problem sorting the following array: $product = array($id, $title, $price); $shop[] = $product; I want the array 'shop' to be sorted by the 'title' in array 'product'. I tried the function 'array_multisort()', but that did not do the trick. Does anyone know how to fix this? Best regards, Sebastiaan Timmers -- 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] test
Let see does my PERSONEL unsubscribe information appear at the bottom of this email? For the second time in 48hrs. someone submitted an unsubscribe request using for me? Yet I still get the list postings? How strange. -- -- 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: Including files variables ...
what everyone is trying to say is that it goes automatically.. ie . test.php -- $blah=10; include whatever.php; whatever.php - echo The value of blah is: {$blah}; It just keeps the variable since it's global.. When ur using a function. It can be different, since you have to import these variables. Warm regards, EMile Bosch Evansville Scene [EMAIL PROTECTED] wrote in message 001001c1a870$353b3240$6401a8c0@amd">news:001001c1a870$353b3240$6401a8c0@amd... I'm having problems passing variables into included PHP files. How can I do this? -- 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 Forms
Hello, I am new to PHP. I have PHP (cgi version) configured on my machine running XP Pro and IIS. It works fine. The first script I wanted to write was the ever-useful feedback form script where the contents of a form are e-mailed to the webmaster. I am sure that I have a working script but when I test on my machine I get a server error. I realize that this is most likely because I don't have any mail settings configured on IIS (new to this as well). I was wondering if someone could give me some advice on how to properly set this up so I can locally test mail scripts like this. Thanks, Matt -- 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] Connect to IBM DB2
Jerry -- I didn't see any functions listed in: http://www.php.net/manual/en/ for DB2 the ODBC maybe you only answers, heres the link: http://www.php.net/manual/en/ref.odbc.php David To connect to Microsoft SQL 7 I'm using the following script which works fine: ?php $query=SELECT * FROM DB1; $queryupd=UPDATE DB1 SET dateval='20010101' where dateval='2101'; $hostname = dbserver; $username = username; $password = pwd; $dbName = DB; mssql_connect($hostname,$username,$password) or die(DATABASE FAILED TO RESPOND.); mssql_select_db($dbName) or DIE(Table unavailable); $result2 = MSSQL_QUERY($queryupd); // Execute Update Statment $result = MSSQL_QUERY($query); // Execute Select Statment $number = MSSQL_NUM_ROWS($result); $i=0; if($number == 0) print No data?; elseif($number 0){ print Number of rows: $numberBR; while($i $number){ $dateval = mssql_result($result,$i,dateval); echo TRTDFONT color=#112266$dateval/FONT/TD; $i++;} } ? Now, how to connect to a DB2 database server without ODBC ? My config is: Web Server: IIS on windows 2000 Server Database Server: IBM DB2 V7.1 on windows 2000 Server PHP4 for windows Thanks. Jerry -- 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] Licensing??
On Saturday 29 December 2001 05:47, Rasmus Lerdorf stuffed this into my mailbox: No it's free hehe :-) but I think they still appreciate any donations :-). For since they are developping software they also have to do research n stuff so sometimes they have to buy books and some testing hardware which mainly is financed by donations I believe (this is general open-source far as I know, not PHP project specific) I'm sure you should be able to find info about it on the homepage. Regards Well, PHP is not under the GPL. But you still don't need to buy any sort of license. -Rasmus On Sat, 29 Dec 2001, Bogdan Stancescu wrote: LOL! You may want to read this for clarification: http://www.gnu.org/philosophy/free-sw.html Bogdan Andrew V. Romero wrote: what do they get out of it? -- 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: XML Parsing Problem
Hi Ben, Had the same problem. The solution I came up with was to populate the value repeatedly by concantenation. $thisxmlval .= (whatever is sent from the parser). Note the . in front of the = As long as the parser is still sending values from this tag, your program should concantenate them, thereby producing one value which was the original content of the tag. kind regards, bill Ben Gollmer wrote: Hi all - I'm experimenting with PHP's XML parser for an application that maps XML tags to MySQL database fields. As a test for my parsing program, I've been grabbing XML from the Slashdot news feed (http://www.slashdot.org/slashdot.xml) and inserting it into a database. This is very simple data - titleblah/title gets inserted into the 'title' field, etc. However, when there are some strange characters in the title field, the XML parser seems to choke. Here is an example. The title of a recent article from Slashdot looks like this in the XML file: titleFollow-up To Critique of BeOS amp;amp; Mac OS X/title Don't ask my why they have a double ampersand in there... Anyway, the XML parser returns this as three sets of data, instead of one. The array that I get looks like this: $myArray[0] = Follow-up To Critique of BeOS $myArray[1] = $myArray[2] = amp; Mac OS X This is the data I get back from the parser, BEFORE putting it into the database. I'm echoing each array field to the screen, just to make sure. So I know it has nothing to do with MySQL. The double ampersand shouldn't make a difference - the XML parser should not be interpreting HTML...right? Also, I don't get an error code or error string from xml_parse(). Anyone have any ideas? This is a subtle bug - in fact I had been satisfied with my XML parsing code, and was well into the rest of my application when I happened to notice this. Ben -- 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 Forms
Mail() function works fine on win32, you need enter smtp server in your php.ini and sendfrom address. example: SMTP = 10.1.25.1 ; for Win32 only sendmail_from = [EMAIL PROTECTED] Valentin Petruchek (aki Zliy Pes) *** ??? ?? *** http://zliypes.com.ua mailto:[EMAIL PROTECTED] - Original Message - From: Matt Obstgarten [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, January 02, 2002 3:48 PM Subject: [PHP] PHP Forms Hello, I am new to PHP. I have PHP (cgi version) configured on my machine running XP Pro and IIS. It works fine. The first script I wanted to write was the ever-useful feedback form script where the contents of a form are e-mailed to the webmaster. I am sure that I have a working script but when I test on my machine I get a server error. I realize that this is most likely because I don't have any mail settings configured on IIS (new to this as well). I was wondering if someone could give me some advice on how to properly set this up so I can locally test mail scripts like this. Thanks, Matt -- 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] URGENT-PDF
Ps2pdf will do EPS. Make sure you have a recent version (it's part of the ghostscript package). For .doc, look at http://www.wvware.com. It does a reasonable job, but complex documents will convert poorly. I haven't yet found a non-commercial source for converting MS Office documents well. The only decent commercial package for Linux I've found which does the MS Office formats (and many others) is KeyPAK (http://www.keypak.com). Good luck... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]. net] On Behalf Of Chamarty Prasanna Kumar Sent: Wednesday, January 02, 2002 12:05 AM To: [EMAIL PROTECTED] Subject: [PHP] URGENT-PDF Hi All, Happy New Year. Known that we can use in Linux to convert a file from ps to pdf by using ps2pdf. Is there any such built-in modules in PHP or SHELL commands to convert the following to PDF. .eps, .ppt, .xls, .doc, .html Please do suggest any other way of doing this using Linux OS. Thanks in advance. Cheers, Kumar. -- 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] Downloading Oracle, crippled?
Anyone downloaded the oracle 9i stuff to use on linux with PHP? What are the limitations, time crippled, table size crippled, function crippled? It seems hard to believe that Larry Ellison would give things away, even to support ways to take market share away from usoft. -- 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] ora_numrows() function
I just wanted to verify the functionality of the ora_numrows() function. On the ora_numrows() manual page it reads that the function returns the number of rows in a result set, but in the ora_getcolumn() documentation it reads that the ora_numrows() function returns the current row number. Could someone please give me a quick clarification? Thanks :) --Sam Sam Masiello Software Quality Assurance Engineer Synacor (716) 853-1362 X289 [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] Session troubles
On 01-02 07:45, Jaime Bozza wrote: I agree. Perhaps make a feature request that disallows session starting if save_handler=user and you haven't defined a session handler?Then it could spit out a more correct error message. Blast. I am still unable to get my own session handler to work. My session handler's write never gets called; only my session_open and session_read get calledthe default file session handler still works, if I change save_handler back to file instead of user. As for the feature request, I guess I could - is there a mechanism to do this outlined somewhere? -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 01, 2002 8:32 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-31 09:23, Jaime Bozza wrote: Sean, From your php error_log, it's saying the following: Failed to write session data (user) which sounds like it's having problems writing to the user-defined session handler. Are you using a user-defined session handler? If not, make sure your php.ini file has: session.save_handler = files And *NOT*: session.save_handler = user That will make a big difference. Good eye. That was it. I *did* have it as user because I was trying to do my own user-defined session handler, and then stepped back and was just trying to get the simpler case to work, w/o changing it back. Thanks, it works now! Now, I just need to see if I can get my session_handler working... It's too bad the error message isn't more descriptive for this, BTW... -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Saturday, December 29, 2001 1:21 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-29 12:56, David Jackson wrote: Sean -- Don't know if this help but here's what I just worked for me. What ver. of PHP are you using? It seem to me that 3.x.x needs PHPLIB: http://sourceforge.net/projects/phplib to handle sessions? -- David Jackson --- sean.php --- ?php include(seaninc.php); ? --- seaninc.php -- ?php session_start(); session_register(i); $i++; echo $i; ? I'm using 4.0.6. I believe session handling was added as part of standard 4.x, right (if configured to compile it)? Some more info: I tried with Konqueror, as I know a cookie needs to be sent during the session_start() phase - I did get a dialog pop-up asking if I wanted to accept the cookie, but I still got the error: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 It says line 2 because I deleted some white space and commented out code thas was before session_start(). I set logging errors on, and sent it to syslog. Here's what it says: Dec 29 12:12:57 free httpd: PHP Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 Dec 29 12:12:57 free httpd: PHP Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0 But /tmp exists, and is world writeable: free# ls -ld /tmp drwxrwxrwt 16 root wheel 1024 Dec 29 12:14 /tmp On 12-29 09:59, Miles Thompson wrote: Sean, What's going on in incl.php. Are you issuing a session_start()? No, I was not. What if it's rearranged like so, as I understand you have to register the session variable before using it. include(incl.php); session_start(); session_register(mine); $mine++; echo $mine; No dice, either. Actually, I had tried several permutations of the order before posting. :) There's the divide and conquer approach too. What do you see if you comment out the include, then issue a phpinfo() and a die()? Okay, I tried commenting out include, resulting in this code: session_start(); session_register(i); $i++; echo $i; When I run the above, I get this: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 6 Which is getting somewhere, in a way. Line 6 is session_start(); What part from phpinfo() output were you interested in? Or did you want to see all of it? Thanks for the help. HTH and Merry Christmas / Happy New Year - Miles Thompson On Friday 28 December 2001 11:26 pm, Sean LeBlanc wrote: I asked this on php-install list, but got no response so here goes... I simply cannot get session to work correctly. Here's the test script: include(incl.php); session_start(); $mine++; session_register(mine); echo $mine; incl.php includes code to save/retrieve session information to/from DB. It calles
[PHP] Re: Extract a string from a string
$find = hi; $contents = implode(null, file($logfile)); $contents = preg_replace(/($find)/i, b style=\color:black;background-color:#FFCC66\\\1/b, $contents); echo $contents; that will replace any $find with your highlighted b. Notice the i at the end preg expression, that tells it to ignore case. The nice part about that is that if you search for HI, if finds hi, it will highlight hi, not HI. Enjoy. -Joe Qartis [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I've got a search script, where you can search for a string and it will return links to the HTML files that contain the string. I've also written a function, where it will highlight each instance of the searched string by using: $asdf = fopen($logfile, r); $contents = fread($asdf,filesize($logfile)); fclose($asdf); $contents=stri_replace($hi,b style=\color:black;background-color:#FFCC66\.$hi./b, $contents); echo $contents; (stri_replace because I wrote a function to do that) Where $hi is the string that is to be highlighted. Of course, if the user searched for HI, and Hi was found, it would show up as a highlighted HI, becuase it only uses $hi as the highlighted word, not the original string. I'm fairly sure that I could do this with ereg functions, but I've spent too long looking and now it just about makes me sick just looking at it. Pleeease, can anybody help? -qartis -- 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] Setting PHP vars in Apache Directives
We are deciding which language we will move in to, PHP or Perl. Once thing that Perl allows is the setting of variables from an Apache directive (Vhost, Directory, Location, etc). I've been looking thru the mod_php module, but I havn't see this ability of PHP. It's looking like it's possible to modify the mod_php module for Apache to support this, but I wanted to see if anyone has hit this problem before. using mod_perl it would be done as: Location / PerlSetVarfoobar /Location using mod_php it would be nice to have it as: Location / php_set_varfoobar /Location I do know of the php_value, php_flag, php_admin_value, php_admin_flag but these are only for INI settings. Thanks for any help before I attempt to modify mod_php ;) Joe Webster -- 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: Regular Expression
preg_match(/body\s([^]*)/i, $html, $args); $body_props = $args[1]; preg is much faster/better than ereg. note the /i at the end of the preg, that makes it case insative, drop the i if you want it to be case sensative on the match. -Joe John Monfort [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello everyone! I'm trying to get the text inside the BODY tag, using regular expression. $area = eregi('(body)(.*))',$str); Where $str is the string containing body bgcolor=#99 tex=#... ... When I print $area, the string contains the entire content of $str. I get something like: body ... p . . . /body /html __John Monfort_ _+---+_ P E P I E D E S I G N S www.pepiedesigns.com The world is waiting, are you ready? -+___+- -- 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: Test
dork John Monfort [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Test: cannot send mail, but can read. Please ignore. -- 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] easy quickie..
Happy New Year, Does php set a variable that tells you the url of the page that a user has just come from? So if I wanted to create my own 'Back' button in a pop up window, for instance? Thanks in advance, Kelly -- 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] easy quickie..
I think it is $HTTP_SERVER_VARS['HTTP_REFERER'] Regards, Andrey Hristov - Original Message - From: Kelly Meeks [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, January 02, 2002 8:15 PM Subject: [PHP] easy quickie.. Happy New Year, Does php set a variable that tells you the url of the page that a user has just come from? So if I wanted to create my own 'Back' button in a pop up window, for instance? Thanks in advance, Kelly -- 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] easy quickie..
I think it is $HTTP_SERVER_VARS['HTTP_REFERER'] Except that the value for this variable isn't always set and can be spoofed. This value should not be relied upon. Oftentimes (though, you'd have to be creative to make this work in a seperate window), what I use to send the user back to where they came from is this: a href=javascript:history.back();Back /a Chris
[PHP] Re: [PHP-DB] Connect to IBM DB2
Hi, IBM DB/2 uses Call Level Interface (CLI) for communication between clients and server. The ODBC driver from IBM is a simple one to one wrapper arround CLI, as CLI and ODBC share the same specifications. Using ODBC will give you an extra layer though. On *nix platforms you can compile usen --with-ibm-db2 and get the ODBC functions linked directly with CLI. This is not currently available on Windows. - Frank To connect to Microsoft SQL 7 I'm using the following script which works fine: ?php $query=SELECT * FROM DB1; $queryupd=UPDATE DB1 SET dateval='20010101' where dateval='2101'; $hostname = dbserver; $username = username; $password = pwd; $dbName = DB; mssql_connect($hostname,$username,$password) or die(DATABASE FAILED TO RESPOND.); mssql_select_db($dbName) or DIE(Table unavailable); $result2 = MSSQL_QUERY($queryupd); // Execute Update Statment $result = MSSQL_QUERY($query); // Execute Select Statment $number = MSSQL_NUM_ROWS($result); $i=0; if($number == 0) print No data?; elseif($number 0){ print Number of rows: $numberBR; while($i $number){ $dateval = mssql_result($result,$i,dateval); echo TRTDFONT color=#112266$dateval/FONT/TD; $i++;} } ? Now, how to connect to a DB2 database server without ODBC ? My config is: Web Server: IIS on windows 2000 Server Database Server: IBM DB2 V7.1 on windows 2000 Server PHP4 for windows Thanks. Jerry -- PHP Database 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] Licensing??
I would like to note that you may need to purchase licensing for certain uses. For instance, I use ClibPDF on OS X. If I ever use it for commercial purposes (which I am planning to do, btw) I will need to purchase a license from FastIO for use of the ClibPDF library. On Wed, 2 Jan 2002 23:00:23 +0100 TD - Sales International Holland B.V. [EMAIL PROTECTED] mentioned: On Saturday 29 December 2001 05:47, Rasmus Lerdorf stuffed this into my mailbox: No it's free hehe :-) but I think they still appreciate any donations :-). For since they are developping software they also have to do research n stuff so sometimes they have to buy books and some testing hardware which mainly is financed by donations I believe (this is general open-source far as I know, not PHP project specific) I'm sure you should be able to find info about it on the homepage. Regards -- 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] easy quickie..
Seb, I tend to agree that some webmasters would do better if they did less and tried not to be so helpful to the user. But custom back buttons can be very useful when used in presentations such as page by page instructions and slideshows without having to hardcode the HTML which (if you forgive the expletive) is a friggin' pain in the ass. :) Esspecialy when you have to code dozens of pages. If the custom back button is implimented properly the user shouldn't ever know the difference between it and a link. -Kevin - Original Message - From: Seb Frost [EMAIL PROTECTED] To: Kelly Meeks [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, January 02, 2002 12:20 PM Subject: RE: [PHP] easy quickie.. I've never understood why people do this? My browser has a back button. I know how to use it. It's only a centimetre of mouse travel away from the page I'm looking at, why do I need a duplicate? - seb -Original Message- From: Kelly Meeks [mailto:[EMAIL PROTECTED]] Happy New Year, Does php set a variable that tells you the url of the page that a user has just come from? So if I wanted to create my own 'Back' button in a pop up window, for instance? Thanks in advance, Kelly --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.307 / Virus Database: 168 - Release Date: 11/12/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 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] array_multisort?
Unless your problem is more extensive than what you're explaining here, there's no reason to do any kind of sort. Simply reorder the list yourself so that whatever ends up in $title is reordered to the first index of your $shop list... $product = array ($id, $title, $price); $shop = array ($product[1], $product[0], $product[2]); -Kevin - Original Message - From: Sebastiaan Timmers - Bean IT [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, January 02, 2002 6:47 AM Subject: [PHP] array_multisort? Hi List, I'm having a problem sorting the following array: $product = array($id, $title, $price); $shop[] = $product; I want the array 'shop' to be sorted by the 'title' in array 'product'. I tried the function 'array_multisort()', but that did not do the trick. Does anyone know how to fix this? Best regards, Sebastiaan Timmers -- 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] easy quickie..
I've never understood why people do this? My browser has a back button. I know how to use it. It's only a centimetre of mouse travel away from the page I'm looking at, why do I need a duplicate? - seb -Original Message- From: Kelly Meeks [mailto:[EMAIL PROTECTED]] Happy New Year, Does php set a variable that tells you the url of the page that a user has just come from? So if I wanted to create my own 'Back' button in a pop up window, for instance? Thanks in advance, Kelly --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.307 / Virus Database: 168 - Release Date: 11/12/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] Including files variables ...
What you need to do is simply set the variables before you include the script. When you include a script with include() or require(), they fall into the same namespace as the include() or require() function that called them. Best Regards, Jason Garber IonZoft.com At 06:54 PM 1/28/2002 -0800, Evansville Scene wrote: I'm having problems passing variables into included PHP files. How can I do this? -- 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] ref IRC
Hi all, I have a few problems. I'm trying to write a PHP script that will function as a webchat. Currently I have soms problems. How can I get each line of the in/output ? This is what a part of what I currently have: ? function con($hport,$Something,$who){ $fp = fsockopen($who, $hport, $errno, $errstr, 4); if (!$fp){ print Cannot connect to IRC server.; } else { echo Connecting ..br\n; if($nick == ) { $nick = Testing; } fputs($fp, NICK $nick\n); echo Send nick ..br\n; $ping = fgets($fp,1024); echo Ping = $ping ..br\n; $reply = substr($ping, 6,13); fputs($fp, PONG $reply\n); echo Replying with $reply ..br\n; fputs($fp, USER d d d :$UNIQUE_ID\n); echo Sending user information ..br\n; fputs($fp, JOIN #test\n); fpassthru($fp); } } ? centerh3IRC/h3/center ?PHP $domain = 127.0.0.1; echo con(6667,Ircd,$domain); ? I'm writing this because I couldn't find any good htmlchat. Anyone who want to help ? Fazke -- 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] easy quickie..
_Your_ browser has a back button.. great.. There are many situations in which the back button may not be visible/available/appropriate. You may also not want to go back in your _history_, just back to the previous page - and possibly set some variables in the page request. It is far more than a duplicate of the back button. Matt. -Original Message- From: Seb Frost [mailto:[EMAIL PROTECTED]] Sent: 02 January 2002 19:21 To: Kelly Meeks; [EMAIL PROTECTED] Subject: RE: [PHP] easy quickie.. I've never understood why people do this? My browser has a back button. I know how to use it. It's only a centimetre of mouse travel away from the page I'm looking at, why do I need a duplicate? - seb -Original Message- From: Kelly Meeks [mailto:[EMAIL PROTECTED]] Happy New Year, Does php set a variable that tells you the url of the page that a user has just come from? So if I wanted to create my own 'Back' button in a pop up window, for instance? Thanks in advance, Kelly --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.307 / Virus Database: 168 - Release Date: 11/12/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 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 Problem
Hi there, This is not a bug.. this is expected behaviour. The string would be chopped up into 3 parts because you have : 1. a string: Follow-up To Critique of BeOS 2. a predefined entity : amp; 3. a string: amp; Mac OS X There are not actually two ampersands.. you have amp; followed by amp; - this is so that once it has been parsed you end up with amp; which will display correctly in most HTML browsers. Note that amp; is a usually a predefined entity in XML and so will be replaced with . HTH Matt. -Original Message- From: Ben Gollmer [mailto:[EMAIL PROTECTED]] Sent: 01 January 2002 00:23 To: [EMAIL PROTECTED] Subject: [PHP] XML Parsing Problem Hi all - I'm experimenting with PHP's XML parser for an application that maps XML tags to MySQL database fields. As a test for my parsing program, I've been grabbing XML from the Slashdot news feed (http://www.slashdot.org/slashdot.xml) and inserting it into a database. This is very simple data - titleblah/title gets inserted into the 'title' field, etc. However, when there are some strange characters in the title field, the XML parser seems to choke. Here is an example. The title of a recent article from Slashdot looks like this in the XML file: titleFollow-up To Critique of BeOS amp;amp; Mac OS X/title Don't ask my why they have a double ampersand in there... Anyway, the XML parser returns this as three sets of data, instead of one. The array that I get looks like this: $myArray[0] = Follow-up To Critique of BeOS $myArray[1] = $myArray[2] = amp; Mac OS X This is the data I get back from the parser, BEFORE putting it into the database. I'm echoing each array field to the screen, just to make sure. So I know it has nothing to do with MySQL. The double ampersand shouldn't make a difference - the XML parser should not be interpreting HTML...right? Also, I don't get an error code or error string from xml_parse(). Anyone have any ideas? This is a subtle bug - in fact I had been satisfied with my XML parsing code, and was well into the rest of my application when I happened to notice this. Ben -- 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] surepay without curl?
Hi list, I haven't been reading the list for a while but ran into a problem that I don't know if I can solve on my own. I'm working on a server running PHP 3.0.13 without curl support. Am I out of luck? -- Data Driven Design 1506 Tuscaloosa Ave Holly Hill, Florida 32117 Phone : (386) 226-8979 http://www.datadrivendesign.com Websites That WORK For You -- 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] INI file parsing
Does PHP parse the ini file every time a file is requested? I am trying to track down a problem on various pages where the timelimit will expire. These are not complex pages and when I go to them they work fine. I have used the same browser that the user eses when the timeout occurs. Nothing strange for me. I have looked at the line that the error log specifies and it is just random lines. sometimes it is a '}'. As if the script just ran out of time on that line. BTW '}' is the closing of an if statement so it isnt stuck in a loop. And when I go to the page I make sure to use the same querystring that the user sent. Another thought, is the php engine slowed by users with a slow connection? Charles Killmer NetgainTechnology.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] Session troubles
What do you have for the return values for your session_read function? (Specifically, what do you return when there's no data available?) Jaime Bozza -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 11:20 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 01-02 07:45, Jaime Bozza wrote: I agree. Perhaps make a feature request that disallows session starting if save_handler=user and you haven't defined a session handler? Then it could spit out a more correct error message. Blast. I am still unable to get my own session handler to work. My session handler's write never gets called; only my session_open and session_read get calledthe default file session handler still works, if I change save_handler back to file instead of user. As for the feature request, I guess I could - is there a mechanism to do this outlined somewhere? -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 01, 2002 8:32 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-31 09:23, Jaime Bozza wrote: Sean, From your php error_log, it's saying the following: Failed to write session data (user) which sounds like it's having problems writing to the user-defined session handler. Are you using a user-defined session handler? If not, make sure your php.ini file has: session.save_handler = files And *NOT*: session.save_handler = user That will make a big difference. Good eye. That was it. I *did* have it as user because I was trying to do my own user-defined session handler, and then stepped back and was just trying to get the simpler case to work, w/o changing it back. Thanks, it works now! Now, I just need to see if I can get my session_handler working... It's too bad the error message isn't more descriptive for this, BTW... -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Saturday, December 29, 2001 1:21 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-29 12:56, David Jackson wrote: Sean -- Don't know if this help but here's what I just worked for me. What ver. of PHP are you using? It seem to me that 3.x.x needs PHPLIB: http://sourceforge.net/projects/phplib to handle sessions? -- David Jackson --- sean.php --- ?php include(seaninc.php); ? --- seaninc.php -- ?php session_start(); session_register(i); $i++; echo $i; ? I'm using 4.0.6. I believe session handling was added as part of standard 4.x, right (if configured to compile it)? Some more info: I tried with Konqueror, as I know a cookie needs to be sent during the session_start() phase - I did get a dialog pop-up asking if I wanted to accept the cookie, but I still got the error: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 It says line 2 because I deleted some white space and commented out code thas was before session_start(). I set logging errors on, and sent it to syslog. Here's what it says: Dec 29 12:12:57 free httpd: PHP Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 Dec 29 12:12:57 free httpd: PHP Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0 But /tmp exists, and is world writeable: free# ls -ld /tmp drwxrwxrwt 16 root wheel 1024 Dec 29 12:14 /tmp On 12-29 09:59, Miles Thompson wrote: Sean, What's going on in incl.php. Are you issuing a session_start()? No, I was not. What if it's rearranged like so, as I understand you have to register the session variable before using it. include(incl.php); session_start(); session_register(mine); $mine++; echo $mine; No dice, either. Actually, I had tried several permutations of the order before posting. :) There's the divide and conquer approach too. What do you see if you comment out the include, then issue a phpinfo() and a die()? Okay, I tried commenting out include, resulting in this code: session_start(); session_register(i); $i++; echo $i; When I run the above, I get this: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 6 Which is getting somewhere, in a way. Line 6 is session_start(); What part from phpinfo() output were you interested in? Or did you want to see all of it? Thanks for the help. HTH and Merry Christmas / Happy New Year - Miles Thompson On Friday 28 December 2001 11:26 pm, Sean LeBlanc wrote: I asked this on php-install list, but got no
[PHP] Re: Hosting provider...
www.tedoc.nl 100% Microsoft Free Matt Moreton [EMAIL PROTECTED] wrote in message 001401c19323$18d44ef0$38bc7ad5@summy">news:001401c19323$18d44ef0$38bc7ad5@summy... Im looking to change my hosting provider. ...something that isnt going to break the bank, is feature full, supports mysql, php etc etc and doesnt limit your bandwidth usage! I need about 100+ mb's of space, and possibly the ability to run a background process. Can anyone here suggest a good provider that meets the above criteria? Thanks Matt. -- 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 Page Title
Hi, To get the title of an external page to put into a link, has somebody did that already and can give me some hints for this trick Robert -- 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] INI file parsing
I am running IIS 5.0 Windows 2000 Server. Changes made to the ini take effect immediately. So it seems that php in Windows and IIS reloads the ini every time a page is requested? Charles Killmer -- Original Message -- From: Joe Webster [EMAIL PROTECTED] Date: Wed, 2 Jan 2002 15:46:32 -0500 no you need to restart apache to change an in setting. So it loads the settings once per server start (at least with apache). Charlesk [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Does PHP parse the ini file every time a file is requested? I am trying to track down a problem on various pages where the timelimit will expire. These are not complex pages and when I go to them they work fine. I have used the same browser that the user eses when the timeout occurs. Nothing strange for me. I have looked at the line that the error log specifies and it is just random lines. sometimes it is a '}'. As if the script just ran out of time on that line. BTW '}' is the closing of an if statement so it isnt stuck in a loop. And when I go to the page I make sure to use the same querystring that the user sent. Another thought, is the php engine slowed by users with a slow connection? Charles Killmer NetgainTechnology.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] INI file parsing
If so that would be totally shitty (in the respects of effecienty) Charlesk [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I am running IIS 5.0 Windows 2000 Server. Changes made to the ini take effect immediately. So it seems that php in Windows and IIS reloads the ini every time a page is requested? Charles Killmer -- Original Message -- From: Joe Webster [EMAIL PROTECTED] Date: Wed, 2 Jan 2002 15:46:32 -0500 no you need to restart apache to change an in setting. So it loads the settings once per server start (at least with apache). Charlesk [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Does PHP parse the ini file every time a file is requested? I am trying to track down a problem on various pages where the timelimit will expire. These are not complex pages and when I go to them they work fine. I have used the same browser that the user eses when the timeout occurs. Nothing strange for me. I have looked at the line that the error log specifies and it is just random lines. sometimes it is a '}'. As if the script just ran out of time on that line. BTW '}' is the closing of an if statement so it isnt stuck in a loop. And when I go to the page I make sure to use the same querystring that the user sent. Another thought, is the php engine slowed by users with a slow connection? Charles Killmer NetgainTechnology.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] Cookies In Images...
Can anyone give me a pointer on where to go to find out how to send cookies through images, preferably in PHP? Matthew Walker Ecommerce Project Manager Mountain Top Herbs --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.310 / Virus Database: 171 - Release Date: 12/19/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] Forking in PHP
This works almost. Instead of having echo hello; you have a huge process that takes a while, the browser wont redirect until the script is finished. This seems to be a feature of IIS. Has anyone found a way to do something similar in PHP 4.1.0, IIS 5.0, Windows 2000 Server? I basically want a way for the user to see a different page than have them waiting for the script to finish. ? if ($process) { echo cool; } else { header(Location: test2.php4?process=true); error_log(this means it works\r\n,3,c:\errors\errors.txt); echo hello; } ? Charles Killmer NetgainTechnology.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] Cookies In Images...
On Wed, 2 Jan 2002 14:11:39 -0700, Matthew Walker wrote: Can anyone give me a pointer on where to go to find out how to send cookies through images, preferably in PHP? To do this you will have to point the HREF in your IMG tag to a PHP script. From that script you should do this: - Pass the correct content-type header (default for PHP is text/html) for example: ? header(Content-Type: image/jpeg); ? - Set the cookie as usual - Then send the contents of the image you would like to display, for example: ? readfile(test.jpg); ? bvr. -- 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] Cookies In Images...
Thanks. That's what I suspected, but I needed to make sure. Matthew Walker Ecommerce Project Manager Mountain Top Herbs -Original Message- From: Bas van Rooijen [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 2:28 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Cookies In Images... On Wed, 2 Jan 2002 14:11:39 -0700, Matthew Walker wrote: Can anyone give me a pointer on where to go to find out how to send cookies through images, preferably in PHP? To do this you will have to point the HREF in your IMG tag to a PHP script. From that script you should do this: - Pass the correct content-type header (default for PHP is text/html) for example: ? header(Content-Type: image/jpeg); ? - Set the cookie as usual - Then send the contents of the image you would like to display, for example: ? readfile(test.jpg); ? bvr. -- 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] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.310 / Virus Database: 171 - Release Date: 12/19/2001 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.310 / Virus Database: 171 - Release Date: 12/19/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] Quick question about recompiling with GD library
Hello, I have png/jpeg support and gd 1.8.3 I see, however, some linux ./configure examples that just use --with-gd and no --with=/usr/local/png or whatever the question is, would --with-gd be enough to create/add text to jpeg/png or *only* if they are included? Just want to double check Thanks Joel Ps. Is there a way php can access the .so file without compiling that library? I saw an example where they connected to the ming (To create flash files) .so file, is that a workaround from having to ./configure and is it bad practice?
Re: [PHP] Forking in PHP
Hi, You could use register_shutdown_function() which should be called before the script ends (duh!). Define a function for your process and pass it's name to register_shutdown_function() . bvr. On Wed, 2 Jan 2002 15:14:59 -0600, charlesk wrote: This works almost. Instead of having echo hello; you have a huge process that takes a while, the browser wont redirect until the script is finished. This seems to be a feature of IIS. Has anyone found a way to do something similar in PHP 4.1.0, IIS 5.0, Windows 2000 Server? I basically want a way for the user to see a different page than have them waiting for the script to finish. ? if ($process) { echo cool; } else { header(Location: test2.php4?process=true); error_log(this means it works\r\n,3,c:\errors\errors.txt); echo hello; } ? Charles Killmer NetgainTechnology.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] Forking in PHP
Thanks for the reply but leave the duh's! out of comments please. -- Original Message -- From: Bas van Rooijen [EMAIL PROTECTED] Reply-To: Bas van Rooijen [EMAIL PROTECTED] Date: Wed, 02 Jan 2002 22:32:53 +0100 Hi, You could use register_shutdown_function() which should be called before the script ends (duh!). Define a function for your process and pass it's name to register_shutdown_function() . bvr. On Wed, 2 Jan 2002 15:14:59 -0600, charlesk wrote: This works almost. Instead of having echo hello; you have a huge process that takes a while, the browser wont redirect until the script is finished. This seems to be a feature of IIS. Has anyone found a way to do something similar in PHP 4.1.0, IIS 5.0, Windows 2000 Server? I basically want a way for the user to see a different page than have them waiting for the script to finish. ? if ($process) { echo cool; } else { header(Location: test2.php4?process=true); error_log(this means it works\r\n,3,c:\errors\errors.txt); echo hello; } ? Charles Killmer NetgainTechnology.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] PHP 4.1.1 + Apache 2.0.30 Ouput Filter....
The following URL works, but then the next one doesn't. Can someone offer some advice on this? http://digitalroadkill.net:8080/ works. index.php is happy and the output filters work. http://digitalroadkill.net:8080/Galleries/ does not work. It tries to get the file as though it were not understood by the output filter. I'm using the following for the OuputFilter lines in my httpd.conf: # #For PHP to work AddType application/x-httpd-php .php .html FilesMatch *.php SetInputFilter php SetOutputFilter php /FilesMatch BTW, FilesMatch *.php,*.html doesn't seem to work anymore. That's what I used to use, and everything was hunky dory. -- Austin Gonyou Systems Architect, CCNA Coremetrics, Inc. Phone: 512-698-7250 email: [EMAIL PROTECTED] It is the part of a good shepherd to shear his flock, not to skin it. Latin Proverb signature.asc Description: This is a digitally signed message part
Re: [PHP] Re: Hosting provider...
At 21:56 2-1-02 +0100, R. Elsenaar wrote: www.tedoc.nl 100% Microsoft Free They are expensive. But please.. this subject has been beaten till dead.. at least a zillion messages should be in the archive.. O well.. a few less :-) Bye, B. -- 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] Forking in PHP
Thanks for the reply but leave the duh's! out of comments please. I'll think about it ;) bvr. -- 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] Session troubles
On 01-02 14:31, Jaime Bozza wrote: What do you have for the return values for your session_read function? (Specifically, what do you return when there's no data available?) Well, it turns out that write *is* being called, but due to some feature of session write, echo and print don't work, as I read on bugs.php.net. So I put a file-writing mechanism in there and I see it is being called and what was happening. I was trying to do an insert all the time, due to bad logic, so it was cycling to 2, then stopping. Now it seems to work properly. :) As for the session read, I return false when no value is found. Jaime Bozza -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 11:20 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 01-02 07:45, Jaime Bozza wrote: I agree. Perhaps make a feature request that disallows session starting if save_handler=user and you haven't defined a session handler? Then it could spit out a more correct error message. Blast. I am still unable to get my own session handler to work. My session handler's write never gets called; only my session_open and session_read get calledthe default file session handler still works, if I change save_handler back to file instead of user. As for the feature request, I guess I could - is there a mechanism to do this outlined somewhere? -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 01, 2002 8:32 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-31 09:23, Jaime Bozza wrote: Sean, From your php error_log, it's saying the following: Failed to write session data (user) which sounds like it's having problems writing to the user-defined session handler. Are you using a user-defined session handler? If not, make sure your php.ini file has: session.save_handler = files And *NOT*: session.save_handler = user That will make a big difference. Good eye. That was it. I *did* have it as user because I was trying to do my own user-defined session handler, and then stepped back and was just trying to get the simpler case to work, w/o changing it back. Thanks, it works now! Now, I just need to see if I can get my session_handler working... It's too bad the error message isn't more descriptive for this, BTW... -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Saturday, December 29, 2001 1:21 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-29 12:56, David Jackson wrote: Sean -- Don't know if this help but here's what I just worked for me. What ver. of PHP are you using? It seem to me that 3.x.x needs PHPLIB: http://sourceforge.net/projects/phplib to handle sessions? -- David Jackson --- sean.php --- ?php include(seaninc.php); ? --- seaninc.php -- ?php session_start(); session_register(i); $i++; echo $i; ? I'm using 4.0.6. I believe session handling was added as part of standard 4.x, right (if configured to compile it)? Some more info: I tried with Konqueror, as I know a cookie needs to be sent during the session_start() phase - I did get a dialog pop-up asking if I wanted to accept the cookie, but I still got the error: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 It says line 2 because I deleted some white space and commented out code thas was before session_start(). I set logging errors on, and sent it to syslog. Here's what it says: Dec 29 12:12:57 free httpd: PHP Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 Dec 29 12:12:57 free httpd: PHP Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0 But /tmp exists, and is world writeable: free# ls -ld /tmp drwxrwxrwt 16 root wheel 1024 Dec 29 12:14 /tmp On 12-29 09:59, Miles Thompson wrote: Sean, What's going on in incl.php. Are you issuing a session_start()? No, I was not. What if it's rearranged like so, as I understand you have to register the session variable before using it. include(incl.php); session_start(); session_register(mine); $mine++; echo $mine; No dice, either. Actually, I had tried several permutations of the order before posting. :) There's the divide and conquer approach too. What do you see if you comment out the include, then issue a phpinfo() and a die()? Okay, I tried commenting out include, resulting in this code:
Re: [PHP] Forking in PHP
register_shutdown_function() doesnt work either. Seems to be IIS caching the output until the script finishes. Anyone else have an idea? -- Original Message -- From: Bas van Rooijen [EMAIL PROTECTED] Reply-To: Bas van Rooijen [EMAIL PROTECTED] Date: Wed, 02 Jan 2002 22:32:53 +0100 Hi, You could use register_shutdown_function() which should be called before the script ends (duh!). Define a function for your process and pass it's name to register_shutdown_function() . bvr. On Wed, 2 Jan 2002 15:14:59 -0600, charlesk wrote: This works almost. Instead of having echo hello; you have a huge process that takes a while, the browser wont redirect until the script is finished. This seems to be a feature of IIS. Has anyone found a way to do something similar in PHP 4.1.0, IIS 5.0, Windows 2000 Server? I basically want a way for the user to see a different page than have them waiting for the script to finish. ? if ($process) { echo cool; } else { header(Location: test2.php4?process=true); error_log(this means it works\r\n,3,c:\errors\errors.txt); echo hello; } ? Charles Killmer NetgainTechnology.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] Session troubles
Returning false is invalid for the session read function, and has caused *MANY* issues with PHP and Sessions. (Check the archives as well as the bugs database. I have a couple in there myself) Change: return false; To: return ''; And things should start working as expected. Jaime Bozza -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 4:02 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 01-02 14:31, Jaime Bozza wrote: What do you have for the return values for your session_read function? (Specifically, what do you return when there's no data available?) Well, it turns out that write *is* being called, but due to some feature of session write, echo and print don't work, as I read on bugs.php.net. So I put a file-writing mechanism in there and I see it is being called and what was happening. I was trying to do an insert all the time, due to bad logic, so it was cycling to 2, then stopping. Now it seems to work properly. :) As for the session read, I return false when no value is found. Jaime Bozza -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 02, 2002 11:20 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 01-02 07:45, Jaime Bozza wrote: I agree. Perhaps make a feature request that disallows session starting if save_handler=user and you haven't defined a session handler? Then it could spit out a more correct error message. Blast. I am still unable to get my own session handler to work. My session handler's write never gets called; only my session_open and session_read get calledthe default file session handler still works, if I change save_handler back to file instead of user. As for the feature request, I guess I could - is there a mechanism to do this outlined somewhere? -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 01, 2002 8:32 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-31 09:23, Jaime Bozza wrote: Sean, From your php error_log, it's saying the following: Failed to write session data (user) which sounds like it's having problems writing to the user-defined session handler. Are you using a user-defined session handler? If not, make sure your php.ini file has: session.save_handler = files And *NOT*: session.save_handler = user That will make a big difference. Good eye. That was it. I *did* have it as user because I was trying to do my own user-defined session handler, and then stepped back and was just trying to get the simpler case to work, w/o changing it back. Thanks, it works now! Now, I just need to see if I can get my session_handler working... It's too bad the error message isn't more descriptive for this, BTW... -Original Message- From: Sean LeBlanc [mailto:[EMAIL PROTECTED]] Sent: Saturday, December 29, 2001 1:21 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Session troubles On 12-29 12:56, David Jackson wrote: Sean -- Don't know if this help but here's what I just worked for me. What ver. of PHP are you using? It seem to me that 3.x.x needs PHPLIB: http://sourceforge.net/projects/phplib to handle sessions? -- David Jackson --- sean.php --- ?php include(seaninc.php); ? --- seaninc.php -- ?php session_start(); session_register(i); $i++; echo $i; ? I'm using 4.0.6. I believe session handling was added as part of standard 4.x, right (if configured to compile it)? Some more info: I tried with Konqueror, as I know a cookie needs to be sent during the session_start() phase - I did get a dialog pop-up asking if I wanted to accept the cookie, but I still got the error: Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 It says line 2 because I deleted some white space and commented out code thas was before session_start(). I set logging errors on, and sent it to syslog. Here's what it says: Dec 29 12:12:57 free httpd: PHP Fatal error: Failed to initialize session module in /usr/local/apache/htdocs/sesstest.php on line 2 Dec 29 12:12:57 free httpd: PHP Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0 But /tmp exists, and is world writeable: free# ls -ld /tmp drwxrwxrwt 16 root wheel 1024 Dec 29 12:14 /tmp On 12-29 09:59, Miles Thompson wrote: Sean, What's going on in incl.php. Are you issuing a session_start()? No, I was not. What if it's rearranged like so, as I understand you have to
RE: [PHP] ora_numrows() function
someone left this comment on the php site - [EMAIL PROTECTED] at 27-Dec-2000 09:37 It is important to note that this function acts more as a counter of the number of rows fetched from the cursor. If you execute this prior to processing the cursor you will always get a 0 for an answer. The online manual and one of my PHP reference books does not make that distinction. Some may expect this to count the number of rows in the cursor prior to processing. This function does not do that. -- hope that helps - from this, it sounds like it effectively returns the current row -Original Message- From: Sam Masiello [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 3:46 AM To: PHP General Subject: [PHP] ora_numrows() function I just wanted to verify the functionality of the ora_numrows() function. On the ora_numrows() manual page it reads that the function returns the number of rows in a result set, but in the ora_getcolumn() documentation it reads that the ora_numrows() function returns the current row number. Could someone please give me a quick clarification? Thanks :) --Sam Sam Masiello Software Quality Assurance Engineer Synacor (716) 853-1362 X289 [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.1.1 + Apache 2.0.30 Ouput Filter....
Ok. I fixed it. I just had my filters jacked up. After fixing them using \.php instead of *.php, I was then calling the wrong page and getting a 404, plus the browser I was using had cached the content-type and was screwing everything up. After just shutting down my browsers, dumping cache, resetting apache, rechecking my filters, everything is fine. Thanks to anyone who was thinking. On Wed, 2002-01-02 at 15:35, Austin Gonyou wrote: The following URL works, but then the next one doesn't. Can someone offer some advice on this? http://digitalroadkill.net:8080/ works. index.php is happy and the output filters work. http://digitalroadkill.net:8080/Galleries/ does not work. It tries to get the file as though it were not understood by the output filter. I'm using the following for the OuputFilter lines in my httpd.conf: # #For PHP to work AddType application/x-httpd-php .php .html FilesMatch *.php SetInputFilter php SetOutputFilter php /FilesMatch BTW, FilesMatch *.php,*.html doesn't seem to work anymore. That's what I used to use, and everything was hunky dory. -- Austin Gonyou Systems Architect, CCNA Coremetrics, Inc. Phone: 512-698-7250 email: [EMAIL PROTECTED] It is the part of a good shepherd to shear his flock, not to skin it. Latin Proverb -- Austin Gonyou Systems Architect, CCNA Coremetrics, Inc. Phone: 512-698-7250 email: [EMAIL PROTECTED] It is the part of a good shepherd to shear his flock, not to skin it. Latin Proverb signature.asc Description: This is a digitally signed message part
Re: [PHP] XML Parsing Problem
Ok, I can understand the predefined entity replacement. But why does it break the string up into 3 parts? I think it should just return Follow-up To Critique of BeOS amp; Mac OS X. Ben On Wednesday, January 2, 2002, at 02:05 PM, Matthew Clark wrote: Hi there, This is not a bug.. this is expected behaviour. The string would be chopped up into 3 parts because you have : 1. a string: Follow-up To Critique of BeOS 2. a predefined entity : amp; 3. a string: amp; Mac OS X There are not actually two ampersands.. you have amp; followed by amp; - this is so that once it has been parsed you end up with amp; which will display correctly in most HTML browsers. Note that amp; is a usually a predefined entity in XML and so will be replaced with . HTH Matt. -Original Message- From: Ben Gollmer [mailto:[EMAIL PROTECTED]] Sent: 01 January 2002 00:23 To: [EMAIL PROTECTED] Subject: [PHP] XML Parsing Problem Hi all - I'm experimenting with PHP's XML parser for an application that maps XML tags to MySQL database fields. As a test for my parsing program, I've been grabbing XML from the Slashdot news feed (http://www.slashdot.org/slashdot.xml) and inserting it into a database. This is very simple data - titleblah/title gets inserted into the 'title' field, etc. However, when there are some strange characters in the title field, the XML parser seems to choke. Here is an example. The title of a recent article from Slashdot looks like this in the XML file: titleFollow-up To Critique of BeOS amp;amp; Mac OS X/title Don't ask my why they have a double ampersand in there... Anyway, the XML parser returns this as three sets of data, instead of one. The array that I get looks like this: $myArray[0] = Follow-up To Critique of BeOS $myArray[1] = $myArray[2] = amp; Mac OS X This is the data I get back from the parser, BEFORE putting it into the database. I'm echoing each array field to the screen, just to make sure. So I know it has nothing to do with MySQL. The double ampersand shouldn't make a difference - the XML parser should not be interpreting HTML...right? Also, I don't get an error code or error string from xml_parse(). Anyone have any ideas? This is a subtle bug - in fact I had been satisfied with my XML parsing code, and was well into the rest of my application when I happened to notice this. Ben -- 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] Re: Get Page Title
R. Elsenaar [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi, To get the title of an external page to put into a link, has somebody did that already and can give me some hints for this trick Robert // Your question managed to spark my interest and get me to write this... // // WARNING: If you are accepting user input for the page URL, you will // want to validate it before passing it to this function. // // I use fopen in order to (hopefully) not need to download the entire // page when we only want something that's likely to be in the first // few lines. // // This is not guarunteed to get the right title, esp. for dynamic pages // or anything // TEST 1: titleFirst Test/title // TEST 2: headtitleSecond Test/title/head // TEST 3: headtitleSecond Test/title/title // This function will return the filename or URL of the page if: // 1. The page has no title.../title tags. // 2. The page cannot be opened. // Consider expanding from this concept. It is not extensively tested. function get_page_title($page) { $contents = implode(' ', file($page)); if(!$contents) return($page); // Something didn't work right. if(eregi('title[^]*([^]*)/title[^]*', $contents, $regs)) { return(trim(ereg_replace('[[:space:]]+', ' ', $regs[1]))); } return($page); } echo get_page_title($path_to_page); -- 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] Fatal error: The script tried to execute a method or access a property of an incomplete object.
I have a problem I'm getting the following error: Fatal error: The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition myappl of the object you are trying to operate on was loaded _before_ the session was started in c:\inetpub\wwwroot\advanced\ClientArea.php on line 23 When I try to execute the following code ? require('library/const.lib.php'); require('library/style.lib.php'); require('library/form.lib.php'); require('library/application.lib.php'); // This file defines the class ? html xmlns:move head link rel=stylesheet type=text/css href=? echo Style::StylesheetDefault() ? / script language=javascript src=script/form.js type=text/javascript/script /head body class=ClientArea ? if (isset($HTTP_SESSION_VARS['MenuItem'])) { $MenuItem = $HTTP_SESSION_VARS['MenuItem']; $appl = $HTTP_SESSION_VARS[APPL_NAME]; switch ($MenuItem) { case 'WM_FILE_EXIT' : $appl-ApplExit(); // This line generates the error break; default: break; } } ? /body /html the application.lib.php file looks like this: ? if (!defined('__APPLICATION_LIB_PHP__')) { define('__APPLICATION_LIB_PHP__',1); class MyAppl { var $Version; function MyAppl() { $this-Version = 0.0.0.1; } function ApplExit() { echo EXIT; } function ApplLogin() { } } } ? Anyone any ideas? Thanks in advanced -- Sturm -- 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] INI file parsing
AFAIK, it will reread the .ini file every time only if you're running PHP as a CGI, as opposed to an Apache module (or ISAPI or NSAPI module, but I don't think either of those are industrial strength yet). SO, yes, the .ini file will be reread each time PHP is called by IIS. -steve At 01:02 PM 1/2/02 , Joe Webster wrote: If so that would be totally shitty (in the respects of effecienty) Charlesk [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I am running IIS 5.0 Windows 2000 Server. Changes made to the ini take effect immediately. So it seems that php in Windows and IIS reloads the ini every time a page is requested? Charles Killmer -- Original Message -- From: Joe Webster [EMAIL PROTECTED] Date: Wed, 2 Jan 2002 15:46:32 -0500 no you need to restart apache to change an in setting. So it loads the settings once per server start (at least with apache). Charlesk [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Does PHP parse the ini file every time a file is requested? I am trying to track down a problem on various pages where the timelimit will expire. These are not complex pages and when I go to them they work fine. I have used the same browser that the user eses when the timeout occurs. Nothing strange for me. I have looked at the line that the error log specifies and it is just random lines. sometimes it is a '}'. As if the script just ran out of time on that line. BTW '}' is the closing of an if statement so it isnt stuck in a loop. And when I go to the page I make sure to use the same querystring that the user sent. Another thought, is the php engine slowed by users with a slow connection? Charles Killmer NetgainTechnology.com ++ | Steve Edberg [EMAIL PROTECTED] | | Database/Programming/SysAdmin(530)754-9127 | | University of California, Davis http://pgfsun.ucdavis.edu/ | +-- Gort, Klaatu barada nikto! --+ -- 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] Code not working in 4.1
I used to run PHP 4.0.3 and at the beginning of some functions that used a lot of global variables, I would add the following lines so I could access all the global variables inside the functions. foreach($GLOBALS as $GlobalVarName = $GlobalVarValue) { global $$GlobalVarName; } I upgraded to 4.1 and this code now causes PHP to die about 50-100 lines after it is executed. Any ideas? - Jonathan -- 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] Code not working in 4.1
use: extract($GLOBALS); http://www.php.net/manual/en/function.extract.php -Original Message- From: Jonathan Hilgeman [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 11:32 AM To: [EMAIL PROTECTED] Subject: [PHP] Code not working in 4.1 I used to run PHP 4.0.3 and at the beginning of some functions that used a lot of global variables, I would add the following lines so I could access all the global variables inside the functions. foreach($GLOBALS as $GlobalVarName = $GlobalVarValue) { global $$GlobalVarName; } I upgraded to 4.1 and this code now causes PHP to die about 50-100 lines after it is executed. Any ideas? - Jonathan -- 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 Problem
well thats just the way XML parsers work, according to the parser, what you have there is not a single string element, you have three child elements (the parent node being the title).. two string nodes broken up by an entity node. In other circumstances, this behaviour can be very useful. Matt. -Original Message- From: Ben Gollmer [mailto:[EMAIL PROTECTED]] Sent: 02 January 2002 23:16 To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: [PHP] XML Parsing Problem Ok, I can understand the predefined entity replacement. But why does it break the string up into 3 parts? I think it should just return Follow-up To Critique of BeOS amp; Mac OS X. Ben -- 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] Holy Moly...
Could someone please direct a total novice to the best PHP beginner news group. Just to many to choose from ~:) Thank You, Julie ~:) -- 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] Holy Moly...
This one's pretty good, IMO but as for the best - hmm... that would be a matter of personal opinion... :) -Original Message- From: Julie Hull [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 1:16 PM To: [EMAIL PROTECTED] Subject: [PHP] Holy Moly... Could someone please direct a total novice to the best PHP beginner news group. Just to many to choose from ~:) Thank You, Julie ~:) -- 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] Holy Moly...
If you dont mind downloading ~50 messages a day, then I'd recommend this group :] Regards Matt. - Original Message - From: Julie Hull [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 03, 2002 2:16 AM Subject: [PHP] Holy Moly... Could someone please direct a total novice to the best PHP beginner news group. Just to many to choose from ~:) Thank You, Julie ~:) -- 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] Mysql Curdate problem
Hi Andras, $aresult=mysql_query(select * from orders WHERE (a3 = CURDATE()-$datec) ,$db); what's the value of $datec? integer 7 or 14? if so then try to change it to this: interval 7 days -- Jimmy Love deeply and passionately. You might get hurt but it's the only way to live life completely. -- 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] Date aritmetic
Hello all, I would like to know if anyone could help me with the following issue: I have 6 variables, two holds a day, others the month and the last ones the year. They are entered through drop-down-menus where the user selects day, month and year for each date. I would like to know the difference in days between these two dates. Since the dates are separated and each value day, month and year are stored on separated variables I wonder who to proceed here. I need to know how many days of separate each dates. Thank you in advance, Carlos Fernando Salt Lake City, UT. Linux User #207984
Re: [PHP] Date aritmetic
Not mentioning that you could've taken a look at http://www.php.net/manual/en/ref.datetime.php yourself, here goes: $days_diff=(mktime(0,0,0,$month2,$day2,$year2)-mktime(0,0,0,$month2,$day2,$year2))/86400; Bogdan Carlos Fernando Scheidecker Antunes wrote: Hello all, I would like to know if anyone could help me with the following issue: I have 6 variables, two holds a day, others the month and the last ones the year. They are entered through drop-down-menus where the user selects day, month and year for each date. I would like to know the difference in days between these two dates. Since the dates are separated and each value day, month and year are stored on separated variables I wonder who to proceed here. I need to know how many days of separate each dates. Thank you in advance, Carlos Fernando Salt Lake City, UT. Linux User #207984 -- 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] Date aritmetic
Well, actually $days_diff=(mktime(0,0,0,$month2,$day2,$year2)-mktime(0,0,0,$month1,$day1,$year1))/86400; but you probably got that... :-) Bogdan -- 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] Date aritmetic
convert both in dates into a time stamp using mktime() subtract the two figures you get back then divide by 86400 (60sec/min * 60min/hr * 24hr/day) -Original Message- From: Carlos Fernando Scheidecker Antunes [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 12:57 PM To: PHP-GENERAL Subject: [PHP] Date aritmetic Importance: High Hello all, I would like to know if anyone could help me with the following issue: I have 6 variables, two holds a day, others the month and the last ones the year. They are entered through drop-down-menus where the user selects day, month and year for each date. I would like to know the difference in days between these two dates. Since the dates are separated and each value day, month and year are stored on separated variables I wonder who to proceed here. I need to know how many days of separate each dates. Thank you in advance, Carlos Fernando Salt Lake City, UT. Linux User #207984
RE: [PHP] Date aritmetic
This isn't to pick on Carlos, but I've notice there's heaps of ppl who don't read the manual, or do a search on the manual - I've found that many of my questions have been answered by doing a search on the docs -Original Message- From: Bogdan Stancescu [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 2:20 PM To: Carlos Fernando Scheidecker Antunes Cc: PHP-GENERAL Subject: Re: [PHP] Date aritmetic Not mentioning that you could've taken a look at http://www.php.net/manual/en/ref.datetime.php yourself, here goes: $days_diff=(mktime(0,0,0,$month2,$day2,$year2)-mktime(0,0,0,$month2,$day2,$y ear2))/86400; Bogdan Carlos Fernando Scheidecker Antunes wrote: Hello all, I would like to know if anyone could help me with the following issue: I have 6 variables, two holds a day, others the month and the last ones the year. They are entered through drop-down-menus where the user selects day, month and year for each date. I would like to know the difference in days between these two dates. Since the dates are separated and each value day, month and year are stored on separated variables I wonder who to proceed here. I need to know how many days of separate each dates. Thank you in advance, Carlos Fernando Salt Lake City, UT. Linux User #207984 -- 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] Can I config PHP RPM?
I'm a PHP newbie and have a few questions. 1) The server I'm working on has PHP 4.0.5 installed using an RPM. So there's no source code. How do I include extensions (say --enable java ) without getting the PHP source code and without make? 2) I think the server's Apache web server is also installed using an RPM. But the PHP is installed as a dynamic module. As far as I know, to install as a dynamic module, you'll have to use the ./configure command of Apache and re make and then make install Apache. But the Apache source code is not there. How is this possible? Thank you. _ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx -- 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] If Statement with more than one conclusion
How can I do an if statement with more than one conclusions Something like this I know this is not correct just an example of what I what to do If($ext==comornetororgorinfo){ Then do this } If($ext==com.ukorme.ukororg.uk){ Then do this } -- Best regards, rdkurth mailto:[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] If Statement with more than one conclusion
something like: If(in_array($ext, array(com, net, org, info)){ //Then do this } If(in_array($ext, com.uk, me.uk, org.uk)){ //Then do this } maybe?? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 4:22 PM To: php-general Subject: [PHP] If Statement with more than one conclusion How can I do an if statement with more than one conclusions Something like this I know this is not correct just an example of what I what to do If($ext==comornetororgorinfo){ Then do this } If($ext==com.ukorme.ukororg.uk){ Then do this } -- Best regards, rdkurth mailto:[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[2]: [PHP] If Statement with more than one conclusion
Hello Martin, Thanks that work perfect Wednesday, January 02, 2002, 9:31:36 PM, you wrote: MT something like: MT If(in_array($ext, array(com, net, org, info)){ MT //Then do this MT } MT If(in_array($ext, com.uk, me.uk, org.uk)){ MT //Then do this MT } MT maybe?? MT -Original Message- MT From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] MT Sent: Thursday, January 03, 2002 4:22 PM MT To: php-general MT Subject: [PHP] If Statement with more than one conclusion MT How can I do an if statement with more than one conclusions MT Something like this I know this is not correct just an example of what MT I what to do MT If($ext==comornetororgorinfo){ MT Then do this MT } MT If($ext==com.ukorme.ukororg.uk){ MT Then do this MT } -- Best regards, rdkurthmailto:[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]