[PHP] How to show proper time to users from around the world

2007-08-29 Thread Hemanth
Hi friends, Is there a solution to showing the proper time and date at user browsers and also recording proper USER times in the database operations in mysql Hemanth -- www.ValueAds.bizso easy FREE India Classifieds Jobs, Matrimony, Property and more A Bangalore, India Venture.

Re: [PHP] How to show proper time to users from around the world

2007-08-29 Thread mike
On 8/29/07, Hemanth <[EMAIL PROTECTED]> wrote: > Hi friends, > > Is there a solution to showing the proper time and date at user > browsers > and also recording proper USER times in the database operations in > mysql if you have the opportunity to have them input the time, you can then use putenv

[PHP] Socket takes a long time to 'finish'

2007-08-29 Thread Alvar Saenz-Otero
Hello, I have a small but somewhat annoying issue. Whenever I open a socket to another server, the file is read very quickly, but it takes the up to 30 seconds or so to close the connection... Here is what I do: $sever = "server.mit.edu"; $url = "/link"; $port = 80; $user_agent = $_SE

[PHP] How to run and terminate C++ program(*.exe) with PHP?

2007-08-29 Thread Aram Shatakhtsyan
How to run C++ program(*.exe) with PHP, and then terminate it. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Socket takes a long time to 'finish'

2007-08-29 Thread Eddie Dunckley
On Wed 29 Aug 07, Alvar Saenz-Otero wrote: > Hello, > I have a small but somewhat annoying issue. > Whenever I open a socket to another server, the file is read very > quickly, but it takes the up to 30 seconds or so to close the > connection... > > Here is what I do: >$sever = "server.mit.edu"

[PHP] Heredocs

2007-08-29 Thread RodgerW
Are heredocs supported by PP 5.2.3 running in WinXP/Apache2.2.4 ? I prrint via heredocs and its not working. Print with single quotes and double quotes work. string init method 3: heredocs -- PHP General Mailing List (http://ww

[PHP] Heredocs

2007-08-29 Thread RodgerW
Are heredocs supported by PHP 5.2.3 running in WinXP/Apache2.2.4 ? I prrint via heredocs and its not working. Print with single quotes and double quotes work. string init method 3: heredocs -- PHP General Mailing List (http://w

Re: [PHP] How to run and terminate C++ program(*.exe) with PHP?

2007-08-29 Thread shiplu
On 8/29/07, Aram Shatakhtsyan <[EMAIL PROTECTED]> wrote: > > How to run C++ program(*.exe) with PHP, and then terminate it. > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > PHP can do anything. But the matter is where the host permits

RE: [PHP] Trying to understand sessions and using them to authenticate...

2007-08-29 Thread Ford, Mike
On 28 August 2007 15:56, Stut wrote: > Jason Pruim wrote: > > One other question, to logout, can I just call a file that has > > session_destroy() and a header("Location: ???"); in it? Or should I > > do something else for logging out? > > foreach (array_keys($_SESSION) as $key) > unset($_SE

Re: [PHP] Heredocs

2007-08-29 Thread Aaron Gould
RodgerW wrote: Are heredocs supported by PHP 5.2.3 running in WinXP/Apache2.2.4 ? I prrint via heredocs and its not working. Print with single quotes and double quotes work. string init method 3: heredocs END; ?> It works here

RE: [PHP] Heredocs

2007-08-29 Thread Jay Blanchard
[snip] Are heredocs supported by PP 5.2.3 running in WinXP/Apache2.2.4 ? I prrint via heredocs and its not working. Print with single quotes and double quotes work. string init method 3: heredocs The closing identifier must begin

RE: [PHP] Heredocs

2007-08-29 Thread Edward Kay
> Are heredocs supported by PP 5.2.3 running in WinXP/Apache2.2.4 ? > I prrint via heredocs and its not working. Print with single quotes and > double quotes work. > > > string init method 3: heredocs > print <<< END >

Re: [PHP] Heredocs

2007-08-29 Thread Thijs Lensselink
On Wed, 29 Aug 2007 13:01:07 +0200, RodgerW <[EMAIL PROTECTED]> wrote: > Are heredocs supported by PHP 5.2.3 running in WinXP/Apache2.2.4 ? > I prrint via heredocs and its not working. Print with single quotes and > double quotes work. > > > string init method 3: hered

Re: [PHP] Trying to understand sessions and using them to authenticate...

2007-08-29 Thread Richard Heyes
Ford, Mike wrote: > On 28 August 2007 15:56, Stut wrote: > >> Jason Pruim wrote: >>> One other question, to logout, can I just call a file that has >>> session_destroy() and a header("Location: ???"); in it? Or should I >>> do something else for logging out? >> foreach (array_keys($_SESSION) as $k

Re: [PHP] Socket takes a long time to 'finish'

2007-08-29 Thread Alvar Saenz-Otero
Thank you! Either of the two options fixed it! My guess is that HTTP 1.0 does not need the "Connection: close" while HTTP 1.1 does. So I had to fix one of the two... I did both, just so that my script has better compatibility in the future. Thanks again, Alvar At 06:59 2007/08/29, Eddie

[PHP] Round

2007-08-29 Thread Koen van den Boogaart
Is it expected behaviour that outputs float(-0) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Round

2007-08-29 Thread Richard Heyes
Koen van den Boogaart wrote: Is it expected behaviour that outputs float(-0) Yes. You (probably) want: http://uk.php.net/manual/en/function.round.php -- Richard Heyes +44 (0)844 801 1072 http://www.websupportsolutions.co.uk Knowledge Base and HelpDesk software that can cut the cost o

RE: [PHP] Regular expression - URL validator

2007-08-29 Thread Wagner Garcia Campagner
Thanks again Jim, That's what i really need. I'm testing this function... If i put a URL like www.example.com, then it works fine and turns it to http://www.example.com But if i put a URL like http://www.example.com, then it also put another header so it turns to http://http://www.example.com

[PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
I've been having problems with Internet Explorer caching php programs. I'm using the following code: header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 header("Pragma", "no-cache"); header("Expires", "-1"); And it used to work, but now, according to Windows Ex

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Richard Heyes
Charlene wrote: I've been having problems with Internet Explorer caching php programs. I'm using the following code: header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 header("Pragma", "no-cache"); header("Expires", "-1"); And it used to work, but now, accord

Re: [PHP] Round

2007-08-29 Thread Koen van den Boogaart
No, I want it to go to float(0), so minus the minus. "-0" doesn't exist in math, as far as I know. Probably a precision thing. "Richard Heyes" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Koen van den Boogaart wrote: >> Is it expected behaviour that >> >> >> >> outputs >> >> fl

Re: [PHP] Regular expression - URL validator

2007-08-29 Thread Jim Lucas
Wagner Garcia Campagner wrote: Thanks again Jim, That's what i really need. I'm testing this function... If i put a URL like www.example.com, then it works fine and turns it to http://www.example.com But if i put a URL like http://www.example.com, then it also put another header so it turns t

Re: [PHP] Round

2007-08-29 Thread Jim Lucas
Koen van den Boogaart wrote: Is it expected behaviour that outputs float(-0) What version of PHP are you running. I'm running 5.1.6 and I get float(0) -- Jim Lucas "Some men are born to greatness, some achieve greatness, and some have greatness thrust upon them." Twelfth Nigh

Re: [PHP] Round

2007-08-29 Thread Richard Heyes
Koen van den Boogaart wrote: No, I want it to go to float(0), so minus the minus. "-0" doesn't exist in math, as far as I know. Probably a precision thing. Ok, then try abs() first then. -- Richard Heyes +44 (0)844 801 1072 http://www.websupportsolutions.co.uk Knowledge Base and HelpDesk soft

Re: [PHP] Round

2007-08-29 Thread Daniel Brown
On 8/29/07, Richard Heyes <[EMAIL PROTECTED]> wrote: > Koen van den Boogaart wrote: > > No, I want it to go to float(0), so minus the minus. "-0" doesn't exist in > > math, as far as I know. Probably a precision thing. > > Ok, then try abs() first then. > > -- > Richard Heyes > +44 (0)844 801 1072

Re: [PHP] Round

2007-08-29 Thread Jim Lucas
Daniel Brown wrote: On 8/29/07, Richard Heyes <[EMAIL PROTECTED]> wrote: Koen van den Boogaart wrote: No, I want it to go to float(0), so minus the minus. "-0" doesn't exist in math, as far as I know. Probably a precision thing. Ok, then try abs() first then. -- Richard Heyes +44 (0)844 801 1

Re: [PHP] Round

2007-08-29 Thread Richard Heyes
What if I expected -1 for the last answer? Then only use abs() if the result from round() is zero; -- Richard Heyes +44 (0)844 801 1072 http://www.websupportsolutions.co.uk Knowledge Base and HelpDesk software that can cut the cost of online support -- PHP General Mailing List (http://www.php

Re: [PHP] Round

2007-08-29 Thread Zoltán Németh
2007. 08. 29, szerda keltezéssel 09.29-kor Jim Lucas ezt írta: > Daniel Brown wrote: > > On 8/29/07, Richard Heyes <[EMAIL PROTECTED]> wrote: > >> Koen van den Boogaart wrote: > >>> No, I want it to go to float(0), so minus the minus. "-0" doesn't exist in > >>> math, as far as I know. Probably a p

Re: [PHP] Round

2007-08-29 Thread Daniel Brown
On 8/29/07, Zoltán Németh <[EMAIL PROTECTED]> wrote: > > Think this through before you respond... > > > > Try this > > > > > var_dump( round(-0.26) ); > > var_dump( abs( round(-0.26) ) ); > > var_dump( round(-1.26) ); > > var_dump( abs( round(-1.26) ) ); > > ?> > > > > does this give you the desir

Re: [PHP] Round

2007-08-29 Thread Jim Lucas
Daniel Brown wrote: On 8/29/07, Zoltán Németh <[EMAIL PROTECTED]> wrote: Think this through before you respond... Try this does this give you the desired results? What if I expected -1 for the last answer? It didn't take much thinking this time if you were expecting -1 for the las

[PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jason Pruim
Hi Everyone, I think after I get this question answered, I can stop asking for awhile since my project will be done, at least until the users say "What happened to XYZ" then I'll ask again :) I asked on a MySQL list about "Resetting a auto increment filed" so that there arn't any gaps

RE: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jay Blanchard
[snip] Is there away with PHP that I can pragmatically change that value to the total records in the database more so then a representation of the actual record number? [/snip] 1. Changing the values in an auto-increment column is just Bad[tm], especially if you are using it as a unique index

Re: [PHP] Round

2007-08-29 Thread Koen van den Boogaart
I'm running 5.2.3. Reaction on above discussion: of course this problem can be solved with all sorts of solutions, but my question is: is it good that a function returns a number that doesn't exist? I once posted a bug report about a wrong round()-result, though it wasn't a bug, but a consequenc

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jason Pruim
On Aug 29, 2007, at 1:58 PM, Jay Blanchard wrote: [snip] Is there away with PHP that I can pragmatically change that value to the total records in the database more so then a representation of the actual record number? [/snip] 1. Changing the values in an auto-increment column is just Bad[tm]

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Satyam
I'm sending these headers: header('Cache-Control: no-cache, must-revalidate'); // HTTP/1.1 header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past I don't remember where I took them from, but they are working fine for me. Satyam - Original Message - From: "R

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Nate
that's from php.net... " PHP scripts often generate dynamic content that must not be cached by the client browser or any proxy caches between the server and the client browser. Many proxies and clients can be forced to disable caching with: Note: You may find that your pages aren't cached eve

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jim Lucas
Jason Pruim wrote: 3. Ask yourself, "Is it important to keep the auto-increment field contiguous?" The main reason for changing it is I do currently have an option to sort by record number, although, if I add a Record number in php, but still have it sort based off of the record number stored

RE: [PHP] Round

2007-08-29 Thread PHP-Gen
I believe there is some confusion on what ABS actually does. Ignoring all the rounding that you are trying to do ABS is a very simple function. ABS definition: Returns the absolute value of number. What that means is. Abs(1) = 1 Abs(2) = 2 Abs(3) = 3 Abs(0) = 0 Abs(-1) = 1 Abs(-2) = 2 Abs(-3) =

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Stephen
--- Jason Pruim <[EMAIL PROTECTED]> wrote: > So to say it another way, I have a table that has > 900 records in it, > I've added 3 records, but then deleted 2 of those > which puts the > actual record count at 901 but my auto increment > field starts at 904 > on the next insert. > > Is ther

Re: [PHP] Round

2007-08-29 Thread Jim Lucas
PHP-Gen wrote: I believe there is some confusion on what ABS actually does. Ignoring all the rounding that you are trying to do ABS is a very simple function. ABS definition: Returns the absolute value of number. What that means is. Abs(1) = 1 Abs(2) = 2 Abs(3) = 3 Abs(0) = 0 Abs(-1) = 1 Abs(

Re: [PHP] Round

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 11:38 am, Zoltán Németh wrote: > 2007. 08. 29, szerda keltezéssel 09.29-kor Jim Lucas ezt írta: >> Daniel Brown wrote: >> > On 8/29/07, Richard Heyes <[EMAIL PROTECTED]> wrote: >> >> Koen van den Boogaart wrote: >> >>> No, I want it to go to float(0), so minus the minus. "

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread brian
Jason Pruim wrote: Hi Everyone, I think after I get this question answered, I can stop asking for awhile since my project will be done, at least until the users say "What happened to XYZ" then I'll ask again :) I asked on a MySQL list about "Resetting a auto increment filed" so that

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread James Ausmus
On 8/29/07, Stephen <[EMAIL PROTECTED]> wrote: > --- Jason Pruim <[EMAIL PROTECTED]> wrote: > > > So to say it another way, I have a table that has > > 900 records in it, > > I've added 3 records, but then deleted 2 of those > > which puts the > > actual record count at 901 but my auto increment >

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 10:43 am, Charlene wrote: > I've been having problems with Internet Explorer caching php programs. > I'm using the following code: > > header("Cache-Control: no-cache, must-revalidate"); // > HTTP/1.1 > header("Pragma", "no-cache"); > header("Expires"

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
Yes, I'm sure. Changes I make to a database are reflected in the database but not on the form. It's only IE. It works fine in FireFox or SeaMonkey. Charlene Richard Heyes wrote: Charlene wrote: I've been having problems with Internet Explorer caching php programs. I'm using the following

[PHP] Perhaps an incomplete $_POST

2007-08-29 Thread Jay Blanchard
I just noticed something a little odd, and maybe there is a simple solution. Given a form; The attributes, especially the name "foo", never appear in any variables array. I am thinking that this might be handy to have for several reasons when processing the form. I have several reasons for needi

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 12:49 pm, Jason Pruim wrote: > I think after I get this question answered, I can stop asking for > awhile since my project will be done, at least until the users say > "What happened to XYZ" then I'll ask again :) > > I asked on a MySQL list about "Resetting a auto incre

[PHP] PhP / MySQL problem

2007-08-29 Thread debussy007
Hi, I created a form asking username, password, country, etc. On the submit of this form I make a sql connection and update the database, add the user. The problem is that whenever the field 'password' is filled in, "it" (I don't know what) is asking to confirm the change of the password. I mad

[PHP] CAN'T GET OUT OF THIS LIST

2007-08-29 Thread Dave Howard Schiff
Please someone remove me! I can't get out! ___ Yahoo! Mail - Sempre a melhor opção para você! Experimente já e veja as novidades. http://br.yahoo.com/mailbeta/tudonovo/ -- PHP General Mailing List (http:

Re: [PHP] Heredocs

2007-08-29 Thread Richard Lynch
I don't think you can have a space between the <<< and the 'END' bit... On Wed, August 29, 2007 6:00 am, RodgerW wrote: > Are heredocs supported by PP 5.2.3 running in WinXP/Apache2.2.4 ? > I prrint via heredocs and its not working. Print with single quotes > and > double quotes work. > >

Re: [PHP] How to run and terminate C++ program(*.exe) with PHP?

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 4:05 am, Aram Shatakhtsyan wrote: > How to run C++ program(*.exe) with PHP, and then terminate it. http://php.net/exec -- Please vote for this great band: http://acl.mp3.com/feature/soundandjury/?band=COMPANY-OF-THIEVES Requires email confirmation. One vote per day per e

Re: [PHP] Socket takes a long time to 'finish'

2007-08-29 Thread Richard Lynch
Try just leaving out the fclose($socket) and let PHP close it at the end for you... It's probably not IDEAL, but it may at least get you moving forward with other bigger issues. Check the http://bugs.php.net/ bugs as well -- Might be something in there of use. There will be a few zillion bogus o

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jason Pruim
On Aug 29, 2007, at 3:02 PM, Richard Lynch wrote: On Wed, August 29, 2007 12:49 pm, Jason Pruim wrote: I think after I get this question answered, I can stop asking for awhile since my project will be done, at least until the users say "What happened to XYZ" then I'll ask again :) I asked

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jason Pruim
On Aug 29, 2007, at 2:41 PM, Stephen wrote: --- Jason Pruim <[EMAIL PROTECTED]> wrote: So to say it another way, I have a table that has 900 records in it, I've added 3 records, but then deleted 2 of those which puts the actual record count at 901 but my auto increment field starts at 904 on

Re: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Jason Pruim
On Aug 29, 2007, at 2:27 PM, Jim Lucas wrote: Jason Pruim wrote: 3. Ask yourself, "Is it important to keep the auto-increment field contiguous?" The main reason for changing it is I do currently have an option to sort by record number, although, if I add a Record number in php, but still h

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
I forgot to mention in my question that only IE appears to cache. And with the way my PHP program goes, I'm constantly changing the URL as I go through the application to modify data and status message. But whenever I return the the edit page, the old data is showing up. Charlene Richard Ly

Re: [PHP] How to show proper time to users from around the world

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 2:24 am, Hemanth wrote: > Is there a solution to showing the proper time and date at user > browsers > and also recording proper USER times in the database operations in > mysql Not really. You can use Javascript to get what the user's clock SAYS is the date/time, but WAY

Re: [PHP] Re: Problems with matrix

2007-08-29 Thread Richard Lynch
Do you REALLY need all the values in one giant matrix at once? You might be MUCH better off to read a single line, process it, discard it, and move on to the next one. Your webhost is probably wrong and you probably ARE running out of RAM and/or running afoul of PHP's time_limit in php.ini set_t

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
I had used something similar in another iteration of trying to fix the caching problem in IE. I tried these lines again, and they don't work. It is only IE that is caching. Charlene Satyam wrote: I'm sending these headers: header('Cache-Control: no-cache, must-revalidate'); // HTTP/1

Re: [PHP] Perhaps an incomplete $_POST

2007-08-29 Thread Kirk Friggstad
To the best of my knowledge, the "name" attribute of the FORM tag is never submitted with the request, whether it be GET or POST. It's there for client-side scripting (JavaScript, etc.) only. One trick that might help you - if your form action is POST, add a querystring to the action, something li

Re: [PHP] Re: Disadvantages of output buffering

2007-08-29 Thread Richard Lynch
On Tue, August 28, 2007 6:40 pm, Felipe Alcacibar wrote: > Emil Edeholt wrote: >> Hi! >> >> My php project would get a much cleaner code if I could set cookies >> anywhere in the code. So I thought of output buffering. But I can't >> find >> any articles on the cons of output buffering. I mean it m

RE: [PHP] Regular expression - URL validator

2007-08-29 Thread Richard Lynch
Yes, make sure you have http:// on the front. http://$link";; ?> On Tue, August 28, 2007 3:22 pm, Wagner Garcia Campagner wrote: > Thanks Jim, > > Your sugestion worked perfect for me!! > > I have another question: > > After i validate this URL i want to put a link with this URL in my > page. > >

Re: [PHP] sybase installation error

2007-08-29 Thread Richard Lynch
It's not finding your Sybase client libraries. Why, how, or where, I dunno... Check config.log and see what it says about Sybase. Also make sure that the Sybase .so library file thingies are where PHP thinks they will be. If they are not, you can sometimes just put a symlink from where PHP is l

Re: [PHP] Heredocs

2007-08-29 Thread Daniel Brown
On 8/29/07, Richard Lynch <[EMAIL PROTECTED]> wrote: > I don't think you can have a space between the <<< and the 'END' bit... > > On Wed, August 29, 2007 6:00 am, RodgerW wrote: > > Are heredocs supported by PP 5.2.3 running in WinXP/Apache2.2.4 ? > > I prrint via heredocs and its not working. Pri

Re: [PHP] CAN'T GET OUT OF THIS LIST

2007-08-29 Thread Jim Lucas
Dave Howard Schiff wrote: Please someone remove me! I can't get out! ___ Yahoo! Mail - Sempre a melhor opção para você! Experimente já e veja as novidades. http://br.yahoo.com/mailbeta/tudonovo/ dud, check out this link

Re: [PHP] PhP / MySQL problem

2007-08-29 Thread Ludovic André
Hi, I created a form asking username, password, country, etc. On the submit of this form I make a sql connection and update the database, add the user. The problem is that whenever the field 'password' is filled in, "it" (I don't know what) is asking to confirm the change of the password. I m

Re: [PHP] PhP / MySQL problem

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 2:03 pm, debussy007 wrote: > I created a form asking username, password, country, etc. > On the submit of this form I make a sql connection and update the > database, > add the user. > > The problem is that whenever the field 'password' is filled in, > "it" (I don't know wha

Re: [PHP] Round

2007-08-29 Thread Koen van den Boogaart
Some information from Wikipedia: http://en.wikipedia.org/wiki/Negative_zero. Says in math a negative zero doesn't exist, in computing it does. Strange thing is that PHP4 and 5 until at least 5.1.6 (see Jim Lucas) round() gives a float(0) and then 5.2.3 gives float(-0). I'll report a bug. ""Rich

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 2:10 pm, Charlene wrote: > I forgot to mention in my question that only IE appears to cache. And > with the way my PHP program goes, I'm constantly changing the URL as I > go through the application to modify data and status message. But > whenever I return the the edit pa

Re: [PHP] Perhaps an incomplete $_POST

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 2:01 pm, Jay Blanchard wrote: > I just noticed something a little odd, and maybe there is a simple > solution. Given a form; > > > > The attributes, especially the name "foo", never appear in any > variables > array. I am thinking that this might be handy to have for severa

Re: [PHP] PhP / MySQL problem

2007-08-29 Thread debussy007
I'm using FF. But it asks to confirm the change of password of my MySQL users. If I comment the php/mysql lines in the .php files, I do not have such a pop-up. Ludovic André wrote: > > >> Hi, >> >> I created a form asking username, password, country, etc. >> On the submit of this form I make

Re: [PHP] Perhaps an incomplete $_POST

2007-08-29 Thread Ludovic André
Yep, the form name is never submitted with the form info. However, the submit button will be submitted along. So, as an alternative, you could name the submit button in a way to recognize the submitted form: ... Ludo To the best of my knowledge, the "name" attribute of the FORM tag is neve

[PHP] Re: Heredocs

2007-08-29 Thread zerof
RodgerW escreveu: Are heredocs supported by PHP 5.2.3 running in WinXP/Apache2.2.4 ? I prrint via heredocs and its not working. Print with single quotes and double quotes work. string init method 3: heredocs END; ?> ---

RE: [PHP] Pragmatically changing a "Record Number"

2007-08-29 Thread Bastien Koert
Please don't do that...autonumber should not be relied for anything other than a unique row identifier. It should NOT matter to the application what that value is as long as it unique. If you need a count of the number of records, do a query (select count(*) from table...) bastien> To: php-ge

[PHP] date formatting

2007-08-29 Thread Mike Ryan
I would like to have my users input the date formate as mm-dd- mysql wants the data to come down as -mm-dd. The question I have is how do I convert from the mm-dd- to -mm-dd so that I can write it out to the database? -- PHP General Mailing List (http://www.php.net/) To unsubscri

[PHP] Re: About Session And Cookies

2007-08-29 Thread tedd
At 10:52 PM +0200 8/18/07, Michelle Konzack wrote: Am 2007-08-17 22:07:47, schrieb Bastien Koert: If cookies are not available, you can either hide the id in the hidden form field element or enable trans_sid to automatically pass the session id in the url This will be a security risk sin

Re: [PHP] date formatting

2007-08-29 Thread Wolf
Just have your input form get it in sections, then piece it all together when dumping it to MySQL This way you can transparent the code on the front to users, but have it in the right format in the backend. Mike Ryan <[EMAIL PROTECTED]> wrote: > I would like to have my users input the dat

[PHP] Re: [WD]: PHP Question - any help is appreciated

2007-08-29 Thread brian
Dylan Barber wrote: I am needing to provide back a fixed length file out of a shopping cart system - I can create the file but does anybody have a simple function to pad or truncate a string to a certain length? Use sprintf() to format your string. $len = 20 //the length you want $str = 'abcd

Re: [PHP] Re: About Session And Cookies

2007-08-29 Thread Kirk Friggstad
On 8/29/07, tedd <[EMAIL PROTECTED]> wrote: > When the user first generates a session id, grab the user's ip and > store both in mysql. > > In the code, always check the session id against the user's ip before > doing anything. If they don't match with what you started with, then > stop. That shoul

Re: [PHP] Re: About Session And Cookies

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 4:33 pm, tedd wrote: > At 10:52 PM +0200 8/18/07, Michelle Konzack wrote: >>Am 2007-08-17 22:07:47, schrieb Bastien Koert: >>> >>> If cookies are not available, you can either >>> >>> hide the id in the hidden form field element >>> or >>> enable trans_sid to automatical

Re: [PHP] date formatting

2007-08-29 Thread Richard Lynch
On Wed, August 29, 2007 4:12 pm, Mike Ryan wrote: > I would like to have my users input the date formate as mm-dd- > mysql > wants the data to come down as -mm-dd. > > The question I have is how do I convert from the mm-dd- to > -mm-dd so > that I can write it out to the database?

[PHP] Re: Heredocs

2007-08-29 Thread Al
Suggestion Write your code like this and you'll be less likely to err and your code will be more readable. You can even put variables inside the heredoc. string init method 3: heredocs Your test text txt; print $str; ?> RodgerW wrote: Are heredocs supported by PP 5.2.3 running in W

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
Unfortunately I don't have a choice. I have to be able to handle IE. And IE is caching the page. I can see it in my Temporary Internet Files folder. And the Expiration Date is 3 hours after the file is created. If I delete the file, a new one is created and the Expiration Date is 3 hours a

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Charlene
Unfortunately I don't have a choice. I have to be able to handle IE. And IE is caching the page. I can see it in my Temporary Internet Files folder. And the Expiration Date is 3 hours after the file is created. If I delete the file, a new one is created and the Expiration Date is 3 hours a

Re: [PHP] Internet Explorer Caching

2007-08-29 Thread Jim Lucas
Charlene wrote: Unfortunately I don't have a choice. I have to be able to handle IE. And IE is caching the page. I can see it in my Temporary Internet Files folder. And the Expiration Date is 3 hours after the file is created. If I delete the file, a new one is created and the Expiration Da