[PHP] Pushing array onto array

2003-08-01 Thread Hank TT
In comparing Perl's push to array_push in "PHP Developer's Cookbook" (2/e, p. 76), the authors note that pushing an array onto another produces a two-dimensional array. However, I have not been able to reproduce their example result, and php.net/array_push does not document this behavior. Just cu

Re: [PHP] strings

2003-08-01 Thread Anthony Ritter
Curt Zirzow writes: > I did some testing you can see the code and results here: > http://zirzow.dyndns.org/html/php/tests/preg/parse_doc.php .. Thanks Curt. I checked it out and I still pick up the following lines which I was looking to delete on the pattern match. They are:

RE: [PHP] weird php error

2003-08-01 Thread Matt Giddings
Duh, I figured it out. I had the permissions screwed up on the file. Thanks for your help and sorry for bothering everybody else with my ignorance. Matt > -Original Message- > From: Matt Giddings [mailto:[EMAIL PROTECTED] > Sent: Friday, August 01, 2003 11:25 PM > To: 'Jim Lucas'; 'David

RE: [PHP] weird php error

2003-08-01 Thread Matt Giddings
Haven't found anything yet. The login.php file is the one I'm trying to view when I get that error. I have a second file "info.php" that works fine, but all it contains is "". So I know apache/php is working, I just don't know why it isn't working with my login script. Matt > -Original Mes

Re: [PHP] strange issue: cygwin- why can't I configure the php.ini ?

2003-08-01 Thread Jason Wong
On Saturday 02 August 2003 09:00, kalmen wrote: > I have installed the latest cygwin - php4.2 with apache, but looking at > the configuration file for > php.ini , I tried to change value , restart apache and it didn't work > then I went and totally rename the php.ini to aaa.bak and restart apache

Re: [PHP] plPHP released.. yes PostgreSQL functions in PHP

2003-08-01 Thread Curt Zirzow
* Thus wrote Joshua D. Drake ([EMAIL PROTECTED]): > Hello, > > As a recent flurry of activity has commenced within Command Prompt we > have released upon this rather unround earth, plPHP. Yes it is trigger > safe, yes you can write UDF's in PostgreSQL with PHP now. I have yet to know what it do

Re: [PHP] strings

2003-08-01 Thread Curt Zirzow
* Thus wrote Anthony Ritter ([EMAIL PROTECTED]): > Curt Zirzow wrote in message: > > > This exact thing was talked about earlier today, with the subject > > 'Using eregi_replace()'. > > > Right. > > However, I've tried using the following code in which the text from the

[PHP] embedding php in C

2003-08-01 Thread April
This was last asked: in 2001 2. 2001-07-31 Embedding PHP into another application... The solution suggested was to adopt a commericial package. I have experimented with a javascript library, but I think the licensing of php is more favourable; I am not lawyer though! I have seen somewhere that

[PHP] plPHP released.. yes PostgreSQL functions in PHP

2003-08-01 Thread Joshua D. Drake
Hello, As a recent flurry of activity has commenced within Command Prompt we have released upon this rather unround earth, plPHP. Yes it is trigger safe, yes you can write UDF's in PostgreSQL with PHP now. Find it here: http://www.commandprompt.com/entry.lxp?lxpe=260 Have a glorius weekend.

Re: [PHP] Verisign PFPRO API & PHP: How to ensure hitting "STOP" in the browser will not kill the transcation

2003-08-01 Thread Curt Zirzow
* Thus wrote e ([EMAIL PROTECTED]): > > > I've not been able to find anywhere a good use of the pfpro > functionality in PHP. No where do any of the scripts ensure that the > script goes through it's full execution. > > One person's solution was just to exec the pfpro binary in the > backgrou

Re: [PHP] strings

2003-08-01 Thread Anthony Ritter
Curt Zirzow wrote in message: > This exact thing was talked about earlier today, with the subject > 'Using eregi_replace()'. Right. However, I've tried using the following code in which the text from the URL is printed out completely and then I change the variable from $

[PHP] Verisign PFPRO API & PHP: How to ensure hitting "STOP" in the browser will not kill the transcation

2003-08-01 Thread e
I've not been able to find anywhere a good use of the pfpro functionality in PHP. No where do any of the scripts ensure that the script goes through it's full execution. One person's solution was just to exec the pfpro binary in the background, passing it the necessary arguments. This seems i

[PHP] strange issue: cygwin- why can't I configure the php.ini ?

2003-08-01 Thread kalmen
Hi, I have installed the latest cygwin - php4.2 with apache, but looking at the configuration file for php.ini , I tried to change value , restart apache and it didn't work then I went and totally rename the php.ini to aaa.bak and restart apache which I expecting the error reading og the php.ini

Re: [PHP] Test a zip file for validity

2003-08-01 Thread Curt Zirzow
* Thus wrote Ivo Pletikosic ([EMAIL PROTECTED]): > Hello all, > > How do I go about checking if a file is a zip file? > > Wrapping the zipinfo utility in php did not help since it does not return an > exit code whether it succeeded or not. I'm assuming the zipinfo your talking about is part of t

Re: [PHP] strings

2003-08-01 Thread Curt Zirzow
* Thus wrote Anthony Ritter ([EMAIL PROTECTED]): > In the following snippet, I'm trying to open and read a URL into the > variable $contents. > I'd like to use preg_replace() to return only part of that string beginning > with say - regional and ending with new - but I get the complete URL string >

RE: [PHP] Test a zip file for validity

2003-08-01 Thread Chris W. Parker
Ivo Pletikosic on Friday, August 01, 2003 5:10 PM said: > Wrapping the zipinfo utility in php did not help since it does not > return an exit code whether it succeeded or not. Well if zipinfo returns anything at all it's probably valid. If it doesn't then it's proba

[PHP] Test a zip file for validity

2003-08-01 Thread Ivo Pletikosic
Hello all, How do I go about checking if a file is a zip file? Wrapping the zipinfo utility in php did not help since it does not return an exit code whether it succeeded or not. Thanks, IP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.ph

Re: [PHP] weird php error

2003-08-01 Thread Jim Lucas
yes it could be in the httpd.conf file. look in your VirtualHost block and see if something there refers to a file called loging.php Jim Lucas - Original Message - From: "Matt Giddings" <[EMAIL PROTECTED]> To: "'David Nicholson'" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, A

[PHP] strings

2003-08-01 Thread Anthony Ritter
In the following snippet, I'm trying to open and read a URL into the variable $contents. I'd like to use preg_replace() to return only part of that string beginning with say - regional and ending with new - but I get the complete URL string returned. Thank you for any assistance. Tony Ritter .

[PHP] Re: A long float number.

2003-08-01 Thread zavaboy
Thanks! number_format() fixed it! "Bogdan Stancescu" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Keeping it on one line doesn't affect the calculations (as it > shouldn't). Try using either sprintf() or number_format() for this > purpose (the latter is generally preferred, but I

RE: [PHP] weird php error

2003-08-01 Thread Matt Giddings
David, This is what my php.ini file looks like and I don't seem to have any .htaccess files. Could it be something in the httpd.conf file that’s pointing to an invalid file/directory? ; Automatically add files before or after any PHP document. auto_prepend_file = auto_append_file = Matt > -

Re: [PHP] weird php error

2003-08-01 Thread David Nicholson
Hello, This is a reply to an e-mail that you wrote on Sat, 2 Aug 2003 at 00:10, lines prefixed by '>' were originally written by you. > Hello, > I'm getting a weird warning message from a php script that I'm > working > on. Right now the script does not contain any include or require > statemen

[PHP] weird php error

2003-08-01 Thread Matt Giddings
Hello, I'm getting a weird warning message from a php script that I'm working on. Right now the script does not contain any include or require statements and is basically a very simple straight forward script. But when I try to execute via the browser I get the following error: Warning: Faile

RE: [PHP] Search Engine

2003-08-01 Thread Ralph Guzman
Check out: http://www.htdig.org/ -Original Message- From: imran [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 4:14 PM To: [EMAIL PROTECTED] Subject: [PHP] Search Engine Hi, Does anyone know any free search engine for web application imee -- PHP General Mailing L

Re: [PHP] Re: Globals

2003-08-01 Thread Jim Lucas
I am running PHP 4.2.2 on Debian linux with apache 1.3.26 Jim - Original Message - From: Greg Beaver To: Jim Lucas Cc: [EMAIL PROTECTED] Sent: Friday, August 01, 2003 3:02 PM Subject: Re: [PHP] Re: Globals What version of PHP are you running? I have PHP 4.3.2 on window

[PHP] Re: A long float number.

2003-08-01 Thread Bogdan Stancescu
Keeping it on one line doesn't affect the calculations (as it shouldn't). Try using either sprintf() or number_format() for this purpose (the latter is generally preferred, but I don't know exactlt what you're after). Bogdan Zavaboy wrote: How do I prevent a long float number end up like this

Re: [PHP] Re: Globals

2003-08-01 Thread Greg Beaver
What version of PHP are you running? I have PHP 4.3.2 on windows XP here. I'm getting bool(false) bool(false) every time. Greg Jim Lucas wrote: I don't follow what you are trying to say here? it is returning true, just as it should. show me the results that you get by running this code. he

Re: [PHP] Multiple targets with fscanf

2003-08-01 Thread Dan Anderson
> Thanks a lot. hehe no thanks needed. Just remember to read up on the functions so you'll know how they work. ;-) -Dan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Globals

2003-08-01 Thread Jim Lucas
I don't follow what you are trying to say here? it is returning true, just as it should. show me the results that you get by running this code. here is mine bool(true) bool(true) What is wrong about this? Read my notes below To: "Jim Lucas" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent:

Re: [PHP] Re: Globals

2003-08-01 Thread Greg Beaver
Jim, My bad, I posted the wrong code. Try this instead to see the bug: { var_dump(isset($GLOBALS['GLOBALS'])); return array_keys($GLOBALS); } //var_dump(not_super(), array_keys($GLOBALS)); not_super(); not_super(); ?> run this code, don't read it, you will see output of bool(false), boo

Re: [PHP] preg, patern quantifier limit

2003-08-01 Thread David Nicholson
Hello, This is a reply to an e-mail that you wrote on Fri, 1 Aug 2003 at 20:35, lines prefixed by '>' were originally written by you. > Hi, i did a standard preg [A-Za-z0-9]{1,65536} > What i am simply trying to do is to validate the a form that will > insert > into my TEXT database field. So i ju

RE: [PHP] Redirect to HTTPS

2003-08-01 Thread Luis Lebron
Here's another way to do it: https://$url_array[host]$url_array[path]";); } ?> Luis -Original Message- From: Richard Baskett [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 3:25 AM To: PHP General Subject: Re: [PHP] Redirect to HTTPS This is how I do it: if ($_SERVER['HTTPS

[PHP] A long float number.

2003-08-01 Thread zavaboy
How do I prevent a long float number end up like this after/during a calculation? 8.5E-05 //A number error occurs. I even tried keeping the whole calculation in 1 line: //Get the weight (in pounds) of a O-Ring. $N = round((0.03613 * 1.85 * ((pow(pi(), 2) * pow(($iDia[$d] - $oDia[$d]), 2) *

Re: [PHP] Re: Globals

2003-08-01 Thread Jim Lucas
umm... That is what is going to happen when you follow your example. I think you are mistaken in what you are expecting... This line: $a = array_keys($GLOBALS); will give you an array of values that match the keys of the $GLOBALS array it won't copy the arrays. Try this. $value) { echo

Re: [PHP] preg, patern quantifier limit

2003-08-01 Thread Curt Zirzow
* Thus wrote Yann Larrivee ([EMAIL PROTECTED]): > Hi, i did a standard preg [A-Za-z0-9]{1,65536} > > What i am simply trying to do is to validate the a form that will insert > into my TEXT database field. So i just want to prevent a larger insert > then expected. > > > PHP trows me this error "p

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Mike Migurski
>$HTTP_RAW_POST_DATA is an array... >with echo you'll only get "array".. No, it's a string - just the raw bytes that were posted. >> Is register globals ON or OFF? Either way, maybe try >> $_SERVER['HTTP_RAW_POST_DATA']... Also, ensure that "always_populate_raw_post_data" is on, too - see: http:

Re: [PHP] Re: Globals

2003-08-01 Thread Greg Beaver
Hi Jim, The code you posted is correct, I never contested that. Read carefully. function not_super() { var_dump(isset($GLOBALS['GLOBALS'])); $a = array_keys($GLOBALS); var_dump(isset($a['GLOBALS'])); } not_super(); ?> run this code, don't read it, you will see output of bool(false)

Re: [PHP] Re: Globals

2003-08-01 Thread Jim Lucas
actually, it does work and it does exist. Try using print_r() or print_r(array_keys($GLOBALS)); and you will see an entry for GLOBALS mine is located at #13 Jim Lucas - Original Message - From: "Greg Beaver" <[EMAIL PROTECTED]> To: "Leif K-Brooks" <[EMAIL PROTECTED]> Cc: <[EMAIL PR

RE: [PHP] _GET question

2003-08-01 Thread Chris W. Parker
Pushpinder Singh Garcha on Friday, August 01, 2003 11:11 AM said: > action="full_profile_1.php?val=$company"> Use a hidden form element instead. > Can some one tell me if the action parameter of the form is correct ? > Since in the first part of the if() stateme

Re: [PHP] Re: Globals

2003-08-01 Thread Greg Beaver
Try this code: } blah(); ?> It appears that in a function scope, it doesn't. This is definitely a bug, I'll post it if it hasn't already been noticed. Greg Leif K-Brooks wrote: Greg Beaver wrote: $GLOBALS does not contain a reference to itself Yes it does. I just ran the following, and I

[PHP] preg, patern quantifier limit

2003-08-01 Thread Yann Larrivee
Hi, i did a standard preg [A-Za-z0-9]{1,65536} What i am simply trying to do is to validate the a form that will insert into my TEXT database field. So i just want to prevent a larger insert then expected. PHP trows me this error "preg_match(): Compilation failed: number too big in {} quantifier

Re: [PHP] Re: Globals

2003-08-01 Thread Leif K-Brooks
Greg Beaver wrote: $GLOBALS does not contain a reference to itself Yes it does. I just ran the following, and I got "Greg is wrong." -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP G

RE: [PHP] Globals

2003-08-01 Thread Jay Blanchard
[snip] just to let you know, the $GLOBALS[] superglobals was around long before php 4.1.0 // Superglobals are available in any scope and do // not require 'global'. Superglobals are available // as of PHP 4.1.0 [/snip] This is the quote in the online manual -- PHP General Mailing List (http://

Re: [PHP] Globals

2003-08-01 Thread Jim Lucas
just to let you know, the $GLOBALS[] superglobals was around long before php 4.1.0 Jim Lucas - Original Message - From: "Jay Blanchard" <[EMAIL PROTECTED]> To: "Chris Boget" <[EMAIL PROTECTED]>; "PHP General" <[EMAIL PROTECTED]> Sent: Friday, August 01, 2003 12:18 PM Subject: RE: [PHP] Gl

Re: [PHP] Globals

2003-08-01 Thread Jim Lucas
Maybe it has to do with the fact that the $GLOBALS[] array has a copy of itself inside the parent. kinda weird but it looks like this $GLOBALS['key1'] = 'value1'; $GLOBALS['key2'] = 'value2'; $GLOBALS['GLOBALS']['key1'] = 'value1'; $GLOBALS['GLOBALS']['key2'] = 'value2'; don't ask me why, but it

[PHP] Re: Globals

2003-08-01 Thread Greg Beaver
Hi Chris, Chris Boget wrote: function blah() { //global $GLOBALS; echo 'Globals: '; print_r( $GLOBALS ); echo ''; } As it is shown above, with the 'global $GLOBALS' line commented out, the print_r() works and shows all the currently defined variables and their corresponding values. However, if

RE: [PHP] Globals

2003-08-01 Thread Jay Blanchard
[snip] $GLOBALS [/snip] >From http://us2.php.net/language.variables.scope "The $GLOBALS array is an associative array with the name of the global variable being the key and the contents of that variable being the value of the array element. Notice how $GLOBALS exists in any scope, this is because

Re: [PHP] Globals

2003-08-01 Thread Chris Boget
> I'm curious if someone could explain to me why this is occuring: > > function blah() { > //global $GLOBALS; > echo 'Globals: '; print_r( $GLOBALS ); echo ''; > > } > > As it is shown above, with the 'global $GLOBALS' line commented > out, the print_r() works and shows all the currently defi

Re: [PHP] Globals

2003-08-01 Thread Jim Lucas
I can't speek about the first problem, but about the second one. You are not setting the variable $blah as a global variable. Try this instead $GLOBALS['blah'] = 'bob'; and that should work. You need to look into scope when refering to variables and functions. Jim Lucas - Original Messag

[PHP] FDF Library Issues

2003-08-01 Thread Richard Lynch
Please Cc: me directly, if possible. Thanks! [This got long, but a search for "Synopsis:" (two of them) should give the gist.] Originally, the machine (Linux 2.4.19-16mdk) had Mandrake 8 RPM's of PHP 4.2.3 and Apache 1.2.26 I was able to install LIBFDFTK.SO 5.0 and the .h file, symlinked to low

[PHP] Globals

2003-08-01 Thread Chris Boget
I'm curious if someone could explain to me why this is occuring: function blah() { //global $GLOBALS; echo 'Globals: '; print_r( $GLOBALS ); echo ''; } As it is shown above, with the 'global $GLOBALS' line commented out, the print_r() works and shows all the currently defined variables and the

[PHP] _GET question

2003-08-01 Thread Pushpinder Singh Garcha
Hello All, My application has a search / query feature where in the user selects the search criteria and is displayed a page containing the reults. The user must also be allowed to edit these results and save them later on. On the results page I use the following logic, // // START OF P

[PHP] Re: using mail()

2003-08-01 Thread Kevin Stone
"Amanda McComb" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > If I am using this code: > > mail("[EMAIL PROTECTED]", "test", "testbody"); > > and want to add a From: line, how do I do it? > > Also, is this an excepted way of sending mail from a web page? > > Thanks, > Amanda The m

Re: [PHP] Re: Search Engine

2003-08-01 Thread John W. Holmes
John W. Holmes wrote: DvDmanDT wrote: I use to write my own search engines... That way they get customized easier... You can write one that spiders like google... Hell, it even found my private server... And there's not a single link ther afaik.. Now, is it for web or site search? If site, just

RE: [PHP] using mail()

2003-08-01 Thread Jay Blanchard
[snip] If I am using this code: mail("[EMAIL PROTECTED]", "test", "testbody"); and want to add a From: line, how do I do it? Also, is this an excepted way of sending mail from a web page? [/snip] Read http://us4.php.net/manual/en/function.mail.php Example 2 (How's that Chris?) And yes, it is a

Re: [PHP] Re: Search Engine

2003-08-01 Thread John W. Holmes
DvDmanDT wrote: I use to write my own search engines... That way they get customized easier... You can write one that spiders like google... Hell, it even found my private server... And there's not a single link ther afaik.. Now, is it for web or site search? If site, just get a MySQL table with a

[PHP] using mail()

2003-08-01 Thread Amanda McComb
If I am using this code: mail("[EMAIL PROTECTED]", "test", "testbody"); and want to add a From: line, how do I do it? Also, is this an excepted way of sending mail from a web page? Thanks, Amanda -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsu

Re: [PHP] Multiple targets with fscanf

2003-08-01 Thread Denis 'Alpheus' Cahuk
Dan Anderson wrote: Is there any reason you couldn't do something like: "); { $li_tag_start_position = strpos($buffer,""); $li_tag_end_position = strpos($buffer,""); $data = substr($buffer,(4 + $li_tag_start_position),(4 + $li_tag_end_position)); $buffer = substr($buffer, (4 + $li_tag_end_positio

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Philip Olson
Your script should work fine, and to fix claims made in this thread: a) $HTTP_RAW_POST_DATA is NOT an array, it's a string. b) It does not live in $_SERVER, or rely on register_globals. Your code is wrong because you don't provide names for your fields, so there is no POST data. Assign your

RE: [PHP] Please Help

2003-08-01 Thread Chris W. Parker
Jay Blanchard on Friday, August 01, 2003 9:24 AM said: > Sigh. What happened to the two *'s? I'm going to take this opportunity to be the bigger man and say I respect your opinion. ;) Chris. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visi

RE: [PHP] Please Help

2003-08-01 Thread Jay Blanchard
[snip] 1. Which do you think is most helpful and benefits the list the most? [/snip] Give a man a program, frustrate him for a day, teach a man to program, frustrate him for a lifetime. IOW send a person to start learning. The question was so vague that the answers given were appropriate. [snip]

Re: [PHP] Purging old files from directories

2003-08-01 Thread Curt Zirzow
* Thus wrote Verdon vaillancourt ([EMAIL PROTECTED]): > Hi :) > > I need to write a script that will scan/read a given directory's contents > and delete files older than a certain date. Ideally, this will be a script > that runs via cron once a week and deletes all files it finds in the > director

RE: [PHP] Please Help

2003-08-01 Thread Chris W. Parker
Jay Blanchard on Friday, August 01, 2003 9:02 AM said: > Hmmm, let's see. The post had no clarity in the subject line, the post > showed no sense of "I tried to look it up", the post was vague You have three options: 1. Explain to them how they could have made thei

RE: [PHP] Please Help

2003-08-01 Thread Jay Blanchard
[snip] > It's always funny how people think these kinds of posts are helpful. > [/snip] > > They're not? Yes, they are not. [/snip] Hmmm, let's see. The post had no clarity in the subject line, the post showed no sense of "I tried to look it up", the post was vague, shall I go on? Folks on the l

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 04:51:38PM +0100, skate wrote: > > > > you could also use different delimiters and write for example: > > '/.*?(hello.*going).*/' or '[.*?(hello.*going).*]' the regular > > expression itself is merely ".*?(hello.*going).*" which matches the > > whole string and replaces it b

RE: [PHP] Please Help

2003-08-01 Thread Chris W. Parker
Jay Blanchard on Friday, August 01, 2003 8:54 AM said: > It's always funny how people think these kinds of posts are helpful. > [/snip] > > They're not? Yes, they are not. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net

RE: [PHP] Please Help

2003-08-01 Thread Jay Blanchard
[snip] John Manko on Thursday, July 31, 2003 11:26 PM said: > umm... ok. > > www.google.com > www.php.net > > that should get you started. It's always funny how people think these kinds of posts are helpful. [/snip] They're not? -- PHP General Mailing List (

RE: [PHP] Please Help

2003-08-01 Thread Chris W. Parker
John Manko on Thursday, July 31, 2003 11:26 PM said: > umm... ok. > > www.google.com > www.php.net > > that should get you started. It's always funny how people think these kinds of posts are helpful. c. -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Using eregi_replace()

2003-08-01 Thread skate
> > you could also use different delimiters and write for example: > '/.*?(hello.*going).*/' or '[.*?(hello.*going).*]' the regular > expression itself is merely ".*?(hello.*going).*" which matches the > whole string and replaces it by the first matching expression > sourrounded in by ()s (thats th

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 11:36:29AM -0400, Anthony Ritter wrote: > However, this works using: > preg_replace() > > . > > $text="blah blah blah hello I must be going blah blah"; > $newtext= preg_replace("!.*?(hello.*going).*!","$1",$text); > echo $newtext; > ?> > ..

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Curt Zirzow
* Thus wrote Chris Shiflett ([EMAIL PROTECTED]): > --- Curt Zirzow <[EMAIL PROTECTED]> wrote: > > Since print_r is usually used for debugging, it would be nice that > > php does this for you. Any comments on this before i throw the > > idea to the php-dev list? > > As of 4.3.0, you can store the o

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Curt Zirzow
* Thus wrote skate ([EMAIL PROTECTED]): > > Since print_r is usually used for debugging, it would be nice that > > php does this for you. Any comments on this before i throw the > > idea to the php-dev list? > > > > if it's just used for debugging, can't you just use the tags around > it? i mean

Re: [PHP] Using eregi_replace()

2003-08-01 Thread Anthony Ritter
However, this works using: preg_replace() . Thank you all. Is there a way I can be sure of the syntax? "!.*?(hello.*going).*!", // the pattern which - I think - reads as follows: !.*? // do not use any character or characters before the grouping of hello

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 05:13:05PM +0200, Marek Kilimajer wrote: > And besides ereg_replace would not work becase it's greedy, .* would > match "going", than "going" would not be found and the whole match would > fail. nope, it would backtrace then. but the first .* ist greedy so it would match

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Chris Shiflett
--- Curt Zirzow <[EMAIL PROTECTED]> wrote: > Since print_r is usually used for debugging, it would be nice that > php does this for you. Any comments on this before i throw the > idea to the php-dev list? As of 4.3.0, you can store the output of print_r() in a variable, so that allows developers t

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 11:25:07AM -0400, Anthony Ritter wrote: > Messju Mohr" <[EMAIL PROTECTED] writes: > > > you mean > > $newtext= ereg_replace(".*?(hello.*going).*","\\1",$text); > > ?? > .. > > Thank you but I get: > > Warning: REG_BADRPT: in c:\apache\htdoc

Re: [PHP] XmlRPC Extension in Apache 4.2.3

2003-08-01 Thread Marek Kilimajer
If I remember well this error is output even if the php_*.dll is found, but php fails to load it, possibly because of missing library/dll. Maybe xmlrpc.dll? Donald Tyler wrote: Hi Everyone, I posted this on the PHP install list but didn't get a reply. I hope you guys/gals can be more helpful.

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 03:13:53PM +, Curt Zirzow wrote: > * Thus wrote messju mohr ([EMAIL PROTECTED]): > > On Fri, Aug 01, 2003 at 10:33:50AM -0400, Anthony Ritter wrote: > > > > i would suggest preg_replace in favour to ereg_replace: > > $newtext= preg_replace("!.*?(hello.*going).*!","$1",$

Re: [PHP] Search Engine

2003-08-01 Thread Curt Zirzow
* Thus wrote Jay Blanchard ([EMAIL PROTECTED]): > > Google for "free search engine for web application". I always find it hard to search for the term 'free'. I'd like to see the day when you can do this in google: "free search engine for web application -ignore_stupid_sites" cheers, Curt --

Re: [PHP] Using eregi_replace()

2003-08-01 Thread Anthony Ritter
Messju Mohr" <[EMAIL PROTECTED] writes: > you mean > $newtext= ereg_replace(".*?(hello.*going).*","\\1",$text); > ?? .. Thank you but I get: Warning: REG_BADRPT: in c:\apache\htdocs\string.php on line 3 Using: . Regards, TR

Re: [PHP] Undefined variable problem

2003-08-01 Thread Curt Zirzow
* Thus wrote Ryan A ([EMAIL PROTECTED]): > > Notice: Undefined variable: email1 in c:\phpdev\www\bwh\project\compare.php > on line 117 > [...] > >$m = 1; >while ($line = mysql_fetch_assoc($rs)) { //dumping into an array > foreach ($line as $field => $value) { > $tmp = $field.$m;

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread skate
> Since print_r is usually used for debugging, it would be nice that > php does this for you. Any comments on this before i throw the > idea to the php-dev list? > if it's just used for debugging, can't you just use the tags around it? i mean, it's no big deal, and you don't really need it forma

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread Curt Zirzow
* Thus wrote Scott Fletcher ([EMAIL PROTECTED]): > Hi! > > I'm a little stuck with this simple math problem. I'm trying to get a > number of days in integer, not float. > > --snip-- >$input_date = "12/16/2002"; >$UserInput = explode("/", $input_date); > >$UserInputMonth = $UserI

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread Curt Zirzow
* Thus wrote Scott Fletcher ([EMAIL PROTECTED]): > The int() function is for C/C++ programming only. This Int() function is > not supported in PHP. In PHP it would be Intval(). For float, Floatval(). > For double, DoubleVal(). Etc. But beware of the Octual numbers. You can cast like you can

Re: [PHP] Using eregi_replace()

2003-08-01 Thread Marek Kilimajer
And besides ereg_replace would not work becase it's greedy, .* would match "going", than "going" would not be found and the whole match would fail. messju mohr wrote: you mean $newtext= ereg_replace(".*?(hello.*going).*","\\1",$text); ?? i would suggest preg_replace in favour to ereg_replace: $

[PHP] XmlRPC Extension in Apache 4.2.3

2003-08-01 Thread Donald Tyler
Hi Everyone, I posted this on the PHP install list but didn't get a reply. I hope you guys/gals can be more helpful. I am having trouble getting the XmlRpc extension working with PnP 4.2.3. SYSTEM: Windows XP Pro PHP 4.2.3 (Running as Apache module) Apache 2.0.44 When Apache starts I get the fo

Re: [PHP] Using eregi_replace()

2003-08-01 Thread Curt Zirzow
* Thus wrote messju mohr ([EMAIL PROTECTED]): > On Fri, Aug 01, 2003 at 10:33:50AM -0400, Anthony Ritter wrote: > > i would suggest preg_replace in favour to ereg_replace: > $newtext= preg_replace("!.*?(hello.*going).*!","$1",$text); Doesn't the $1 need to be escaped or in single quotes so php do

Re: [PHP] Trouble getting $HTTP_RAW_POST_DATA

2003-08-01 Thread Curt Zirzow
* Thus wrote Donald Tyler ([EMAIL PROTECTED]): > > Also, print_r() does not include any HTML formatting, so you will need to > look at the source for the page in the browser to make it readable. This is a problem I run into all the time, I am curious of how many people have run into this. I've b

Re: [PHP] Using eregi_replace()

2003-08-01 Thread messju mohr
On Fri, Aug 01, 2003 at 10:33:50AM -0400, Anthony Ritter wrote: > Using eregi_replace(), is there a way to take out a piece of a sentence - > which has spaces - and then return the new sentence? > > For example, to return the new sentence: > > hello I must be going > > from the original sentence

[PHP] Re: What is $$

2003-08-01 Thread DvDmanDT
Well, it's a variable that tells php what variable to use... so it's like if $var is "hello", then $$var is the same as $hello... -- // DvDmanDT MSN: [EMAIL PROTECTED] Mail: [EMAIL PROTECTED] "Ryan A" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > Hi, > I have just found this in

[PHP] Re: Search Engine

2003-08-01 Thread DvDmanDT
I use to write my own search engines... That way they get customized easier... You can write one that spiders like google... Hell, it even found my private server... And there's not a single link ther afaik.. Now, is it for web or site search? If site, just get a MySQL table with a longtext in it

[PHP] Using eregi_replace()

2003-08-01 Thread Anthony Ritter
Using eregi_replace(), is there a way to take out a piece of a sentence - which has spaces - and then return the new sentence? For example, to return the new sentence: hello I must be going from the original sentence: blah blah blah hello I must be going blah blah. I tried: ...

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread skate
> The int() function is for C/C++ programming only. This Int() function is > not supported in PHP. In PHP it would be Intval(). For float, Floatval(). > For double, DoubleVal(). Etc. But beware of the Octual numbers. > sorry, confusing my flash action script again :( -- PHP General Maili

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread Scott Fletcher
Gee! I forgot the '$'. It's been right there in my face. Thanks! I hope the round() function work without a problem because I saw in some posting that some people have this problem where if 3.51 is rounded, it return a 3. "Seth - Kate Buntin" <[EMAIL PROTECTED]> wrote in message news:[EMAIL P

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread Scott Fletcher
The int() function is for C/C++ programming only. This Int() function is not supported in PHP. In PHP it would be Intval(). For float, Floatval(). For double, DoubleVal(). Etc. But beware of the Octual numbers. "Skate" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > >$Day

RE: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread Buntin, Seth - KATE
I used your snip you just posted and changed the $Days = round(Days) to $Days = round($Days) and got 228. -Original Message- From: Scott Fletcher [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 9:18 AM To: [EMAIL PROTECTED] Subject: [PHP] Simple Math Calculation Problem Hi!

Re: [PHP] Simple Math Calculation Problem....

2003-08-01 Thread skate
>$Days = (($clockDate - $inputDate) / (24 * 3600)); $Days = int(($clockDate - $inputDate) / (24 * 3600)); you tried that? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Simple Math Calculation Problem....

2003-08-01 Thread Scott Fletcher
Hi! I'm a little stuck with this simple math problem. I'm trying to get a number of days in integer, not float. --snip-- $input_date = "12/16/2002"; $UserInput = explode("/", $input_date); $UserInputMonth = $UserInput[0]; $UserInputDay = $UserInput[1]; $UserInputYear = $UserI

Re: [PHP] Purging old files from directories

2003-08-01 Thread Verdon vaillancourt
Thank you :) On 8/1/03 10:06 AM, "Marek Kilimajer" <[EMAIL PROTECTED]> wrote: > Begin in the manual: > Directory functions > Filesystem functions - filemtime() -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Purging old files from directories

2003-08-01 Thread Jason Wong
On Friday 01 August 2003 21:40, Verdon vaillancourt wrote: > I need to write a script that will scan/read a given directory's contents > and delete files older than a certain date. Ideally, this will be a script > that runs via cron once a week and deletes all files it finds in the > directory old

  1   2   >