Re: [PHP] Re: Echo HTML code Verses breaking out of ?php ?

2003-11-25 Thread Curt Zirzow
* Thus wrote tkwright ([EMAIL PROTECTED]): Just warming the timer This Is HTML ### # Total Time: 0.000114 seconds # # Start Time: 1069732578.575586 seconds # # Ending Time: 1069732578.575700 seconds #

Re: [PHP] $ of variables, php, mysql

2003-11-25 Thread RT
On Tue, 2003-11-25 at 00:42, Joffrey Leevy wrote: Would appreciate in anyone can help me. Let's say I do a query in php, eg. $query = select shed from structure; With the mysql_fetch_array function and a loop I could see all the values stored in the column, shed, using the command: echo

Re: [PHP] $ of variables, php, mysql

2003-11-25 Thread Eugene Lee
On Mon, Nov 24, 2003 at 09:42:30PM -0800, Joffrey Leevy wrote: : : Would appreciate in anyone can help me. Some more code would be helpful. : Let's say I do a query in php, eg. $query = select : shed from structure; With the mysql_fetch_array : function and a loop I could see all the values

Re: [PHP] PHP with Java extension

2003-11-25 Thread Panos Konstantinidis
Hello options some of which ray has suggested. Others include soap or writing out objects using the XMLEncoder class (1.4+) and decoding them with a parser in your php. this is also a possible solution but the java system that does the processing is already written and tested, the

Fw: [PHP] Re: Excel Table download it

2003-11-25 Thread Larry_Li
header(Content-type: application/vnd.ms-excel); header(Content-Disposition: attachment; filename=report.xls); - Forwarded by Larry Li/APPLIED MATERIALS on 11/25/2003 03:40 PM - Phillip Jackson [EMAIL PROTECTED] 11/25/2003 02:30 PM To: [EMAIL PROTECTED] cc:

Re: [PHP] PRINT QUESTION

2003-11-25 Thread Burhan Khalid
Dale Hersh wrote: I know that in php there are a bunch of basic functions for opening a connection to a printer and then handling the printer queue and so forth. I would like to know how to take a string and echo that to the printer in php. The printer functions only work under Windows. From

Re: [PHP] PRINT QUESTION

2003-11-25 Thread Jyry Kuukkanen
On Tue, 25 Nov 2003, Burhan Khalid wrote: Dale Hersh wrote: I know that in php there are a bunch of basic functions for opening a connection to a printer and then handling the printer queue and so forth. I would like to know how to take a string and echo that to the printer in php. The

Re: [PHP] when to use \n in forms

2003-11-25 Thread Duncan Hill
On Monday 24 November 2003 04:02, Nigel Jones wrote: Not to offend anyone BUT What the is DHTML and JS (and VB for that matter) meant to do, we can use PHP instead who needs onLoad=Gimmethedampopups() - not me anyway i http://www.kryogenix.org/code/browser/sorttable/ is a neat bit of JS

Re: [PHP] $$vars and security

2003-11-25 Thread Chris Shiflett
--- Phillip Jackson [EMAIL PROTECTED] wrote: i have developed my own register globals function that mimics the action of register globals, but only for $_POST... i do this to ensure that all incoming communication is escaped for use in scripts to account for, and to avoid, SQL injection. So,

Re: [PHP] $$vars and security

2003-11-25 Thread Marek Kilimajer
Phillip Jackson wrote: function escape(){ while (list($key, $value) = each($_POST)) { $value = trim(mysql_escape_string($value)); global $$key; $$key = $value; } } 1. The function does not detect if magic_quotes_gpc are on, post vars would be double escaped then. 2. $value might be an

Re: [PHP] $$vars and security

2003-11-25 Thread Phillip Jackson
great point about the array; to make the script more portable i will most definitely detect magic quotes. Marek Kilimajer [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Phillip Jackson wrote: function escape(){ while (list($key, $value) = each($_POST)) { $value =

Re: [PHP] $$vars and security

2003-11-25 Thread Phillip Jackson
Personally, I think this is a bad approach, regardless of how well it is implemented. I think you will give yourself a false sense of security. what, then, do you yourself do in such an application requiring a response from the user to massage the data? reject all input that doesn't conform to

[PHP] Time

2003-11-25 Thread Fernando Melo
Hi there, I have a RH Linux Web server running apache and PHP. I recently changed the system clock, the time zone and hardware clock. The time and date are showing up correctly in Webmin and in the O/S itself. But when I call a php function to display the date and time it shows it as one hour

Re: [PHP] $ of variables, php, mysql

2003-11-25 Thread Marek Kilimajer
Eugene Lee wrote: Try using more variables to make life a little easier to parse: $colname = $_FORM['form'] $query = select {$colname} from structure; $result = mysql_query($query); while (($row = mysql_fetch_array($result)) !== false) {

RE: [PHP] Time

2003-11-25 Thread Wouter van Vliet
Fernando Melo wrote: Hi there, I have a RH Linux Web server running apache and PHP. I recently changed the system clock, the time zone and hardware clock. The time and date are showing up correctly in Webmin and in the O/S itself. But when I call a php function to display the date and

Re: [PHP] Date format question

2003-11-25 Thread Manisha Sathe
Thanks to all, it help me a lot manisha -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Locking mysql tables with PHP

2003-11-25 Thread Tony Crockford
Hi bit confused! here's what I want to do: get a numeric value from a MySQL table, do a calculation, then on another PHPpage update the numeric value in the table. what I don't want is anyone else getting the same number from the table before I've updated it. what PHP would you use to do

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Marek Kilimajer
Tony Crockford wrote: Hi bit confused! here's what I want to do: get a numeric value from a MySQL table, do a calculation, then on another PHPpage update the numeric value in the table. what I don't want is anyone else getting the same number from the table before I've updated it. what PHP

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Tony Crockford
On Tue, 25 Nov 2003 13:50:36 +0100, Marek Kilimajer [EMAIL PROTECTED] wrote: Tony Crockford wrote: get a numeric value from a MySQL table, do a calculation, then on another PHPpage update the numeric value in the table. what I don't want is anyone else getting the same number from the table

RE: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Jay Blanchard
[snip] is there a way I can get a number and increment it all in one query then? [/snip] UPDATE tblFoo SET value = (value+1) WHERE conditions -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Locking mysql tables with PHP

2003-11-25 Thread pete M
On way to do it would be to create a table called flags and update the value in that psuedo code update flags set locked =1 get value to calculate otheruesrs would check the page select locked from flags if NOT locked then do query on the update page update table set calculation = result update

[PHP] Re: Locking mysql tables with PHP

2003-11-25 Thread pete M
Another idea would ne to use an application variable.. This is like a Session variable but is site wide http://0x00.org/php/phpApplication/ regards Pete Tony Crockford wrote: Hi bit confused! here's what I want to do: get a numeric value from a MySQL table, do a calculation, then on

RE: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Jay Blanchard
[snip] is there a way I can get a number and increment it all in one query then? UPDATE tblFoo SET value = (value+1) WHERE conditions [/snip] OR (forgot the PHP part) $sqlUpdate = UPDATE tblFoo SET value = (value + $variable) WHERE conditions ; if(!($dbUpdate = mysql_query($sqlUpdate,

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Tony Crockford
On Tue, 25 Nov 2003 07:15:10 -0600, Jay Blanchard [EMAIL PROTECTED] wrote: [snip] is there a way I can get a number and increment it all in one query then? [/snip] UPDATE tblFoo SET value = (value+1) WHERE conditions Hmm.. my bad - I get that bit, but can I do: SELECT value WHERE conditions

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread pete M
UPDATE tblfoo SET value= (value+1) WHERE conditions Tony Crockford wrote: On Tue, 25 Nov 2003 07:15:10 -0600, Jay Blanchard [EMAIL PROTECTED] wrote: [snip] is there a way I can get a number and increment it all in one query then? [/snip] UPDATE tblFoo SET value = (value+1) WHERE conditions

RE: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Jay Blanchard
[snip] [snip] is there a way I can get a number and increment it all in one query then? [/snip] UPDATE tblFoo SET value = (value+1) WHERE conditions Hmm.. my bad - I get that bit, but can I do: SELECT value WHERE conditions UPDATE tblfoo SET value= (value+1) [/snip] Essentially that is

[PHP] Problems with a simple page

2003-11-25 Thread Carlos A. Rodriguez
Hi php-fans... here's a simple question for you I have this HTML page in WIN (Busqueda.htm) the page contains a textfield (textfield3) and a button (submit1) which calls a php file Buscador.php in a Linux server (RED HAT 8) well, my php file which doesn't read anything when I write this echo

RE: [PHP] Problems with a simple page

2003-11-25 Thread Jay Blanchard
[snip] Hi php-fans... here's a simple question for you I have this HTML page in WIN (Busqueda.htm) the page contains a textfield (textfield3) and a button (submit1) which calls a php file Buscador.php in a Linux server (RED HAT 8) well, my php file which doesn't read anything when I write this

Re: [PHP] Problems with a simple page

2003-11-25 Thread John Nichel
Carlos A. Rodriguez wrote: Hi php-fans... here's a simple question for you I have this HTML page in WIN (Busqueda.htm) the page contains a textfield (textfield3) and a button (submit1) which calls a php file Buscador.php in a Linux server (RED HAT 8) well, my php file which doesn't read

Re: [PHP] PHP with Java extension

2003-11-25 Thread Raditha Dissanayake
Hi, If i understand your project correctly all you need is for the php script to do some elementary processing and pass some parameters to a jsp or servlet. If so you do not need to delve too deeply into PHP at all and i am sure learning the few functions needed to achieve this is easier than

RE: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Jay Blanchard
[snip] is there a way I can get a number and increment it all in one query then? UPDATE tblFoo SET value = (value+1) WHERE conditions Hmm.. my bad - I get that bit, but can I do: SELECT value WHERE conditions UPDATE tblfoo SET value= (value+1) [/snip] I see where the confusion may be

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Tony Crockford
On Tue, 25 Nov 2003 07:47:58 -0600, Jay Blanchard [EMAIL PROTECTED] wrote: [snip] [snip] is there a way I can get a number and increment it all in one query then? [/snip] UPDATE tblFoo SET value = (value+1) WHERE conditions Hmm.. my bad - I get that bit, but can I do: SELECT value WHERE

[PHP] line breaks

2003-11-25 Thread Rodney Green
Greetings! I'm writing a script that will take the contents of a text file that has several lines of user accounts and creates a shell script with chown commands for each user in that text file. My problem is that when it writes the shell script file it puts a line break after the colon in

Re: [PHP] line breaks

2003-11-25 Thread John Nichel
Rodney Green wrote: Greetings! I'm writing a script that will take the contents of a text file that has several lines of user accounts and creates a shell script with chown commands for each user in that text file. My problem is that when it writes the shell script file it puts a line break

Re: [PHP] line breaks

2003-11-25 Thread Rodney Green
John Nichel wrote: Chances are, $buffer has the line break on it when you read it in from the text file. Try striping off whitespace before you write... while (!feof ($handle)) { $buffer = rtrim ( fgets($handle, 1000) ); fwrite ($fhandle, chown $buffer:html

[PHP] Time

2003-11-25 Thread Fernando Melo
Hi there, I have a RH Linux Web server running apache and PHP. I recently changed the system clock, the time zone and hardware clock. The time and date are showing up correctly in Webmin and in the O/S itself. But when I call a php function to display the date and time it shows it as one

RE: [PHP] Time

2003-11-25 Thread Fernando Melo
I have done all those checks. Thanks for trying though. Anyone else have any suggestions please? :( -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 25 November 2003 16:06 To: [EMAIL PROTECTED] Subject: AW: [PHP] Time Hi Fernando, first try date and date -u in

Re: [PHP] Problems with a simple page

2003-11-25 Thread Graham Solomon
Jay Blanchard wrote: [snip] Hi php-fans... here's a simple question for you I have this HTML page in WIN (Busqueda.htm) the page contains a textfield (textfield3) and a button (submit1) which calls a php file Buscador.php in a Linux server (RED HAT 8) well, my php file which doesn't read

Re: [PHP] line breaks

2003-11-25 Thread John Nichel
Rodney Green wrote: John Nichel wrote: Chances are, $buffer has the line break on it when you read it in from the text file. Try striping off whitespace before you write... while (!feof ($handle)) { $buffer = rtrim ( fgets($handle, 1000) ); fwrite ($fhandle, chown $buffer:html

Re: [PHP] line breaks

2003-11-25 Thread Rodney Green
John Nichel wrote: Rodney Green wrote: John Nichel wrote: Chances are, $buffer has the line break on it when you read it in from the text file. Try striping off whitespace before you write... while (!feof ($handle)) { $buffer = rtrim ( fgets($handle, 1000) ); fwrite ($fhandle,

Re: [PHP] $$vars and security

2003-11-25 Thread Chris Shiflett
--- Phillip Jackson [EMAIL PROTECTED] wrote: Personally, I think this is a bad approach, regardless of how well it is implemented. I think you will give yourself a false sense of security. what, then, do you yourself do in such an application requiring a response from the user to massage

Re: [PHP] $$vars and security

2003-11-25 Thread Marek Kilimajer
Chris Shiflett wrote: Yes, that's it. I know this may sound like a huge hassle compared to a nice one-size-fits-all data filtering function, but I personally would never rely on myself to be able to predict all of the different types of attacks that people will come up with. There are many people

RE: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Wouter van Vliet
Marek Kilimajer wrote: Tony Crockford wrote: Hi bit confused! here's what I want to do: get a numeric value from a MySQL table, do a calculation, then on another PHPpage update the numeric value in the table. what I don't want is anyone else getting the same number from the table

Re: [PHP] line breaks

2003-11-25 Thread John Nichel
Rodney Green wrote: snip Actually, I'm not having problems with that. The whitespace is still there in between the commands and arguments, etc. I'm using fgets , not fread. Not sure what the difference between the two is but I'll check it out. The problem I am having however is that at the end

Re: [PHP] line breaks

2003-11-25 Thread Rodney Green
John Nichel wrote: Rodney Green wrote: snip Actually, I'm not having problems with that. The whitespace is still there in between the commands and arguments, etc. I'm using fgets , not fread. Not sure what the difference between the two is but I'll check it out. The problem I am having however

Re: [PHP] Locking mysql tables with PHP

2003-11-25 Thread Marek Kilimajer
Wouter van Vliet wrote: I may be wrong here, but doesn't PHP let MySQL retain the locks when you've connected with the mysql_pconnect(); function? (persistent connect, I would expect locks to get released on a disconnect, which usually happens on a page refresh (new mysql_connect() call). That is

RE: [PHP] User/Pwd Management Package?

2003-11-25 Thread Thomas Svenson
Hi, I'm interesting in finding a PHP package that implements functions for managing user names passwords controlling access to specific parts of a site. Of course, free is best. But cheap is good. And, even not-so-cheap is fine, as long as it provides good functionality. Any pointers

[PHP] Windows Environment Variables

2003-11-25 Thread Rodney Green
Hello, Is PHP able to access and use Windows Environment Variables? If so, is there a function or a reference you can point me to? Thanks, Rod -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] apache 2.0.47 apache2filter PHP 4.3.4 solaris linux

2003-11-25 Thread Daniel Sand
hi PHP folks, i have a slight problem on PHP 4.3.4 and apache2filters If i compile the apache2filter support into php all runs through an the module works. BUT ( hehe. this is what i get mad about ^_^ ) You cann put all kind of content in and any php code that is found is getting parsed. BUT

[PHP] PHP SESSION DURATION.....

2003-11-25 Thread Keith
Hi, How do I go about making a session last longer that the duration of the browser? Say I wanted to make a session last for 1 month, so that I could close the browser as often I wanted, and the session would still be there. I found the explanations of the session function on PHP.net quite

[PHP] Re: PHP SESSION DURATION.....

2003-11-25 Thread Keith
Correction: I meant to say: Are session variables stored server-side or client-side like cookies? Keith [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, How do I go about making a session last longer that the duration of the browser? Say I wanted to make a session last for 1

[PHP] Add Reply-To to this list(s)

2003-11-25 Thread Thomas Svenson
Hi, It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the author. Less hassle for me when replying and less risk of

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread David T-G
Thomas -- ...and then Thomas Svenson said... % % Hi, Hi! % % It would be nice if the moderator of this, and the other PHP-lists could fix % so the listserver automatically add a Reply-To header to all the mails. No it wouldn't. It would be a Bad Thing. This was just beaten to death

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Sophie Mattoug
And mly opinion is it's _really_ _very_ useful (I just sent my message to someone instead of the list! Gr Annoying!) Sophie Mattoug wrote: It's the way we do on [EMAIL PROTECTED], and everything is fine ! David T-G wrote: Thomas -- ...and then Thomas Svenson said... % % Hi, Hi! % %

Re: [PHP] Re: PHP SESSION DURATION.....

2003-11-25 Thread Larry E. Ullman
Correction: I meant to say: Are session variables stored server-side or client-side like cookies? The session data is stored on the server. The session cookie (if there is one) is stored in the browser. How do I go about making a session last longer that the duration of the browser? Set the

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Chris Garaffa
On Nov 25, 2003, at 11:57 AM, Thomas Svenson wrote: Hi, It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the

RE: [PHP] Time

2003-11-25 Thread Fernando Melo
Hi, I found the problem. If you change the time zone on your Linux server running Apache and PHP, you need to Stop and then Start Apache else the PHP (or Apache) will still pick up the old time zone. Thanks anyway -Original Message- From: Wouter van Vliet [mailto:[EMAIL PROTECTED]

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Chris Shiflett
--- Thomas Svenson [EMAIL PROTECTED] wrote: It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the author. Less

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Marek Kilimajer
David T-G wrote: % % When I hit Reply my message would then automatically reply to the list and % not the author. Less hassle for me when replying and less risk of forgetting % it. Much better for you to Do It Right, perhaps including changing to a real mail program. See the archives for the

[PHP] Re: Securing PHP code..

2003-11-25 Thread Peter Clarke
Video Populares Et Optimates wrote: Hi! I'm pondering on a problem here. Being a C/C++, Java and Visual Basic developer, the aspect of reverse engineering code from (compiled) programs, hasn't occupied my mind that much. Now, developing PHP scripts on large scale I have started to think

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread David T-G
Sophie - ...and then Sophie Mattoug said... % % And mly opinion is it's _really_ _very_ useful (I just sent my message % to someone instead of the list! Gr Annoying!) Since it was apparently intended for the list, I'll reply to all what I sent to you: Just because it's done badly

[PHP] extensions

2003-11-25 Thread Alex Hunsley
I wish to access native functionality in a native library from php. I believe writing a php extension is the way to go about it. (The lib I want to access is sufficiently complex that doing a system call to execute it isn't a viable solution) Can anyone point me to some useful guide? I've found

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Duncan Hill
Thomas Svenson said: Hi, It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the author. Less hassle for me when

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Dan Joseph
Hi, Much better to just switch to a mail client that understands the list headers in the mail, and supports reply to list. KMail (KDE) and Squirrelmail (web) are two that spring to mind. The only problem with that is not everyone has an option to switch clients. However, I think

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread David T-G
Dan, et al -- ...and then Dan Joseph said... % % Hi, Hiya! % % Much better to just switch to a mail client that understands the ... % % The only problem with that is not everyone has an option to switch clients. Yes, but that subset is very, very small. There is almost always a

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Dave G
This is, I suppose, a completely off topic thread. However, I just read the web page http://www.unicom.com/pw/reply-to-harmful.html and I was completely unconvinced. In all the years that I have belonged to and run mailing lists, I have never experienced any difficulties. Period. Never. It has

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Gabriel Guzman
On Tuesday 25 November 2003 09:51 am, Dave G wrote: snip Telling people that they need to use proper email software and go about things in the way they don't expect which they are you refering to? i expect my reply button to reply to the person who sent the initial message... not everyone

[PHP] Windows PHP permissions question

2003-11-25 Thread Robin Kopetzky
Good Morning/Afternoon. I have a program that is trying to write to a directory on a Windows server and I don't know how to setup the permissions to read/write/delete just from this directory. I have it permissions set to 'Everyone' but that doesn't work. Help?!?! Robin 'Sparky' Kopetzky Black

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread David T-G
Dave, et al -- ...and then Dave G said... % % This is, I suppose, a completely off topic thread. However, I just It sure is. And this has come up many times before. It's all in the archives. The only reason I bother to answer when the problem rears its head again is to fight, tooth and

[PHP] Object aggregation/composition - Experimental..?

2003-11-25 Thread Video Populares et Optimates
Hi! I'm sifting through the possibilities with PHP and naturally one of the first things I searched for was the possibility for OO development. Now, I found chapter LXXII in the PHP manual (file generated Sun Oct 05 02:13:52 2003), but it has quite an ugly warning clause in the top: Warning

[PHP] Intuitive Interfaces (was: Add Reply-To to this list(s))

2003-11-25 Thread Chris Shiflett
--- Dave G [EMAIL PROTECTED] wrote: If the over whelming majority of people expect a system to behave one way, that's not evidence that they are brain dead, but that it's very likely the expected behaviour is more natural for people, and systems should match humans, not vice versa. I will try

Re: [PHP] Intuitive Interfaces

2003-11-25 Thread Cesar Cordovez
Chris Shiflett wrote: Some Web sites I have visited think it is helpful to use some client-side scripting to move the focus from the first text field to the second after three numbers have been entered. So, when the user hits tab after entering the first three numbers, the second text field is

Re: [PHP] Passing vars w/refresh w/register globals off?

2003-11-25 Thread Kim Steinhaug
Well first off all it is possible to post and get at the same time. Dont know why you want to, but its kinda easy really : Example : form name=myform action=myscript.php?get1=aget2=b method=post input type=hidden name=jalla value=balla /form You can submit this form several ways, with ordinary

[PHP] Re: Change Date

2003-11-25 Thread Kim Steinhaug
Is it me or are everyone responding how to give a the date in here? The timestamp is still time() and not date() isnt it? Timestamp works in seconds, so 1 hour is : 60 seconds * 60 minutes. $hour = 60*60; $day = 24*$hour; timestamp for 125 days into the future would then be,

[PHP] Re: Detecting Server API (CGI or Apache) at runtime?

2003-11-25 Thread Richard Cyganiak
Richard Cyganiak [EMAIL PROTECTED] schrieb im Newsbeitrag news:[EMAIL PROTECTED] is there a way to tell at runtime if PHP is running as an Apache module or through CGI? Replying to myself ... I found the answer, there's a function php_sapi_name() for this purpose, see

RE: [PHP] Intuitive Interfaces

2003-11-25 Thread Johnson, Kirk
Cesar Cordovez wrote: Chris Shiflett wrote: Some Web sites I have visited think it is helpful to use some client-side scripting to move the focus from the first text field to the second after three numbers have been entered. I think this is the worst thing to do. If they are going to this

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread RT
On Tue, 2003-11-25 at 11:57, Thomas Svenson wrote: Hi, It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the

[PHP] Regular expression help

2003-11-25 Thread Ben
I need someone to tell me exactly what this regular-expression means: if(ereg([^ \t\n],$val)) { // do the job here } I'm looking for an intermittent bug, and I need to understand this to make sure I have found the bug. Thanks -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Intuitive Interfaces

2003-11-25 Thread RT
On Tue, 2003-11-25 at 13:50, Chris Shiflett wrote: [snip] Some Web sites I have visited think it is helpful to use some client-side scripting to move the focus from the first text field to the second after three numbers have been entered. So, when the user hits tab after entering the first

RE: [PHP] Regular expression help

2003-11-25 Thread Bronislav Kluka
This condition is true if there is no space, new line or tabulator in $val I need someone to tell me exactly what this regular-expression means: if(ereg([^ \t\n],$val)) { // do the job here } I'm looking for an intermittent bug, and I need to understand this to make sure I have found

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Eugene Lee
On Tue, Nov 25, 2003 at 04:57:41PM -, Thomas Svenson wrote: : : It would be nice if the moderator of this, and the other PHP-lists : could fix so the listserver automatically add a Reply-To header to all : the mails. : : When I hit Reply my message would then automatically reply to the list

Re: [PHP] $ of variables, php, mysql

2003-11-25 Thread Eugene Lee
On Tue, Nov 25, 2003 at 11:38:27AM +0100, Marek Kilimajer wrote: : Eugene Lee wrote: : : Try using more variables to make life a little easier to parse: : : $colname = $_FORM['form'] : $query = select {$colname} from structure; : $result = mysql_query($query); : while

[PHP] array problems

2003-11-25 Thread Curtis Maurand
Hello, consider the following code (content.txt is tab delimited). $city = Ipswitch; $content = fopen(content.txt, r); $city_found = 0; while (!feof($content) $city_found == 0) { $my_line = fgets($content, r); $content_array = explode(\t,$my_line); if ($content_array == $city)

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Chris W. Parker
Eugene Lee mailto:[EMAIL PROTECTED] on Tuesday, November 25, 2003 12:47 PM said: If you would stop using M$ Outlook and switch to a better mail client that supports mailing lists, your problem would be solved. The problem with your theory is that some of us are in corporate environments

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Glenn E. Sieb
From: Eugene Lee [mailto:[EMAIL PROTECTED] If you would stop using M$ Outlook and switch to a better mail client that supports mailing lists, your problem would be solved. Amusing--I've used Eudora.. I've used Mozilla.. I've used Netscape.. I don't see that behaviour in any of those. So,

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Cesar Cordovez
I had the same problem here until, I installed Netscape to handle my personal mail (this list). Works great! Chris: Why don't you give it a try? Chris W. Parker wrote: The problem with your theory is that some of us are in corporate environments where personal email is not allowed and

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Eugene Lee
On Wed, Nov 26, 2003 at 02:51:58AM +0900, Dave G wrote: : : Telling people that they need to use proper email software and go : about things in the way they don't expect is not a path to sensible : human interfaces. Computers, machines, systems, should match us, not : us to them. In any case,

Re: [PHP] $ of variables, php, mysql

2003-11-25 Thread Joffrey Leevy
Hey thanks guys. Problem solved. --- Eugene Lee [EMAIL PROTECTED] wrote: On Tue, Nov 25, 2003 at 11:38:27AM +0100, Marek Kilimajer wrote: : Eugene Lee wrote: : : Try using more variables to make life a little easier to parse: : :$colname = $_FORM['form'] :$query = select

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Jay Blanchard
[snip] If you would stop using M$ Outlook and switch to a better mail client that supports mailing lists, your problem would be solved. [/snip] As has been said several times, not all can do this. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Curt Zirzow
* Thus wrote Thomas Svenson ([EMAIL PROTECTED]): Hi, It would be nice if the moderator of this, and the other PHP-lists could fix so the listserver automatically add a Reply-To header to all the mails. When I hit Reply my message would then automatically reply to the list and not the

Re: [PHP] Regular expression help

2003-11-25 Thread Ben
Thanks Bronislav for your answer but this can't be it as the following test code passes validation: ?Php $val = \t test \n; if(ereg([^ \t\n],$val)) { echo 'In here!!'; } echo 'BR' . nl2br($val); ? Anyone has an idea? Bronislav kluèka [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Roger B.A. Klorese
This is simply impossible. This list is propagated to places other than the mailing list (ie. news.php.net) So? What negative impact would a Reply-To: header have on a newsgroup? It doesn't affect followups... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Regular expression help

2003-11-25 Thread Matthias Nothhaft
Hi, ^ inside [] means not the following chars, so your expression means: if ($val contains no space , no tab \t and no newline \n) { //do the job ... } Regards, Matthias Ben wrote: I need someone to tell me exactly what this regular-expression means: if(ereg([^ \t\n],$val)) { //

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Comex
[EMAIL PROTECTED] Dave G: This is, I suppose, a completely off topic thread. However, I just read the web page http://www.unicom.com/pw/reply-to-harmful.html and I was completely unconvinced. Yes, I do use OE which is completely broken. And no I don't have to. Oh well. I still agree with

Re: [PHP] Regular expression help

2003-11-25 Thread CPT John W. Holmes
From: Bronislav Kluka [EMAIL PROTECTED] I need someone to tell me exactly what this regular-expression means: if(ereg([^ \t\n],$val)) { // do the job here This condition is true if there is no space, new line or tabulator in $val Actually, the regular expression will match anything

Re: [PHP] array problems

2003-11-25 Thread Eugene Lee
On Tue, Nov 25, 2003 at 03:45:11PM -0500, Curtis Maurand wrote: : : Hello, : consider the following code (content.txt is tab delimited). : : $city = Ipswitch; : $content = fopen(content.txt, r); : $city_found = 0; : while (!feof($content) $city_found == 0) : { : $my_line =

Re: [PHP] Regular expression help

2003-11-25 Thread Ben
That's it! Thank you very much, you have the answer. I wonder why the programmer did not write the following line instead: if (strlen(trim($val))) { // Do the job here } Anyways, you just proved that I did not fix the bug! Now I have to work even more! :-P Thanks Matthias Nothhaft [EMAIL

[PHP] Blessing an object

2003-11-25 Thread Wouter van Vliet
Hi Folks I was wondering (mostly because I came across some situations where I need it) if PHP supplies any methods to bless an array or object to become some other object. In perl, I can simply do: my $SomeInstance = bless { item = 'value', 'Item2' = 'value2' }, 'SomeObject'; And then

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Thomas Svenson
It Adds Nothing is absolutely false. Being able to automatically respond to the list adds more naturally expected behaviour. I remain steadfast in my opinion that automatically replying to the list is a much more natural option. My opinion is that this is a multi person discussion forum,

RE: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Thomas Svenson
If you would stop using M$ Outlook and switch to a better mail client that supports mailing lists, your problem would be solved. I wouldn't mind that at all. What clients do you recommend for WindwosXP? I want a small client (note: I have to use Outlook for business purposes, but have the lists

  1   2   >