Re: [PHP] Fork and multi-thread in PHP?

2002-06-12 Thread Rasmus Lerdorf
That's one of the main reasons you would want to use the mail() function. I wouldn't advise a fork() here, but if you really insist, see the pcntl extension - http://php.net/pcntl -Rasmus On Wed, 12 Jun 2002, Nathan Cassano wrote: Hi PHP folks, I have a program that sends out email

RE: [PHP] GOTO command. Doest it exist?

2002-06-11 Thread Rasmus Lerdorf
this situation. -Rasmus On Wed, 12 Jun 2002, Martin Towell wrote: I've found that any language that supports while, do/while, for and if/else as well as functions/subroutines doesn't need goto. IMO, you should be able to do code using just those basic elements (sequence, loops, conditions - basic

Re: [PHP] preg

2002-06-11 Thread Rasmus Lerdorf
Sounds like a weird thing to want to do, but this will do it: preg_replace('/(\w)\1$/','2',$str) -Rasmus On Wed, 12 Jun 2002, Zac Hillier wrote: Does anyone know how I can use preg or any other function to identify a double letter on the end of a string and then replace it. So 'foo

Re: [PHP] RE: Time to Divide Lists? WAS: [PHP] MySQL - Creating TheDatabase

2002-06-04 Thread Rasmus Lerdorf
out and ask there. So nothing would have been gained. But yes, we could add something to the footer. -Rasmus On Tue, 4 Jun 2002, Jay Blanchard wrote: Quite frequently on this list and others there are questions where it is obvious that the manual or list archives have not been searched. Heck

Re: [PHP] Determine overhead of PHP script.

2002-06-02 Thread Rasmus Lerdorf
in bytes. -Rasmus On Mon, 3 Jun 2002, Analysis Solutions wrote: JH: On Sat, Jun 01, 2002 at 10:29:38PM -0400, John Holmes wrote: Is there a way to determine the overhead or memory usage of a PHP script as it runs? You could do some sort of exec() or system() type call. For example

Re: [PHP] Possible to convert from Hex string to integer?

2002-06-01 Thread Rasmus Lerdorf
Did you check the manual? http://php.net/hexdec On Sat, 1 Jun 2002, Michael Davey wrote: Does anyone know of a function within PHP that will convert a hexadecimal string (without the leading 0x) into an integer? regards, Mikey -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Working with ip addresses and address space

2002-05-31 Thread Rasmus Lerdorf
ip2long and long2ip and a bit of bitwise logic is really all you need. -Rasmus On Fri, 31 May 2002, Chris Knipe wrote: Hi all, anyone know of any good pre-written classes or functions to work with IP address space? I'm looking for things which can verify correct notation of IP addresses

Re: [PHP] Speed comparison of PHP vs. PERL (not conclusive)

2002-05-31 Thread Rasmus Lerdorf
Not very surprising. Perl's looping code has always ben faster than PHP's. Highly iterative loops is really not what PHP is geared for. You are not going to write a Mandelbrot algorithm in PHP. You write it in C and drop in a super-quick extension into PHP and call mandelbrot(). -Rasmus

Re: [PHP] Speed comparison of PHP vs. PERL (not conclusive)

2002-05-31 Thread Rasmus Lerdorf
are going to loop a couple of hundred thousand times to do something. -Rasmus On Fri, 31 May 2002, Ilia A. wrote: Does this mean that running a comparison benchmarks between PHP and any other language would in many cases show PHP to be slower simply because it's looping code is slow? Unless

Re: [PHP] Finding what headers and content were already been sent

2002-05-31 Thread Rasmus Lerdorf
to ultimately send. By the way, I know that PHP's phpinfo() function lists headers received and headers sent, but I couldn't find how can I access them in PHP. In addition, how do I know what content has been sent at any point in a script? $HTTP_* has them all. -Rasmus -- PHP General

RE: [PHP] Finding what headers and content were already been sent

2002-05-31 Thread Rasmus Lerdorf
You can loop through $GLOBALS and check for vars that start with HTTP_, but yes, you typically know which things you are interested in. And no, $HTTP_* are only the request headers. For the Apache module version there is of course also getallheaders() -Rasmus On Sat, 1 Jun 2002, Noor Dawod

RE: [PHP] Finding what headers and content were already been sent

2002-05-31 Thread Rasmus Lerdorf
Ok, I have added apache_response_headers() which returns the current set of headers that Apache either knows about at this point (before the headers are sent) or the set of sent headers once they have actually gone out. This will be in 4.3 -Rasmus On Sat, 1 Jun 2002, Noor Dawod wrote: Ok, I

RE: [PHP] fdup Pipes?

2002-05-30 Thread Rasmus Lerdorf
on a completely different topic. -Rasmus On Thu, 30 May 2002, Jonathan Rosenberg wrote: I have no idea what you are talking about. My message was NOT a reply to a previous post. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] How can I remove the last character from a one line file?

2002-05-28 Thread Rasmus Lerdorf
Ouch! echo substr($string,0,-1); is much more efficient. -Rasmus On Tue, 28 May 2002, Scott Hurring wrote: TIMTOWTDI $string = Jacko; print preg_replace('/.$/', '', $string); --- Scott Hurring Systems Programmer EAC Corporation [EMAIL PROTECTED] Voice: 201-462-2149 Fax: 201-288

RE: [PHP] _() ???

2002-05-28 Thread Rasmus Lerdorf
No, the _() function is the standard gettext() alias. See http://php.net/gettext -Rasmus On Tue, 28 May 2002, John Holmes wrote: What exactly does the underscore in _(Select your preferred language:) mean? It doesn't do anything. It's just a naming convention the author chose to use

RE: [PHP] Generate inline image

2002-05-28 Thread Rasmus Lerdorf
How about the obvious way? img src=generateimage.php?id=3 -Rasmus On Tue, 28 May 2002, Engineering Software Center wrote: Hi: all: With helps from Martin, now I can create images on the fly. I used code like img src=\generateimage.php\ to create my images. However, with this option, how

Re: [PHP] easy date question?

2002-05-28 Thread Rasmus Lerdorf
See the PEAR Date/Calc class. On Tue, 28 May 2002, Ed Lazor wrote: How can I find out the date of the 3rd Tuesday of any given month? Thanks, -Ed -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List

Re: [PHP] PHP 4.1.2 ignores ini-set on max_upload_filesize

2002-05-27 Thread Rasmus Lerdorf
You cannot change the upload limit in your script because the file upload happens before your script is executed. You need to set it in your php.ini, httpd.conf or .htaccess -Rasmus On Mon, 27 May 2002, DevilKin wrote: Hello, As stated in the topic: PHP 4.1.2 balantly ignores

Re: [PHP] Setting PHP Authentication manually?

2002-05-27 Thread Rasmus Lerdorf
can do is emulate it using cookies and/or sessions. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] --NEWBIE-- T_String parse error ??

2002-05-26 Thread Rasmus Lerdorf
You probably missed a quote or something. Show us line 1. On Sun, 26 May 2002, Kevin J wrote: Hello all, I am new to PhP, and I just bought the Beginning PhP 4 book, and i got my first parse error, and I have no idea what it is i done wrong, cause its not covered in this book!!! this

Re: [PHP] ini_set('register_globals',0) doesn't work

2002-05-26 Thread Rasmus Lerdorf
register_globals affects things that happen before PHP parsing begins, so by the time you get to your ini_set() it is too late. So no, that won't work. You need to set it in your php.ini, httpd.conf or .htaccess. -Rasmus On Sun, 26 May 2002, Jens Lehmann wrote: I tested ini_set

Re: [PHP] Function Switch($pid) - NEED HELP

2002-05-25 Thread Rasmus Lerdorf
Just don't do the break in case 1 if you want to fall through to case 2. On Sat, 25 May 2002, Vincent Kruger wrote: I have a script that switches. switch($pid) { case 1: break; case 2: break; } Now I'm doing a check in case 1 and if everything goes well, i want to

Re: [PHP] SegFaults with PHP4.2.1 and Apache 2.0.36

2002-05-25 Thread Rasmus Lerdorf
workaround. For now you can try going single-threaded and see if that helps (although then you might as well just use Apache 1.3.x) -Rasmus On Fri, 24 May 2002, Rodolfo Segleau wrote: Not sure if you guys have already responded to this, but here we go (I'm checking the archives of PHP as I am

Re: [PHP] Selective SafeMode {?!}

2002-05-24 Thread Rasmus Lerdorf
Like every other PHP directive which can be used in a per-dir manner: VirtualHost ... ... php_admin_flag safe_mode On ... /VirtualHost On Sat, 25 May 2002, Liam MacKenzie wrote: Hi guys, I was wondering if it were possibe to have safemode activated for some users but not others. Say I

Re: [PHP] dynamically named variables?

2002-05-23 Thread Rasmus Lerdorf
Or you could simply use: extract($_POST, EXTR_PREFIX_ALL, 'file_'); That does the same thing much quicker. -Rasmus On Thu, 23 May 2002, Nick Wilson wrote: * and then Ford, Mike [LSS] declared Here's the coup: I have a bunch of post vars, lets say $red, $green

Re: [PHP] Leading zeroes

2002-05-23 Thread Rasmus Lerdorf
$str = ltrim($str,'0'); would be more efficient. On Thu, 23 May 2002, Michael Sims wrote: On Thu, 23 May 2002 09:26:05 -0700 (PDT), you wrote: Does anybody have a clever and efficient way of getting rid of leading zeroes in a string? How about: $str = preg_replace(/^0+/,,$str); --

Re: [PHP] Accessing PHP globals from a module.

2002-05-22 Thread Rasmus Lerdorf
On Tue, May 21, 2002 at 08:03:36AM -0700, Rasmus Lerdorf wrote: Depends a bit on what sort of globals you are after. If you mean a global variable set by the user in the global symbol table you would do: pval **tmp; if(zend_hash_find(EG(symbol_table), foo, 3, (void **)tmp

Re: [PHP] voting using text files

2002-05-22 Thread Rasmus Lerdorf
conditions. -Rasmus On Wed, 22 May 2002, 1LT John W. Holmes wrote: A good structure would be to have one file for each possible answer and each file contains the number of votes it has recieved. Then: -- Open file for the chosen option as read only -- Read the value in the file -- Close

Re: [PHP] PHP QUERY_STRING

2002-05-21 Thread Rasmus Lerdorf
register_globals On Tue, 21 May 2002, Stavros Patiniotis wrote: Hello, My web server hdd just crashed, and I have replaced and rebuilt it with a new drive. All of my websites have been transferred over the the new site from backup, and I am having a problem with PHP seeing GET variables.

Re: [PHP] Problem with mktime()

2002-05-20 Thread Rasmus Lerdorf
08 and 09 are not real numbers. Any number starting with a 0 is an octal number which means you can only use digits 0-7 Drop the leading 0 and everything will work. -Rasmus On Mon, 20 May 2002, Johannes Tyra [BrainData] wrote: Hi, I want to read out the asterisk from a birthdate. First

Re: [PHP] bug in SLEEP() function...

2002-05-20 Thread Rasmus Lerdorf
. -Rasmus On Sat, 18 May 2002, Jason Caldwell wrote: Dunno if this has been mentioned or fixed in the latest release (I'm using PHP version 4.1.1) -- but, a script will not timeout until the sleep() function has finished it's duration -- for example: In my script, if I set set_time_limit(30

Re: [PHP] Re: Register_Shutdown_Function ??

2002-05-20 Thread Rasmus Lerdorf
Windows? Blah. This stuff may very well not work there. No idea. -Rasmus On Sat, 18 May 2002, Jason Caldwell wrote: It doesn't matter. I'm setting the output *not* to the browser, but to the command shell, where I am running the script from. If you look at the errors, you'll see 2

Re: [PHP] Re: Register_Shutdown_Function ??

2002-05-20 Thread Rasmus Lerdorf
What makes you think you can echo something after your script has timed out? Change that print to write something to a file in /tmp and you will see that it works just fine. -Rasmus On Sat, 18 May 2002, Jason Caldwell wrote: Here's my code: ? set_time_limit(1

Re: [PHP] Email harvesters

2002-05-20 Thread Rasmus Lerdorf
If there was just one archive of this list and we controlled it, then this would be ok. But the fact is that there are dozens, and we don't control any of them. So I don't see how this could be done. -Rasmus On Mon, 20 May 2002, Richard Baskett wrote: I wrote this email to the php Archive

Re: [PHP] php.net sloooooooowwww

2002-05-20 Thread Rasmus Lerdorf
Use a mirror. us2.php.net is quick We are having some network problems on the main server. A good reminded to everyone to go find your local mirrors and use them instead. On Sat, 18 May 2002, Jason Caldwell wrote: Anyone know why http://www.php.net is s incredibly slow today

Re: [PHP] while loop question - problem (new set of eyes needed)

2002-05-20 Thread Rasmus Lerdorf
You are resetting $row inside your loop. Don't do that. On Sun, 19 May 2002, Lee P Reilly wrote: Hi, I wonder if someone could have a quick look at this for me? It's a simple while loop, but it's not acting the way (I think) it should. If I break down the while loop, it reads:

Re: [PHP] Why would this command just Die!

2002-05-20 Thread Rasmus Lerdorf
Change your die() call to this: die(mysql_error()) so you can actually see what is going on. -Rasmus On Mon, 20 May 2002, Php Developers wrote: This command just dies! I have checked sql connection ... ok the insert into line ... ok Pfft it just don't wanna work ?php $answers

Re: [PHP] Re: php.net sloooooooowwww

2002-05-20 Thread Rasmus Lerdorf
http://php.he.net/distributions/php-4.2.1-Win32.zip On Sat, 18 May 2002, Jason Caldwell wrote: Is there some place else I can download release 4.2.1 ??? www.php.net is dead slow, and us2.php.net is taking forever to prompt me for the download -- I keep getting hit with the Page Cannot be

Re: [PHP] Calling Compiled File From PHP File

2002-05-20 Thread Rasmus Lerdorf
Yes, building a small custom extension is the way to go. And the source tree is the same for UNIX and Windows. On Mon, 20 May 2002, Bruce Miller wrote: I have an algorithm that I don't want anyone to see; therefore I can't put it in a php file. Is there a way I can create a compiled file

RE: [PHP] php4.2.0 (win) error message question

2002-05-20 Thread Rasmus Lerdorf
Hebrew On Tue, 21 May 2002, Martin Towell wrote: I understand that I put :: when I shouldn't have. But why is it called T_PAAMAYIM_NEKUDOTAYIM and not T_DOUBLE_COLON or something else? It's not latin or something is it? -Original Message- From: Peter [mailto:[EMAIL PROTECTED]]

Re: [PHP] Bundled php mysql library vs mysql extension

2002-05-18 Thread Rasmus Lerdorf
be able to talk to a remote MySQL server and because we got tired of answering the dozens of mysql_connect undefined function questions we got every day. -Rasmus On Sat, 18 May 2002, Pentothal wrote: Which are the differences between the php bundled mysql library and the external standard

Re: [PHP] Images with GD

2002-05-17 Thread Rasmus Lerdorf
Use imagettfbbox(). This function calculates the bounding box given the font, size and actual text within which that text would fit. -Rasmus On Fri, 17 May 2002, Anzak Wolf wrote: I'm working on getting some image creation scripts done and I have one requirement that I'm not sure how

Re: [PHP] Subscriber count from db

2002-05-17 Thread Rasmus Lerdorf
See number_format() On Fri, 17 May 2002, Randum Ian wrote: Hi all, Ive been searching through the archives for this and I am still none the wiser! Ive done a count on my database and found out I have 1234567890 stored in a variable $count. How do I output 1,234,567,890 so that if I write

Re: [PHP] PHP+MySQL - Excel ?

2002-05-17 Thread Rasmus Lerdorf
It is also possible to connect directly to MySQL from Excel via MyODBC. -Rasmus On Fri, 17 May 2002, Chris Boget wrote: Is it possible to create an excel file with some data from mySQL, using PHP ? Yes if you know the file format for excel. If not then write your data into a CSV file

Re: [PHP] PHP+MySQL - Excel ?

2002-05-17 Thread Rasmus Lerdorf
No, this has nothing to do with PHP. You can run MySQL on Windows or UNIX, doesn't matter, and set up a connection directly from Excel to MySQL. PHP can of course run anywhere you want and manipulate the data in MySQL which will then be reflected in Excel. -Rasmus On Fri, 17 May 2002, Chris

Re: [PHP] PHP+MySQL - Excel ?

2002-05-17 Thread Rasmus Lerdorf
Are there examples anywhere that illustrate how this can be done? I'm not very interested in looking into this alternative. You are not very interested, but you want examples? Just read the MyODBC docs at mysql.com. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe

Re: [PHP] accessing mysql_fetch_array more than once?

2002-05-17 Thread Rasmus Lerdorf
reset() On Fri, 17 May 2002, Chris Knipe wrote: Hi all, Howcome, when I do a SQL lookup, I can only access the array once? Say, I have... ? $SQL = mysql_query(SOME SELECT STATEMENT); while ($var = mysql_fetch_array($SQL)) { echo $var['columbname']; } // that works, and prints out

Re: [PHP] ob_start() and ob_gzhandler

2002-05-17 Thread Rasmus Lerdorf
You can just set output_handler in your php.ini file to automatically buffer and compress everything. On Fri, 17 May 2002, Jason Soza wrote: Hmmm... So if I -wanted- to buffer the entire page using ob_gzhandler, I wouldn't use ob_implicit_flush(), correct? Or would this be beneficial in this

[PHP] Kiev party (fwd)

2002-05-17 Thread Rasmus Lerdorf
Could someone who has a clue about this fill in Serg and the rest of the folks on this list who might be interested? -- Forwarded message -- Date: Fri, 17 May 2002 23:32:28 +0300 From: Serg Lysak [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Kiev party Hello webmaster,

Re: [PHP] mktime()

2002-05-17 Thread Rasmus Lerdorf
A couple of ways to do it: strtotime('09 May 2002'); mktime(12,0,0,5,9,2002); On Sat, 18 May 2002, Josh Edwards wrote: After reading the manual Istill can't convert this 09/May/2002 to a timestamp. Any Pointers -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] what is php.ini on linux?

2002-05-16 Thread Rasmus Lerdorf
It is called php.ini. A php.ini-dist sample file comes with the distribution. phpinfo() will tell you where it is supposed to live. Just copy php.ini-dist to that_location/php.ini and edit it appropriately. -Rasmus On Thu, 16 May 2002, andy wrote: Hi there, I am wondering what

Re: [PHP] recognising plain text files

2002-05-16 Thread Rasmus Lerdorf
The uploaded mime type is set by the browser, not by PHP. So I guess in your Netscape case it isn't sending the right type. Perhaps have a look at the 'file' UNIX-level command and use that. -Rasmus On Thu, 16 May 2002, Lee P Reilly wrote: Hi, I am doing some validation on files

Re: [PHP] Uploading JPEG's - Security Issues?

2002-05-16 Thread Rasmus Lerdorf
doesn't matter what sort of junk is embedded in the image. At most it will show up as a broken image icon in your browser. -Rasmus On Tue, 14 May 2002, Andre Dubuc wrote: Thanks Rasmus, I thought there had to be function out there that could examine the actual contents. Now the question remains

Re: [PHP] uh, oh errors?

2002-05-16 Thread Rasmus Lerdorf
What is on line 6 of the db.php file? Do you have a stray carriage return at the end of this file? On Thu, 16 May 2002, Jas wrote: Not sure how to resolve this, looked at php.net for the headers available and this is the error I am recieving: Warning: Cannot add header information -

Re: [PHP] How YaBB logs in

2002-05-15 Thread Rasmus Lerdorf
in the DB. There is no way to compare baGGlRhhSFzk2 directly to ysu0jnfX9fp2. -Rasmus On Wed, 15 May 2002, Matthew Ward wrote: I'm currently integrating my site with YaBB so that when you log into my YaBB forums it also logs you into the whole site. I'm also developing a script that I'm integrating

Re: [PHP] IF Statements

2002-05-15 Thread Rasmus Lerdorf
Your brackets don't match up. Use an editor that lets you do bracket-matching. Hit '%' in vi, for example. -Rasmus On Wed, 15 May 2002, Jon Yates wrote: People, hope you can help. The below IF statement is getting a PARSE error. Can anyone spot why? Cheers. Jon

Re: [PHP] Problems compiling php4.2.1 (lex command not found)

2002-05-14 Thread Rasmus Lerdorf
quick-fix is to just install flex on your box - not sure why this requirement suddenly appeared though. Perhaps a timestamp is wrong on a file. -Rasmus On Tue, 14 May 2002, andy wrote: Hi there, I did recently compile php4.2.0 and it worked fine. Now I did download 4.2.1 and used the same

Re: [PHP] GD library problem

2002-05-14 Thread Rasmus Lerdorf
there that have jpg, png and gif all included. PHP supports these hacked versions. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Problems compiling php4.2.1 (lex command not found)

2002-05-14 Thread Rasmus Lerdorf
You don't really need to know what flex is. Just install the flex rpm. On Tue, 14 May 2002, andy wrote: does that mean that I can fix it anyhow, or this is a bug on 4.2.1? I don't know what flex is. Andy Rasmus Lerdorf [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]"

Re: [PHP] GD library problem

2002-05-14 Thread Rasmus Lerdorf
By the way, there is no createimage() function. It is called imagecreate(). And the only real news is that the Unisys patent expires in 2003, so we might be able to do something then. But GIF needs to die. It's a crappy format. PNG is well supported in all browsers. -Rasmus On Tue, 14 May

Re: [PHP] Calculating the bandwith usage

2002-05-14 Thread Rasmus Lerdorf
Not really a job for PHP. That is best done by analyzing the httpd logs after the fact. On Tue, 14 May 2002, Etus wrote: Hey, I need to write a script in php that calculate the bandwith usage of selected pages. Anyone knows how I can do this? Thanks, Yuval -- PHP General Mailing

Re: [PHP] Sessions Without Cookies or SID Passing...

2002-05-14 Thread Rasmus Lerdorf
Use standard HTTP authentication over SSL - that's the only other way. On Tue, 14 May 2002, Matthew Walker wrote: We have a shopping cart product we're developing in PHP, and I've recently come across I dilemma that I need to find a reliable solution to. Many of the people who will be

RE: [PHP] Sessions Without Cookies or SID Passing...

2002-05-14 Thread Rasmus Lerdorf
Authentication is really just like a cookie that can't be disabled when it comes down to it. -Rasmus On Tue, 14 May 2002, Matthew Walker wrote: You're not understanding the problem. This is not an authentication situation. We are using sessions to track information about what a customer's OrderID

RE: [PHP] Sessions Without Cookies or SID Passing...

2002-05-14 Thread Rasmus Lerdorf
not a good idea. -Rasmus On Wed, 15 May 2002, Martin Towell wrote: You're missing one method - using the user's IP address It's not a guaranteed fool-proof method, but if you don't want to use cookies or the URL, then this sorta works. -Original Message- From: Rasmus Lerdorf [mailto

RE: [PHP] Sessions Without Cookies or SID Passing...

2002-05-14 Thread Rasmus Lerdorf
a cookie. Depending on how users configure their browsers they may have to log in at the beginning of a session although these days most browsers have these password managers that make this login procedure trivial. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit

Re: [PHP] PHP 4.2x changes

2002-05-14 Thread Rasmus Lerdorf
Turn on register_globals in your php.ini file and things should start working again. On Tue, 14 May 2002, Weston Houghton wrote: All, I've recently upgraded from 4.1.2 to 4.2.0. And of course my script has stopped working. I know a lot with the globals has changed, but to be honest, I am

Re: [PHP] Uploading JPEG's - Security Issues?

2002-05-14 Thread Rasmus Lerdorf
random filename in /tmp ensuring not to overwrite anything that is already there. It is then your job to perform the check and copy the file to some appropriate directory on your server. If you don't do anything with the file, PHP will automatically delete it at the end of the request. -Rasmus

Re: [PHP] WTF

2002-05-14 Thread Rasmus Lerdorf
Turn on register_globals in your php.ini file. On Tue, 14 May 2002, mail-list wrote: This is bothering the hell out of me. The first file is a simple form, passing the information to the second file (send_request.php). For some reason the variables are not passing through to the second page.

Re: [PHP] PHP 4.2x changes

2002-05-14 Thread Rasmus Lerdorf
http://www.php.net/manual/en/security.registerglobals.php On Wed, 15 May 2002, Weston Houghton wrote: Ok, makes sense based on previous threads I have gleaned over. Can you point me to any reading material that fills in the details on all of this though? Would like to know more about why I

Re: [PHP] PHP 4.2x changes

2002-05-14 Thread Rasmus Lerdorf
Try it. $_SERVER[...] will work fine inside your class. -Rasmus On Wed, 15 May 2002, Weston Houghton wrote: Thanks for the link. Everything there makes sense, and I'm not sure if I need to turn register_globals on to make this work. Is there a way to get either: $_SERVER[PATH_TRANSLATED

Re: [PHP] Apache does not work with PHP

2002-05-14 Thread Rasmus Lerdorf
First of all, PHP 4.0.4 is over 2 years old now. Upgrade! Then let us know if you have any problems. -Rasmus On Wed, 15 May 2002, Vivek Kumar Agrawal wrote: Dear Folks, I am trying to set up Suse Linux Server with sybase and PHP. While configuring my computer with these software I am

Re: [PHP] Import/Export with MS outlook/Outllok Express

2002-05-13 Thread Rasmus Lerdorf
php.net/fgetcsv On 10 May 2002, Amit Singh wrote: Hi Folks, Can anybody help me getting a piece of code for processing a file(csv format) having MS Outlook/Outlook Express addresses. I want to read the file line by line taking care of possible multiline entries in any field of the record.

Re: [PHP] ImageLines with styles

2002-05-13 Thread Rasmus Lerdorf
http://www.php.net/manual/en/function.imagesetthickness.php On Mon, 13 May 2002, Leotta, Natalie (NCI/IMS) wrote: Hello. I'm drawing line graphs and for each line they want a different style (dots, dashes, etc.). I can't find a way to make the line draw thicker than normal, and the regular

Re: [PHP] Timeline for Apache 2 full use?

2002-05-13 Thread Rasmus Lerdorf
virtually no testing, so issues in that are unknown as well. 6 months is much more realistic as far as I am concerned. -Rasmus On Mon, 13 May 2002, Eli White wrote: As the subject says, can anyone give me a timeline estimate for full usage (not experimental) of PHP within Apache 2.0? I ask

Re: [PHP] Re: Debugger

2002-05-12 Thread Rasmus Lerdorf
for conspiracy reasons. I mean if the PHP 3 debugging code worked with PHP 4, then you could just take the code from PHP 3 and use it. It's not like it is deleted from CVS. -Rasmus On Sun, 12 May 2002, Michael Kimsal wrote: Jose Leon wrote: It would be nice that php itself incoporates

Re: [PHP] Re: function over loading?

2002-05-12 Thread Rasmus Lerdorf
Well, not in the procedural sense, but you can do method and property overloading on objects. See http://php.net/overload -Rasmus On Sun, 12 May 2002, Smileyq wrote: In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Kris Vose) wrote: Can you practice function over-loading in php

Re: [PHP] Email updates

2002-05-11 Thread Rasmus Lerdorf
Have a look at procmail (http://www.procmail.org/) -Rasmus On Sat, 11 May 2002, Randum Ian wrote: Hi all, I want to be able to allow certain people the ability to email news directly onto a page using the address [[EMAIL PROTECTED]] but only if they are verified on a db. Please can

Re: [PHP] Problme with PHPMyAdmin.

2002-05-11 Thread Rasmus Lerdorf
Apache2+PHP has a number of issues. At this point it is only suitable for testing purposes. I suggest using Apache 1.3.x if you want a stable working server. -Rasmus On Sat, 11 May 2002, vins wrote: My phpMyAdmin keeps caching it'self. How do i disable it. I'm using apache 2 and php4.2

Re: [PHP] setcookie()

2002-05-11 Thread Rasmus Lerdorf
PHP is a server-side language and as such it deals with server-side issues. If you want to write javascript that sets a client-side Javascript cookie, go ahead. It has nothing to do with PHP and PHP will certainly not get in your way. -Rasmus On Sat, 11 May 2002, jtjohnston wrote

Re: [PHP] setcookie()

2002-05-11 Thread Rasmus Lerdorf
And you can do so if you turn on output buffering. Having PHP send off JavaScript to do this is a massive hack that has no place in PHP. Write your own setcookie wrapper function if that is what you want. -Rasmus On Sat, 11 May 2002, jtjohnston wrote: Rasmus server-side / client-side

Re: [PHP] PHP 5??

2002-05-11 Thread Rasmus Lerdorf
He has no clue. There is no PHP 5. The next version will be 4.2.1 next week and probably 4.3 after that. -Rasmus On Sat, 11 May 2002, Tim Thorburn wrote: Hi, In my seemingly never ending search for a decent hosting company, I've contacted some customer service people from Verio who tell

Re: [PHP] read all files in directory

2002-05-11 Thread Rasmus Lerdorf
See http://php.net/readdir for a full example. On Sun, 12 May 2002, Andreas Indahl wrote: Hi! How can I read all files in a directory, when I don't know which files are there? Sincerely Andreas Indahl -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Re: Debugger

2002-05-10 Thread Rasmus Lerdorf
See DBG (http://dd.cron.ru/dbg/) On Sat, 11 May 2002, Jason Wong wrote: On Saturday 11 May 2002 04:07, Austin Marshall wrote: Jose Leon wrote: php -l will let you know where your syntax errors are. What? Regards If you invoke the interpreter from the command line (CGI).

Re: [PHP] External authentication and PHP_AUTH_PW containing plaintext password

2002-05-09 Thread Rasmus Lerdorf
The code is pretty obvious in sapi/apache/mod_php4.c in the init_request_info() function. On Thu, 9 May 2002, Lenny Miceli wrote: I've tried to search the archives/bug reports/faq's and didn't find any definitive answers on the security issue dealing with the plain text password being kept

Re: [PHP] Announcement: Smarty template engine 2.1.1 released

2002-05-07 Thread Rasmus Lerdorf
Relax Dan, open source non-commercial PHP-related announcements of interest to a lot of PHP users are welcome here. -Rasmus On Tue, 7 May 2002, Dan Hardiker wrote: This is a minor bug fix release. Wasnt aware that php-general had incorporated a channel for product plugging

Re: [PHP] Unsetting PHP_AUTH_USER

2002-05-07 Thread Rasmus Lerdorf
there is no way to tell a browser to not send this header cleanly. Sending a 401 is the only way, but as you mentioned that pops up the login button. So basically you will have to layer some additional mechanism on top of the http auth system to achieve what you want. -Rasmus On Wed, 8 May 2002

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread Rasmus Lerdorf
See either extract() or import_request_variables() in the manual. -Rasmus On Mon, 6 May 2002, David J Jackson wrote: The code below works (but its ugly), but I know there has to be a why to grab all the $_POST[] at once and then parse them out? Isn't there a why for me to access them

RE: [PHP] file_exists

2002-05-06 Thread Rasmus Lerdorf
Not until 4.3. On Mon, 6 May 2002, Jonathan Rosenberg wrote: Does fopen() actually work for https connections? I thought this implementation was not yet released. -Original Message- From: Austin Marshall [mailto:[EMAIL PROTECTED]] Sent: Monday, May 06, 2002 9:40 PM To: Craig

Re: [PHP] date(), strtotime(), Wed, Dec 31, 1969 ??

2002-05-03 Thread Rasmus Lerdorf
Because your strtotime() call is returning 0. Replace the '-' with '/' and I bet it would work. -Rasmus On Fri, 3 May 2002, ROBERT MCPEAK wrote: Running PHP3 on a Linux box and I've got trouble with date(). Here's the code: $blah=2002-05-02; $thedate = date(D, M d, Y, strtotime($blah

RE: [PHP] I want to use a mailer other than sendmail

2002-05-03 Thread Rasmus Lerdorf
actually all that bad) Now find the line that starts with DS and change it so it says: DSmail.mindspring.com for example. Then restart your sendmail. And now hocus-pocus-presto-shazzam, your sendmail suddenly works great for all your apps, not just PHP. -Rasmus On Fri, 3 May 2002, John Holmes wrote

RE: [PHP] Problems upgrading PHP..

2002-05-02 Thread Rasmus Lerdorf
confused.. Chad -Original Message- From: Chad Day [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 02, 2002 2:52 PM To: Rasmus Lerdorf Cc: [EMAIL PROTECTED] Subject: RE: [PHP] Problems upgrading PHP.. php.ini didn't exist before apparently on this server I'm on.. or rather, it was a 0

Re: [PHP] Search engine indexing

2002-05-02 Thread Rasmus Lerdorf
yup On Tue, 30 Apr 2002, Charl wrote: Are PHP files indexed the same way as plain HTML files by search engines? -- Charl -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] asking about upload file

2002-05-02 Thread Rasmus Lerdorf
Did you read the chapter in the manual on that? On Fri, 3 May 2002, wong wrote: please help me how upload 5 file gif or jpeg together with php. RiZaL -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List

Re: [PHP] Variables not set

2002-04-26 Thread Rasmus Lerdorf
Please read http://www.php.net/manual/en/language.variables.scope.php On Fri, 26 Apr 2002, Liam Gibbs wrote: I have a problem with my variables not being set. I have a file I use for constants and functions, structured like so: $this = this; $that = that; . . . function this() {

Re: [PHP] Safe mode

2002-04-26 Thread Rasmus Lerdorf
You need to use php_admin_flag for safe_mode. But I wouldn't expect any effect here since you defaulted it to On and in your httpd.conf you are turning it on... So what are you expecting to see different? -Rasmus On Fri, 26 Apr 2002, Ashley M. Kirchner wrote: On our server, PHP's

Re: [PHP] getting session data

2002-04-26 Thread Rasmus Lerdorf
You forgot to do a session_start() in your a.php script. Also make sure register_globals is turned on. If it isn't, use $_SESSION['userip'] in b.php. -Rasmus On Fri, 26 Apr 2002, Deval Parikh wrote: hi, IF I am using this code in one script... a.php - ?php $userip

Re: [PHP] Variables not working

2002-04-26 Thread Rasmus Lerdorf
Turn on register_globals in your php.ini file. On Sat, 27 Apr 2002, baldey_uk wrote: Hello all, im not sure if its my installation or if on doing something wrong but i cant seem to use any of the variables from forms that i PUT to. Or any full stop! even ?php echo $HTTP_USER_AGENT; ?

RE: [PHP] Variables not working

2002-04-26 Thread Rasmus Lerdorf
PROTECTED]] Sent: 27 April 2002 02:34 To: Rasmus Lerdorf; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [PHP] Variables not working Before you get carried away with registering globals, try echoing: $_SERVER[HTTP_USER_AGENT]; Or, for versions prior to 4.1.X, change

Re: [PHP] PHP Team: PHP 4.2.0 SSL Support?

2002-04-26 Thread Rasmus Lerdorf
4.3 will have better support courtesy of Wez's cool streams code. -Rasmus On Fri, 26 Apr 2002, [-^-!-%- wrote: Hello PHP Team ! I was wondering if the latest PHP release had any improved support for SSL and secure connections. Are there any plans to add (or enhance) SSL support in PHP

Re: [PHP] mail() through a form

2002-04-26 Thread Rasmus Lerdorf
['name']; $email = $row['email']; if($submit) { if($automail == 'abuse') { $From = $name; $to = [EMAIL PROTECTED]; mail( $to, $From, $email, $message ); The argument to mail() are to, subject, message. See http://www.php.net/manual/en/function.mail.php The rest looks ok. -Rasmus

<    3   4   5   6   7   8   9   10   11   12   >