Re: [PHP] Adding comma's to numeric string
number_format() At 14:16 10.1. 2001, Timothy G. Wells wrote the following: -- >Greetings, > >Any efficient ideas how to make any number readable by adding comma's? > >i.e. 300 ==> 3,000,000 > >Thanks, > >-- Tim Wells > > >-- > Timothy G. Wells, CEOGood News Internet Services > [EMAIL PROTECTED] http://www.goodnews.net > voice 513-662-4443 x 11 fax 513-662-8461 > > Everything You Need To Succeed On the Internet > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Shorter way for "each"
while( list( , $value ) = each( $my_array) ) or foreach( $my_array as $value ) At 16:16 10.1. 2001, Moritz Petersen wrote the following: -- >Hi, > >is there a shorter way to do: > >while (list($key, $value) = each($my_array)) >{ >echo $value... >} > >I just need the value! > >Thanks, >Mo. > >-- >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 of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] urlencode problem
rawurlencode() / rawurldecode() ^^^ ^^^ At 16:35 10.1. 2001, Zhihong Pan wrote the following: -- >I have tow files named as "a+b.doc" and "x y.doc". Before I pass them to another >page, I do urlencode first. But after I do urldecode in the next page, I got "a >b.doc" instead of "a+b.doc", but the second file is correct. Could anybody help me to >solve the problem ? > >Thanks, > >Zhihong Pan >Chek, Inc > > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] cgi--remove X-Powered-By and Content-type
I think you could also turn expose_php off in php.ini (if you use it) At 19:11 10.1. 2001, Philip Olson wrote the following: -- >Add a -q > >#!/usr/local/bin/php -q > >To suppress them. > > >Philip Olson >http://www.cornado.com/ > >On Wed, 10 Jan 2001, Tom Harris wrote: > >> I'm sure this is an easy question (I'm just too dumb to figure it out). >> >> When I run a php script from the shell it always outputs >> X-Powered-By: PHP/4.0.3pl1 >> Content-type: text/html >> >> Normally I just ignore this, but I've been using cron to run a php script >> and I'm getting my mailbox cluttered with messages that just contain the >> above 2 lines. Is there a way to make the cgi version of php not send those >> two lines. I tried changing default_mimetype ="" in the php.ini file but >> that didn't work. >> >> Thanks >> >> >> >> -- >> PHP General Mailing List (http://www.php.net/) >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> To contact the list administrators, e-mail: [EMAIL PROTECTED] >> > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] >To contact the list administrators, e-mail: [EMAIL PROTECTED] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] looking for a PHP editor
agreed, 4.5.2 still contains pretty old bugs. UltraEdit is bugfree (at least I haven't encountered any), has project management capabilities (but cannot make use of a version control system, AFAIK). At 18:59 10.1. 2001, Boget, Chris wrote the following: -- >> > >Personally, my team and I use HomeSite 4.5.x from Allaire. >> > You did not mention the price (compared to HoTMetaL at $70). >> my two cents on price. who cares! if an editor makes one >> happy then pay as much as it takes to get it. consider how many >> hours are spent with the editor. 18 hours a day? in the end, what's >> $20? $200? homesite is about $90. >> oh btw, i use homesite and vim , and vim is free! :) > >Plus, Homesite has project management and can interface >with source control applications (we use VSS) whereas I >believe HoTMetaL does not. I don't particularly like Homesite >(there are many things I despise about it, as a matter of fact), >but it's the only one that I know of (on a windows OS) that has >these features. If there were another, I think I'd probably switch >in a heartbeat. > >Chris --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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 question
since when is false equal to one? in PHP, false is represented by string(0) "", and true by 1. so, you really want At 19:33 10.1. 2001, Neil Zanella wrote the following: -- >On Wed, 10 Jan 2001, Toby Butzon wrote: > >> : >> >> $a evaluates to false, the ! reverses it, and it prints "Hello, World!" > >What is bothering me is the following: if variables that are not assigned >a value were to evaluate to false then since false is the same as the >number 1 the following PHP script should print the number 1 but instead >prints nothing: > > > >How is this behavior justified? >I could not find anything on this in the PHP manual. > >Thanks, > >-- Neil > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] looking for a PHP editor
you can surely use CVS or VSS or RCS or something like that. the point here is whether you can use such a system from an editor seamlessly, which you can't in the case of UltraEdit, but can with HomeSite. At 19:32 10.1. 2001, Miles Thompson wrote the following: -- >Cynic, > >I've never used version control -- other than saving as draft1, draft2, draft3 -- and >there have been days I've wanted draft2.5. Is this something integral to the editor, >or would a tool like CVS work? > >Versioning would be *good*. > >Miles > >At 07:26 PM 01/10/2001 +0100, Cynic wrote: >>agreed, 4.5.2 still contains pretty old bugs. >>UltraEdit is bugfree (at least I haven't encountered any), has >>project management capabilities (but cannot make use of a >>version control system, AFAIK). >> >>At 18:59 10.1. 2001, Boget, Chris wrote the following: >>-- >>>> > >Personally, my team and I use HomeSite 4.5.x from Allaire. >>>> > You did not mention the price (compared to HoTMetaL at $70). >>>> my two cents on price. who cares! if an editor makes one >>>> happy then pay as much as it takes to get it. consider how many >>>> hours are spent with the editor. 18 hours a day? in the end, what's >>>> $20? $200? homesite is about $90. >>>> oh btw, i use homesite and vim , and vim is free! :) >>> >>>Plus, Homesite has project management and can interface >>>with source control applications (we use VSS) whereas I >>>believe HoTMetaL does not. I don't particularly like Homesite >>>(there are many things I despise about it, as a matter of fact), >>>but it's the only one that I know of (on a windows OS) that has >>>these features. If there were another, I think I'd probably switch >>>in a heartbeat. >>> >>>Chris >>--end of quote-- >> >> >> >> >>Cynic: >> >>A member of a group of ancient Greek philosophers who taught >>that virtue constitutes happiness and that self control is >>the essential part of virtue. >> >>[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] > > > --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] looking for a PHP editor
I mailed the author of UltraEdit, and he responded within 10 minutes, so I'm forwarding the reply. It turns out you _can_ actually make use of a version control system from within UE: >There is a link on our Products page to Component Software's >RCS version control software - http://www.idmcomp.com/products/ >. You can read about integrating this with UltraEdit-32 at >http://www.componentsoftware.com/csrcs/addons/ue32.htm . >Also, although we don't use Visual SourceSafe ourselves, one >user told us he was able to integrate VSS with UltraEdit-32 by >configuring the following tools: > >Visual SoureSafe >1. Advanced - Tool Configuration >>From Tool Configuration >Command Line: ss.exe checkout %n%e -GWR >Working Directory: [E]:\PROGRAM FILES\MICROSOFT VISUAL >STUDIO\COMMON\VSS\WIN32\ >Command Output [Replace Existing] >Same for checking in the file, except change checkout to checkin! >You can then add these tools to the toolbar. At 19:38 10.1. 2001, Philip Olson wrote the following: -- >Agreed on the annoying homesite bugs, like with FTP. UltraEdit is nice >too, haven't spent enough time with it. > >Now only if a php-tidy existed ... > >Philip > >On Wed, 10 Jan 2001, Cynic wrote: > >> agreed, 4.5.2 still contains pretty old bugs. >> UltraEdit is bugfree (at least I haven't encountered any), has >> project management capabilities (but cannot make use of a >> version control system, AFAIK). >> >> At 18:59 10.1. 2001, Boget, Chris wrote the following: >> -- >> >> > >Personally, my team and I use HomeSite 4.5.x from Allaire. >> >> > You did not mention the price (compared to HoTMetaL at $70). >> >> my two cents on price. who cares! if an editor makes one >> >> happy then pay as much as it takes to get it. consider how many >> >> hours are spent with the editor. 18 hours a day? in the end, what's >> >> $20? $200? homesite is about $90. >> >> oh btw, i use homesite and vim , and vim is free! :) >> > >> >Plus, Homesite has project management and can interface >> >with source control applications (we use VSS) whereas I >> >believe HoTMetaL does not. I don't particularly like Homesite >> >(there are many things I despise about it, as a matter of fact), >> >but it's the only one that I know of (on a windows OS) that has >> >these features. If there were another, I think I'd probably switch >> >in a heartbeat. >> > >> >Chris >> --end of quote-- >> >> >> >> >> Cynic: >> >> A member of a group of ancient Greek philosophers who taught >> that virtue constitutes happiness and that self control is >> the essential part of virtue. >> >> [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] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] knowing file's mime-type
besides, a file type can be defined in httpd.conf, not in mime.types At 19:48 10.1. 2001, Nikolai Vladychevski wrote the following: -- >Chris Lee wrote: >> >> use exec() and unix's command 'file' >> >> exec("file $filename"); >> >> and admire the output :) > >I know, but "file" does not gives it based on /etc/mime.types, it even >has nothing to do with apache. > > >Nikolai > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] knowing file's mime-type
err, how about apache_lookup_uri()? http://docs.wad.cz/php/function.apache-lookup-uri.html At 20:01 10.1. 2001, Nikolai Vladychevski , Chris Lee <[EMAIL PROTECTED]> wrote the following: -- >besides, a file type can be defined in httpd.conf, not in >mime.types > >At 19:48 10.1. 2001, Nikolai Vladychevski wrote the following: >-- >>Chris Lee wrote: >>> >>> use exec() and unix's command 'file' >>> >>> exec("file $filename"); >>> >>> and admire the output :) >> >>I know, but "file" does not gives it based on /etc/mime.types, it even >>has nothing to do with apache. >> >> >>Nikolai >> >>-- >>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 of quote-- > > > >Cynic: > >A member of a group of ancient Greek philosophers who taught >that virtue constitutes happiness and that self control is >the essential part of virtue. > >[EMAIL PROTECTED] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Netscape does not show all the variables
you won't find out anything useful this way. I'm Czech (central Europe), and have en-us at the first position in the list of preferred languages. At 15:53 11.1. 2001, Sam wrote the following: -- >Hi all, > >when I use IE, and do a phpinfo() > >The variable >HTTP_ACCEPT_LANGUAGE displays en-gb (for english GB) > >But Netscape only displays en... > >The problem is, is that I want to know where visitors to my site are coming >from i.e. UK, US, Australia, so that I can do a bit of php so that the >relevant information is produced. > >Is there anyway to do this, using php? > >Thanks > >Sam Rose > > > > > >The information in this email and in any attachments is confidential and may >be privileged. If you are not the intended recipient, please destroy this >message, delete any copies held on your systems and notify the sender >immediately. You should not retain, copy or use this email for any purpose, >nor disclose all or any part of its content to any other person. > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Netscape does not show all the variables
The HTTP_ACCEPT_LANGUAGE has nothing to do with location. Is it called HTTP_USER_POSITION? No. It's a code of the _language_ (well, actually, list of codes of languages, along with their preference weights (if that's the right word) that a user can set to _anything_ in their browser. Example: en-us,en-gb;q=0.7,cs;q=0.3 header sent along with a request for http://www.somewhere.tld/index.html means I want the document in US English or UK English, and when it's not available, in Czech. If none of these is available, I will get it in whatever language it's available in. And, of course, the server must be set up to grok this kind of negotiation. At 16:45 11.1. 2001, Sam wrote the following: -- >Yeah, but there are three locations that I have which are UK, US and >Australia. Each of them have different en-??. Well on IE anyway. > >So I'm not sure which way to go about this. > >-Original Message- >From: Cynic [mailto:[EMAIL PROTECTED]] >Sent: Thursday, January 11, 2001 3:12 PM >To: Sam; '[EMAIL PROTECTED]' >Subject: Re: [PHP] Netscape does not show all the variables > > >you won't find out anything useful this way. I'm Czech (central >Europe), and have en-us at the first position in the list of >preferred languages. > >At 15:53 11.1. 2001, Sam wrote the following: >-- >>Hi all, >> >>when I use IE, and do a phpinfo() >> >>The variable >>HTTP_ACCEPT_LANGUAGE displays en-gb (for english GB) >> >>But Netscape only displays en... >> >>The problem is, is that I want to know where visitors to my site are coming >>from i.e. UK, US, Australia, so that I can do a bit of php so that the >>relevant information is produced. >> >>Is there anyway to do this, using php? >> >>Thanks >> >>Sam Rose >> >> >>___ >_ >> >> >>The information in this email and in any attachments is confidential and >may >>be privileged. If you are not the intended recipient, please destroy this >>message, delete any copies held on your systems and notify the sender >>immediately. You should not retain, copy or use this email for any purpose, >>nor disclose all or any part of its content to any other person. >> >> >>-- >>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 of quote-- > > > >____ >Cynic: > >A member of a group of ancient Greek philosophers who taught >that virtue constitutes happiness and that self control is >the essential part of virtue. > >[EMAIL PROTECTED] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Running java under php4 (PHP4 ext/java)
PHP so far AFAIK has problems with JVM. A wouldn't recommend playing with it yet unless you like pulling your hair out. At 16:29 11.1. 2001, Fraser MacKenzie wrote the following: -- >I can get you past this part, but I cannot get you past the: > >unable to instantiate non-existant class: java > >error. It is driving me bloody nuts. I have tried 3..count em...3 >different JDKs now. It has taken up way more of my time than I would have >liked... > >Fraser > >On Thu, 11 Jan 2001, Eduard Witteveen wrote: > >> Hello, >> >> I was wondering if somebody could give me some links to information >> about running java. >> >> I cant get a instance of a class, and i don't know what im doing wrong.. >> the message that i get is 'Unable to locate CreateJavaVM function', So i >> suspect that php cant find java. How do i debug 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] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Extending PHP
You will probably get answers in php-dev rather than in php-general. At 21:58 11.1. 2001, Jason Lee wrote the following: -- >I'd like to write a module for PHP so that we can, from our PHP scripts, talk to our >servers using our home grown communication library. My concern is that documentation >says to use emalloc(), estrdup(), and efree(). Our code uses the STL quite heavily. >Beyond getting past the C++ to C linker issues (extern "C" { ), will the STL cause >memory problems? Is this the right forum for this kind of question? Thanks! > >-- >Jason Lee| Get her boy and let yourself surrender. Run alone with >Programmer/Analyst | her and never fall. She is wisdom and the most >www.rri-medtech.com | praiseworthy trait of all. > > >-- >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 of quote------ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Making PHP Hold the hundreth place, instead of dropping the 0
number_format() At 16:09 11.1. 2001, JB wrote the following: -- >Hey, > >Simple question. Breifly rumaged through the PHP docs and couldn't find this answer. > >How do i force PHP to hold ending zero in a double? > >Ie- if the price is 15.50, php will output it as 15.5 after it does the math. how do >i overcome this. thanks! > >jason --end of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Question
you'll have to compute the sum of filesizes of all the files in their directory. At least on NT, filesize on directory returns 0. At 12:08 12.1. 2001, Gareth Davies wrote the following: -- >Hi all, > >Is there a way in PHP to get the size of a directory? (so I can see how much disk >space my users are using in their home directory). > >Can someone also tell me what the PHP General list is exactly. Is it run by PHP folk >only? Can I subscribe to this list somewhere and maybe help someone else out for a >change? > >Thanks, >Gareth Davies >Progressive Business Services Ltd > >+44 (0) 1274 889592 Office >+44 (0) 1274 889656 Fax >+44 (0) 7970 733851 Mobile (24 Hour) --end of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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: Special Characters
IIRC the conversion rules are locale specific. use setlocale() to set appropriate environment. At 13:01 12.1. 2001, TV Karthick Kumar wrote the following: -- >Hi all, > >I have a problem while converting the string into upper case by using >the strtoupper function. > >I want to convert the string which has some special characters in it. >For example, med vänlig hälsning, António etc. There are lots of strings / >words with some special characters in it. It cannot be listed. > >As I want to convert them into upper case, I tried. >strtoupper(hälsning), it's just converting it as: HäLSNING and then writes >onto the database. But I want that special character - ' ä ' also to be >converted into upper case and then onto the database. How do I get rid of >this problem and convert into upper case ?. > >PLS. HELP ME. > >Thanks in advance. > >~ Karthick > > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Question
you probably meant $totalfilesize += filesize($files); ^ At 13:17 12.1. 2001, Johan Holst Nielsen wrote the following: -- >>Is there a way in PHP to get the size of a directory? (so I can see how much disk >space my >users are using in their home directory). > >>Can someone also tell me what the PHP General list is exactly. Is it run by PHP folk >only? Can >I subscribe to this list somewhere and maybe help someone else out for a >change? > >Yes! Try to see this, it isn't tested, just maked out of memory! > >$totalfilesize = 0; >$dir=opendir('.'); >while (($files = readdir($dir))!==false) { >$totalfilesize .= filesize($files); >} >closedir($dir); >print($totalfilesize." bytes"); >?> > > > > > > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] odbc_* <-> MyODBC <-> MySQL
Just curious. I tried accessing MySQL through ODBC using a system DSN (MyODBC driver ver. myodbc-2.50.36-nt.zip) and a script as simple as this one crashes Apache at the odbc_fetch_row() call. I actually don't know much about ODBC related stuff inside PHP... or generally, for that matter, so I don't know whether this is unsupported, or whether a more stable state is possible / desirable. $conn = odbc_connect( $dsn , $usr , $pwd ); $res = odbc_tables( $conn ) ; while( $r = odbc_fetch_row( $res ) ) { for( $i = 0 ; $i < count( $r ) ; $i++ ) { echo $r[ $i ] , '|' ; } echo "\n" ; } ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] regex
yes At 23:54 12.1. 2001, Jerry Lake wrote the following: -- >is it possible with regex to >change one or more text characters >followed by a space into the same >characters followed by a tab? > >Jerry Lake > > >-- >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 of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] regex
depends. is the set of strings preceeding the space limited and known, or is it something like [^abc]{3,12} ? At 00:13 13.1. 2001, Jerry Lake wrote the following: -- >and how would I go about that? > >Jerry Lake > >-Original Message----- >From: Cynic [mailto:[EMAIL PROTECTED]] >Sent: Friday, January 12, 2001 3:10 PM >To: Jerry Lake; [EMAIL PROTECTED] >Subject: Re: [PHP] regex > > >yes > >At 23:54 12.1. 2001, Jerry Lake wrote the following: >-- >>is it possible with regex to >>change one or more text characters >>followed by a space into the same >>characters followed by a tab? >> >>Jerry Lake >> >> >>-- >>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 of quote-- > > > > >Cynic: > >A member of a group of ancient Greek philosophers who taught >that virtue constitutes happiness and that self control is >the essential part of virtue. > >[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] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Script execution Speed
depends on the underlying FS - you might find yourself bitten by disk hits that could've been avoided... How about writing a small test suite and benching the server? At 00:29 13.1. 2001, Randy Johnson wrote the following: -- >Is it faster and more efficient to have smaller scripts that only do one >specific thing when it is executed or can I have a script perform to >different tasks based on a variable sent to it? It will be a high user >website so I am thinking that the smaller the script the better? Am I >right? > >Randy > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] >To contact the list administrators, e-mail: [EMAIL PROTECTED] --end of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] regex
looks like you need to find all the spaces _before_ the _first_ digit on the row, and _after_ the _last_ digit on the row. does that fit your data? are there no other numbers than the telephone ones? At 00:29 13.1. 2001, Jerry Lake wrote the following: -- >I have a small phone directory >bust the name listings are combined >for example >Schwartz Bob & Amelia 555-1212Oxford >Scirkin Bill555-1213Brooks > >I need to add a tab or a comma after the >lastname so I can have as a separate field >when I dump it into MySQL and there is about >3500 records and I'd hate to have to do it by hand >any ideas? > >Jerry Lake- [EMAIL PROTECTED] > >-Original Message- >From: Cynic [mailto:[EMAIL PROTECTED]] >Sent: Friday, January 12, 2001 3:25 PM >To: Jerry Lake; [EMAIL PROTECTED] >Subject: RE: [PHP] regex > > >depends. is the set of strings preceeding the space limited >and known, or is it something like [^abc]{3,12} ? > > >At 00:13 13.1. 2001, Jerry Lake wrote the following: >-- >>and how would I go about that? >> >>Jerry Lake >> >>-Original Message- >>From: Cynic [mailto:[EMAIL PROTECTED]] >>Sent: Friday, January 12, 2001 3:10 PM >>To: Jerry Lake; [EMAIL PROTECTED] >>Subject: Re: [PHP] regex >> >> >>yes >> >>At 23:54 12.1. 2001, Jerry Lake wrote the following: >>-- >>>is it possible with regex to >>>change one or more text characters >>>followed by a space into the same >>>characters followed by a tab? >>> >>>Jerry Lake >>> >>> >>>-- >>>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 of quote-- >> >> >> >> >>Cynic: >> >>A member of a group of ancient Greek philosophers who taught >>that virtue constitutes happiness and that self control is >>the essential part of virtue. >> >>[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] >--end of quote-- > > > > >Cynic: > >A member of a group of ancient Greek philosophers who taught >that virtue constitutes happiness and that self control is >the essential part of virtue. > >[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] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Simple form not passing variables, Why??
you have register_globals off in your php.ini or httpd.conf or .htaccess. either use $HTTP_GET_VARS['name'] or turn the setting on. At 00:36 13.1. 2001, jeff fitzmyers wrote the following: -- >The code below does not work. What could be causing >this?? php pages do come up, and I can retrieve SQL >data. The header seems okay: test.php?name=Bob and if >I define a variable on the same page I can use it. > >Please enter user name here: > > > > > >you typed: > echo ($name); >?> > >Linux 2.2.14 >PHP/4.0.3pl1 >'./configure' '--without-gd' '--with-apxs' >'--with-mysql=/usr' '--with-pgsql' '--with-imap' > >Ideas?? > >__ >Do You Yahoo!? >Yahoo! Photos - Share your holiday photos online! >http://photos.yahoo.com/ > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] >To contact the list administrators, e-mail: [EMAIL PROTECTED] --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] regex
try this: $s = file( 'mylisting.txt' ); $r = "\\1\t\\2\t\\3" ; $p = '~^(.*)\040+(?=\d)(\d+-\d+)(?<=\d)\040+(.*)$~Ui' ; you might want to limit the possible appearance of the phone numbers more strictly. At 00:44 13.1. 2001, Jerry Lake wrote the following: -- >Bolgrihn Michael555-5566142 Hillyer St Oxford >Bollenbach Gary V 555-5078315 Freedom Rd Oxford >Bonaguidi Daniel555-5155N4663 10th Av Montello >Bonnett Agatha & John 555-5363547 Fawn Ct Oxford >Bonnett Bernard & Norma 555-4360116 E Ormsby St Oxford >Bonnett Bob & Eleanor 555-5627527 Fern Av Oxford > >Here is a sample from the listing there are numbers in the address >as well. >$NewString = ereg_replace("([[:alpha:]]+) ", "\\1".",", $test); >that works to an extent, except that it adds the comma after >every word that is followed by one space and not just the first occurance > >Jerry Lake > >-Original Message- >From: Cynic [mailto:[EMAIL PROTECTED]] >Sent: Friday, January 12, 2001 3:41 PM >To: Jerry Lake; [EMAIL PROTECTED] >Subject: RE: [PHP] regex > > >looks like you need to find all the spaces _before_ the _first_ >digit on the row, and _after_ the _last_ digit on the row. >does that fit your data? are there no other numbers than the >telephone ones? > >At 00:29 13.1. 2001, Jerry Lake wrote the following: >-- >>I have a small phone directory >>bust the name listings are combined >>for example >>Schwartz Bob & Amelia 555-1212Oxford >>Scirkin Bill555-1213Brooks >> >>I need to add a tab or a comma after the >>lastname so I can have as a separate field >>when I dump it into MySQL and there is about >>3500 records and I'd hate to have to do it by hand >>any ideas? >> >>Jerry Lake- [EMAIL PROTECTED] >> >>-Original Message- >>From: Cynic [mailto:[EMAIL PROTECTED]] >>Sent: Friday, January 12, 2001 3:25 PM >>To: Jerry Lake; [EMAIL PROTECTED] >>Subject: RE: [PHP] regex >> >> >>depends. is the set of strings preceeding the space limited >>and known, or is it something like [^abc]{3,12} ? >> >> >>At 00:13 13.1. 2001, Jerry Lake wrote the following: >>-- >>>and how would I go about that? >>> >>>Jerry Lake >>> >>>-Original Message- >>>From: Cynic [mailto:[EMAIL PROTECTED]] >>>Sent: Friday, January 12, 2001 3:10 PM >>>To: Jerry Lake; [EMAIL PROTECTED] >>>Subject: Re: [PHP] regex >>> >>> >>>yes >>> >>>At 23:54 12.1. 2001, Jerry Lake wrote the following: >>>-- >>>>is it possible with regex to >>>>change one or more text characters >>>>followed by a space into the same >>>>characters followed by a tab? >>>> >>>>Jerry Lake >>>> >>>> >>>>-- >>>>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 of quote-- >>> >>> >>> >>> >>>Cynic: >>> >>>A member of a group of ancient Greek philosophers who taught >>>that virtue constitutes happiness and that self control is >>>the essential part of virtue. >>> >>>[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] >>--end of quote------ >> >> >> >> >>Cynic: >> >>A member of a group of ancient Greek philosophers who taught >>that virtue constitutes happiness and that self control is >>the essential part of virtue. >> >>[EMAIL PROTECTED] >> >> >> >>-- >>PHP General Mailing List (http://w
RE: [PHP] regex
Oh, of course: $result = preg_replace( $p , $r , $s ) ; But you have probably already figured that. At 01:28 13.1. 2001, Cynic wrote the following: -- >try this: > >$s = file( 'mylisting.txt' ); >$r = "\\1\t\\2\t\\3" ; >$p = '~^(.*)\040+(?=\d)(\d+-\d+)(?<=\d)\040+(.*)$~Ui' ; > >you might want to limit the possible appearance of the phone >numbers more strictly. > >At 00:44 13.1. 2001, Jerry Lake wrote the following: >-- >>Bolgrihn Michael555-5566142 Hillyer St Oxford >>Bollenbach Gary V 555-5078315 Freedom Rd Oxford >>Bonaguidi Daniel555-5155N4663 10th Av Montello >>Bonnett Agatha & John 555-5363547 Fawn Ct Oxford >>Bonnett Bernard & Norma 555-4360116 E Ormsby St Oxford >>Bonnett Bob & Eleanor 555-5627527 Fern Av Oxford >> >>Here is a sample from the listing there are numbers in the address >>as well. >>$NewString = ereg_replace("([[:alpha:]]+) ", "\\1".",", $test); >>that works to an extent, except that it adds the comma after >>every word that is followed by one space and not just the first occurance >> >>Jerry Lake >> >>-Original Message- >>From: Cynic [mailto:[EMAIL PROTECTED]] >>Sent: Friday, January 12, 2001 3:41 PM >>To: Jerry Lake; [EMAIL PROTECTED] >>Subject: RE: [PHP] regex >> >> >>looks like you need to find all the spaces _before_ the _first_ >>digit on the row, and _after_ the _last_ digit on the row. >>does that fit your data? are there no other numbers than the >>telephone ones? >> >>At 00:29 13.1. 2001, Jerry Lake wrote the following: >>-- >>>I have a small phone directory >>>bust the name listings are combined >>>for example >>>Schwartz Bob & Amelia 555-1212Oxford >>>Scirkin Bill 555-1213Brooks >>> >>>I need to add a tab or a comma after the >>>lastname so I can have as a separate field >>>when I dump it into MySQL and there is about >>>3500 records and I'd hate to have to do it by hand >>>any ideas? >>> >>>Jerry Lake- [EMAIL PROTECTED] >>> >>>-Original Message- >>>From: Cynic [mailto:[EMAIL PROTECTED]] >>>Sent: Friday, January 12, 2001 3:25 PM >>>To: Jerry Lake; [EMAIL PROTECTED] >>>Subject: RE: [PHP] regex >>> >>> >>>depends. is the set of strings preceeding the space limited >>>and known, or is it something like [^abc]{3,12} ? >>> >>> >>>At 00:13 13.1. 2001, Jerry Lake wrote the following: >>>-- >>>>and how would I go about that? >>>> >>>>Jerry Lake >>>> >>>>-Original Message- >>>>From: Cynic [mailto:[EMAIL PROTECTED]] >>>>Sent: Friday, January 12, 2001 3:10 PM >>>>To: Jerry Lake; [EMAIL PROTECTED] >>>>Subject: Re: [PHP] regex >>>> >>>> >>>>yes >>>> >>>>At 23:54 12.1. 2001, Jerry Lake wrote the following: >>>>-- >>>>>is it possible with regex to >>>>>change one or more text characters >>>>>followed by a space into the same >>>>>characters followed by a tab? >>>>> >>>>>Jerry Lake >>>>> >>>>> >>>>>-- >>>>>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 of quote-- >>>> >>>> >>>> >>>> >>>>Cynic: >>>> >>>>A member of a group of ancient Greek philosophers who taught >>>>that virtue constitutes happiness and that self control is >>>>the essential part of virtue. >>>> >>>>[EMAIL PROTECTED] >>>> >>>> >>>> >>>> >>>>-- >>>>PHP General Mailing List (http://www.php.net/) >>>>To unsubs
[PHP] backdoor in InterBase
* Borland Interbase Server Contains Backdoor Account http://www.windowsitsecurity.com/articles/index.cfm?articleID=16566 fixes for Windows, Linux, Solaris, HP-UX and SCO available at http://www.borland.com/interbase/downloads/patches.html Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Guru Needed - the parser is corrupting my html!!
this is a bug in PHP (several reports in bug db). either ask your ISP to disable trans-sid in your virtual host, or do it yourself in .htaccess At 15:52 13.1. 2001, Jamie Burns wrote the following: -- >hey guys... > >my dumb isp has turned on ' --enable-trans-sid ' for all of the users on their >webserver without telling them. > >while i am sure this feature has some benefits, it is breaking my code, big time. >besides sticking the session value onto the end of every suspected server request, it >is corrupting my javascript code in strange ways! Look at these examples... > > > >SPOT THE DIFFERENCE! > >ORIGINAL CODE: > > function MM_swapImgRestore() { //v3.0 > var i,x,a=document.MM_sr; for(i=0;a&&ix.src=x.oSrc; > } > > var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); > >CORRUPTED CODE: > > function MM_swapImgRestore() { //v3.0 > var i,x,a=document.MM_sr; for(i=0;a&&ix.src="x.oSrc;" > } > > var d="document;" if(d.images){ if(!d.MM_p) d.MM_p="new" Array(); > > > >see those speech marks around: > >)" x.src="x.oSrc;" and d="document;" > >they (and many more elsewhere in my code) are corrupting my javascript?!?!?!?! > >please help, this is a live system and my isp has forced my into an emergency >situation. > >can i turn off transparent sid's through a run time or configuration file (i cannot >recompile) ? > >anyone know how to stop this corruption? > >if it helps, i use the include() function to get and output the html template from my >code. > >jamie burns. --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Guru Needed - the parser is corrupting my html!!
php_flag session.use_trans_sid 0 At 16:08 13.1. 2001, Jamie Burns wrote the following: -- >thanks! > >what do i need to put in my apache config? > >j > >- Original Message - >From: "Cynic" <[EMAIL PROTECTED]> >To: "Jamie Burns" <[EMAIL PROTECTED]>; ><[EMAIL PROTECTED]> >Sent: Saturday, January 13, 2001 3:06 PM >Subject: Re: [PHP] Guru Needed - the parser is corrupting my html!! > > >> this is a bug in PHP (several reports in bug db). either ask >> your ISP to disable trans-sid in your virtual host, or do it >> yourself in .htaccess >> >> >> At 15:52 13.1. 2001, Jamie Burns wrote the following: >> -- >> >hey guys... >> > >> >my dumb isp has turned on ' --enable-trans-sid ' for all of the users on >their webserver without telling them. >> > >> >while i am sure this feature has some benefits, it is breaking my code, >big time. besides sticking the session value onto the end of every suspected >server request, it is corrupting my javascript code in strange ways! Look at >these examples... >> > >> > >> > >> >SPOT THE DIFFERENCE! >> > >> >ORIGINAL CODE: >> > >> > function MM_swapImgRestore() { file://v3.0 >> > var i,x,a=document.MM_sr; for(i=0;a&&ix.src=x.oSrc; >> > } >> > >> > var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); >> > >> >CORRUPTED CODE: >> > >> > function MM_swapImgRestore() { file://v3.0 >> > var i,x,a=document.MM_sr; >for(i=0;a&&i> > } >> > >> > var d="document;" if(d.images){ if(!d.MM_p) d.MM_p="new" Array(); >> > >> > >> > >> >see those speech marks around: >> > >> >)" x.src="x.oSrc;" and d="document;" >> > >> >they (and many more elsewhere in my code) are corrupting my >javascript?!?!?!?! >> > >> >please help, this is a live system and my isp has forced my into an >emergency situation. >> > >> >can i turn off transparent sid's through a run time or configuration file >(i cannot recompile) ? >> > >> >anyone know how to stop this corruption? >> > >> >if it helps, i use the include() function to get and output the html >template from my code. >> > >> >jamie burns. >> --end of quote-- >> >> >> >> >> Cynic: >> >> A member of a group of ancient Greek philosophers who taught >> that virtue constitutes happiness and that self control is >> the essential part of virtue. >> >> [EMAIL PROTECTED] >> --end of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] problem building php_gd.dll
I'v run into a wall when trying to build php_gd.dll. I have built gd.lib (gd-1.8.3) with PNG support (libpng-1.0.8): % nmake gd.lib /f makefile.nt and except two warnings, all seemed well: gd_io.c(145) : warning C4028: formal parameter 2 different from declaration gdkanji.c(385) : warning C4033: 'do_convert' must return a value now I entered MSDEV, loaded php_modules.dsw, added the gd directory to lib and include paths, and built php_gd.dll. This resulted in two errors: (...)\ext\gd\gd.c(729) : error C2065: 'gdImageCreateFromPng' : undeclared identifier (...)\ext\gd\gd.c(875) : error C2065: 'gdImagePng' : undeclared identifier I'm stuck. ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] rewriting the browser's url
1) use POST method, not GET 2) don't output anything from the script that recieves the POST data, instead, redirect to another page. pseudocode follows: if( post ) { query the database ; header( 'Location: result.php' ) ; } html form At 03:23 14.1. 2001, Jared Howard wrote the following: -- >I need to know how to be able to eliminate the querysting portion of the >URL that is displayed on the users browser. I don't want it possible to >click refresh and reenter in the same querystring that was used previously >(eg. php runs a mysql query of INSERT based on the querystring which only >should be run once no matter how many times they click refresh). > > >-- >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 of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] Escape characters
mail( 'email@address' , 'subject' , stripslashes( $body ) ) ; At 04:22 14.1. 2001, Jeremy Bowen wrote the following: -- >Hey All, > >I am sending e-mail using the mail() command. My question is whenever >an ' is used in the e-mail it is escaped like this: don\'t. Is there any way to >prevent this?? > >Thanks, > >Jeremy > >-- >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 of quote-- Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] GD Library ??? Where to find.
www.boutell.com/gd/ IIRC At 18:26 15.1. 2001, Dallas Kropka wrote the following: -- >Please point me to the GD library I cant seem to find 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] --end of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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] simple division.. but how?
look at the math functions. also, number_format() might be your friend. At 19:53 15.1. 2001, [EMAIL PROTECTED] wrote the following: -- >if you want to do >10 / 3 >i want it to show 3 and not 3.3 > >how do I control that? > > >- Thanks > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] >To contact the list administrators, e-mail: [EMAIL PROTECTED] --end of quote-- ____ Cynic: A member of a group of ancient Greek philosophers who taught that virtue constitutes happiness and that self control is the essential part of virtue. [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]