RE: [PHP] php + mysql - timstamp - calculate hours remaining

2006-01-10 Thread Albert
I wrote: Delete the records from the table: mysql_query(DELETE FROM table WHERE timestamp = '$timestamp') or die('Could not delete from table'); That query should be DELETE FROM table WHERE timestamp = '$timestamp' Sorry about that. Albert -- No virus found in this outgoing message.

Re: [PHP] php + mysql - timstamp - calculate hours remaining

2006-01-10 Thread David Grant
Gregory, David Grant wrote: Gregory Machin wrote: I have a table with a timestamp column and would like to use his to calculate the age of the record . how would i go about this... I would also like to exicute a mysql stament that pasess the tables and removes fields older than say 72 hours.

Re: [PHP] php + mysql - timstamp - calculate hours remaining

2006-01-10 Thread M. Sokolewicz
David Grant wrote: Gregory, David Grant wrote: Gregory Machin wrote: I have a table with a timestamp column and would like to use his to calculate the age of the record . how would i go about this... I would also like to exicute a mysql stament that pasess the tables and removes fields

[PHP] Re: php / mysql / js search result question

2006-01-04 Thread Michelle Konzack
Am 2005-12-27 08:03:42, schrieb Dave Carrera: Hi List, User input is a so the list moves to first instance of a. User continues to input ap so the list moves to 2 Apple Customer and so on. This can only be done from a JavaScript. Thank you in advance Dave c Greetings Michelle --

[PHP] MySQL update killed my login...

2006-01-03 Thread William Stokes
Hello, My ISP updated their MySQL DB to 5.0.18 and that killed my login procedure which was OK yesterday. Any ideas how to start to debug this? The login updates 2 fields in users table row where username and password macthes. This is the code: if (!$query = mysql_query(update tbl_users set

Re: [PHP] MySQL update killed my login...

2006-01-03 Thread M
It seems the upgrade was from Mysql 4.0. PASSWORD() function changed between 4.0 and 4.1, it uses longer hashes now. You can still use OLD_PASSWORD() function instead. William Stokes wrote: Hello, My ISP updated their MySQL DB to 5.0.18 and that killed my login procedure which was OK

Re: [PHP] MySQL update killed my login...

2006-01-03 Thread William Stokes
Thanks! -W M [EMAIL PROTECTED] kirjoitti viestissä:[EMAIL PROTECTED] It seems the upgrade was from Mysql 4.0. PASSWORD() function changed between 4.0 and 4.1, it uses longer hashes now. You can still use OLD_PASSWORD() function instead. William Stokes wrote: Hello, My ISP updated

[PHP] Any Senior PHP/MySQL Developers in the Los Angeles area?

2006-01-03 Thread Beau Gould
Any Senior PHP/MySQL Developers in the Los Angeles area looking for work? If so, send me your resume. I've got multiple clients. 70-100k range. Thank you, Beau Gould www.superiorss.com [EMAIL PROTECTED] -- No virus found in this outgoing message. Checked by AVG Free Edition. Version

[PHP] Re: PHP MySQL

2006-01-03 Thread toylet
Here's one thought . ascii (97) is the letter a is it possible that the ascii (65) A was interpreted as lowercase thus creating a duplicate primary key? Or your DBMS doesn't make a distinction between upper or lower case. You are correct. I compiled mysql and php from source tar-ball.

[PHP] PHP MySQL

2006-01-02 Thread Man-wai Chang
A table with a column big5 char(2) not null primary key. $target-query(delete from canton); for ($ii=0; $ii256; $ii++) { for ($jj=0; $jj256; $jj++) { echo $ii ... $jj . \n; $query=insert into canton ( big5 ) values ( ' . mysql_real_escape_string(chr($ii).chr($jj))

[PHP] Re: PHP MySQL

2006-01-02 Thread Jerry Kita
Man-wai Chang wrote: A table with a column big5 char(2) not null primary key. $target-query(delete from canton); for ($ii=0; $ii256; $ii++) { for ($jj=0; $jj256; $jj++) { echo $ii ... $jj . \n; $query=insert into canton ( big5 ) values ( ' .

Re: [PHP] php / mysql / js search result question

2005-12-31 Thread Drew Butler
You're right when you say this has nothing to do with PHP. Well, mostly right. I don't believe he is looking for a select box solution. I believe what is being looked for is a Google Suggest style input box auto-complete solution. Now you were right to say this is heavily dependant on JavaScript

Re: [PHP] php / mysql / js search result question

2005-12-30 Thread Richard Lynch
On Tue, December 27, 2005 2:03 am, Dave Carrera wrote: I have a very long list of customer names which i know is easy to get from a mysql result using php, no prob there. How long is very long?... But what i would like to do is offer input box and when the user enters a letter, i think this

Re: [PHP] php / mysql / js search result question

2005-12-29 Thread Greg Schnippel
Hi - It sounds like you're trying to implement something similar to google suggest which uses ajax to allow a user to navigate through a large list of entries. The google suggest method does use a lot of calls to the database but its asynchronous which eliminates cumbersome page loads.

[PHP] php / mysql / js search result question

2005-12-27 Thread Dave Carrera
Hi List, I have a very long list of customer names which i know is easy to get from a mysql result using php, no prob there. But what i would like to do is offer input box and when the user enters a letter, i think this will require client side onchange(), the full list, i think might be in

[PHP] PHP/MYSQL Connection trouble (charset)

2005-12-26 Thread Christian Ista
Hello, I Have MySQL 4.1.14 and 5.0.15 installed on my Windows XP Pro SP2. There are installed in D:\Tools\MySQL\MySQL Server 4.1.14 and MySQL Server 5.0.15 for the version 5. They work on port 3306 and 3307. When I try a DB connection, I receive this error: File

RE: [PHP] PHP/MYSQL Connection trouble (charset)

2005-12-26 Thread Christian Ista
From: Christian Ista [mailto:[EMAIL PROTECTED] File 'c:\mysql\share\charsets\?.conf' not found (Errcode: 2) Character set '#33' is not a compiled character set and is not specified in the 'c:\mysql\share\charsets\Index' file Resource id #5 I answer to myself. In fact I reinstall MySQL 4.x

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-19 Thread Eric Butera
Could you direct me towards any good resources on general security with php/mysql? http://phpsec.org/library/ Make sure to read these: - data filtering - sql injection . . .and all the others in time. =)

[PHP] MySQL - PHP's configure failed with error

2005-12-19 Thread Scott Fletcher
I don't know what is the problem. I'm using the GNU GCC and GNU Biutils. --snip-- ./configure --with-mysqli=../../mysql/bin/mysql_config --with-apxs2=../../ap ache2/bin/apxs --with-unixODBC --with-openssl --with-curl --disable-libxml - -disable-dom --enable-track-vars --enable-ftp

Re: [PHP] MySQL - PHP's configure failed with error

2005-12-19 Thread Curt Zirzow
On Mon, Dec 19, 2005 at 02:56:37PM -0500, Scott Fletcher wrote: I don't know what is the problem. I'm using the GNU GCC and GNU Biutils. --snip-- ./configure --with-mysqli=../../mysql/bin/mysql_config --with-apxs2=../../ap ache2/bin/apxs --with-unixODBC --with-openssl --with-curl

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-18 Thread Paul Jinks
more or less working now and need to look at security issues. Thanks for the tip about SQL injection - had no idea what this was, but googling it proved very interesting - scary stuff! Could you direct me towards any good resources on general security with php/mysql? Thanks again Paul. -- PHP

[PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread Paul Jinks
Hi all, I have a site where users can search study projects. I'd like to be able to clicks on a project title which passes a variable to this page, which then displays all the data on that project in a table. Cool - and to a noob like me, actually pretty exciting. Except it doesn't work. I

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread David Grant
Paul Jinks wrote: $SQLQuery = SELECT * FROM project WHERE projTitle = .$HTTP_GET_VARS['projTitle'] or die(SQLQuery 1 failed); $SQLQuery = SELECT * FROM project WHERE projTitle = ' . $HTTP_GET_VARS['projTitle'] . '; Not sure why you've got the or die() there.

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread Richard Davey
On 16 Dec 2005, at 12:30, Paul Jinks wrote: I have a site where users can search study projects. I'd like to be able to clicks on a project title which passes a variable to this page, which then displays all the data on that project in a table. Cool - and to a noob like me, actually pretty

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread Paul Jinks
David Grant wrote: $SQLQuery = SELECT * FROM project WHERE projTitle = ' . $HTTP_GET_VARS['projTitle'] . '; Yep, that fixed it. Thanks. I had a feeling there was a mix up with the s and 's. What's with the . s? Not sure why you've got the or die() there. I had the idea that you could

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread Paul Jinks
Richard Davey wrote: ($HTTP_GET_VARS), because lots do not. I would suggest replacing $HTTP_GET_VARS with $_GET (in all instances), because the long format will eventually vanish and your script will cease to work. Cheers Rich, will sort this out. I assume you removed the MySQL details

Re: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread David Grant
Paul, Paul Jinks wrote: David Grant wrote: $SQLQuery = SELECT * FROM project WHERE projTitle = ' . $HTTP_GET_VARS['projTitle'] . '; Yep, that fixed it. Thanks. I had a feeling there was a mix up with the s and 's. What's with the . s? The . is a concatenation operator, i.e. it joins two

RE: [PHP] PHP/MySQL noob rides again.. into trouble

2005-12-16 Thread Kilbride, James
@lists.php.net Subject: Re: [PHP] PHP/MySQL noob rides again.. into trouble David Grant wrote: $SQLQuery = SELECT * FROM project WHERE projTitle = ' . $HTTP_GET_VARS['projTitle'] . '; Yep, that fixed it. Thanks. I had a feeling there was a mix up with the s and 's. What's with the . s

[PHP] mysql select statement in php having three conditions

2005-12-16 Thread sunaram patir
hi, can someone tell me how to do this: i have to retrive data from a mysql table let's sayTABLE . i have to check that the rows i retrive meet this condition: field1='$variable',field2 is false and field3 is also false. as you can see field2 and field3 are bool type. field1 is varchar. i did

RE: [PHP] mysql select statement in php having three conditions

2005-12-16 Thread Jay Blanchard
[snip] can someone tell me how to do this: i have to retrive data from a mysql table let's sayTABLE . i have to check that the rows i retrive meet this condition: field1='$variable',field2 is false and field3 is also false. as you can see field2 and field3 are bool type. field1 is varchar. i

[PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Paul Jinks
the page I get this: pResult of bSELECT projTitle FROM project/b/p p br / br / br / br / /p There are indeed 4 entries in the database, but I can't figure out why it's not displaying the data. It worked fine on my PHP/Mysql-in-a-box course. No, we

[PHP] PHP, MySQL and XML for IPodCasting

2005-12-09 Thread Danny
Hi, I´ve got a web project that daily offers 4 o 5 mp3 files recorded by me. From an web based interface I populate a database with titles, descripcion, images and the path for the mp3 file in the server The cuestion is I would like to offer the content for Ipod, using ipodcasting. Then I have

Re: [PHP] PHP, MySQL and XML for IPodCasting

2005-12-09 Thread Michael Hulse
On Dec 9, 2005, at 3:45 AM, Danny wrote: How to proceed I recently set-up my first Podcast... Every week I have a script that grabs three MP3 files from a remote server and puts them on my own server... Then I have another script that generates the Podcast XML. I am using CRON jobs

Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread John Nichel
projTitle FROM project/b/p p br / br / br / br / /p There are indeed 4 entries in the database, but I can't figure out why it's not displaying the data. It worked fine on my PHP/Mysql-in-a-box course. No, we didn't study the syntax :( Any help gratefully received

Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Zareef Ahmed
Hi Paul, Why you are closing your connection before finishing your work on the database? Zareef Ahmed - Original Message - From: Paul Jinks [EMAIL PROTECTED] To: php-general@lists.php.net Sent: Friday, December 09, 2005 6:50 AM Subject: [PHP] PHP/MySql noob falls at first

[PHP] Re: PHP/MySql noob falls at first hurdle

2005-12-09 Thread Brice
On 12/9/05, Paul Jinks [EMAIL PROTECTED] wrote: Hi all I've been asked to put simple database interactivity on an academic site. They want users to enter a few details of their projects so other researchers can search and compare funding etc. How difficult can that be, I thought I've

RE: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Dan Parry
Jinks [mailto:[EMAIL PROTECTED] Sent: 09 December 2005 11:51 To: php-general@lists.php.net Subject: [PHP] PHP/MySql noob falls at first hurdle Hi all I've been asked to put simple database interactivity on an academic site. They want users to enter a few details of their projects so other

[PHP] Re: PHP/MySql noob falls at first hurdle

2005-12-09 Thread Brice
Are short tags disabled? Change this line... ?=$output_row[projTitle]?br / To... ?php echo ( $output_row[projTitle] ) ?br / This line seems to work : pResult of b?=$SQLquery ?/b/p -- Brice Favre http://pelmel.org/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Re: PHP/MySql noob falls at first hurdle

2005-12-09 Thread Paul Jinks
Brice wrote: Try to check the key of your result row with a print_r or a var_dump command. Brice Favre http://pelmel.org/ Like this? ?php while($ouput_row = mysql_fetch_array($result)) print_r($output_row); ? Apologies if this is pathetically wrong. Like I

Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Rory McKinley
Paul Jinks wrote: snip ? while($ouput_row = mysql_fetch_array($result)) { ? ?=$output_row[projTitle]?br / snip Paul - is this the actual code that you are using? - because you have a typo in your while statement - $ouput_row instead of $output_row - means that when you

RE: [PHP] Re: PHP/MySql noob falls at first hurdle

2005-12-09 Thread Dan Parry
PROTECTED] Sent: 09 December 2005 15:05 To: php-general@lists.php.net Subject: Re: [PHP] Re: PHP/MySql noob falls at first hurdle Brice wrote: Try to check the key of your result row with a print_r or a var_dump command. Brice Favre http://pelmel.org/ Like this? ?php

[PHP] Re: PHP/MySql noob falls at first hurdle

2005-12-09 Thread Brice
On 12/9/05, Paul Jinks [EMAIL PROTECTED] wrote: Brice wrote: Try to check the key of your result row with a print_r or a var_dump command. Brice Favre http://pelmel.org/ Like this? ?php while($ouput_row = mysql_fetch_array($result)) print_r($output_row);

Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Rory McKinley
Paul Jinks wrote: Rory McKinley wrote: Paul Jinks wrote: snip ? while($ouput_row = mysql_fetch_array($result)) { ? ?=$output_row[projTitle]?br / snip Paul - is this the actual code that you are using? - because you have a typo in your while statement - $ouput_row

Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Dan McCullough
I would hate to see a time clock that tabulated how many hours I wasted with typos and stupid things like that. On 12/9/05, Rory McKinley [EMAIL PROTECTED] wrote: Paul Jinks wrote: Rory McKinley wrote: Paul Jinks wrote: snip ? while($ouput_row =

RE: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Jim Moseby
For future reference, during testing, you can set your error reporting levels ( i think) in php.ini to output a notice regarding a variable that does not exist - would have helped you spot the error! I normally use the Zend debugger which does quite a good job of telling me that I am an

Re: [PHP] PHP, MySQL and XML for IPodCasting

2005-12-09 Thread Danny
Simply Fantastic!. Thanks a lot! So for me the best solution I think, would be to read the MySQL Table, and produce the XML with a given template from a PHP Script. I will use Scheduled Task instead of CRON... (Sorry, working on windows ;-) ) [Off topic] Could it be tested without an IPod

Re: [PHP] PHP, MySQL and XML for IPodCasting

2005-12-09 Thread Michael Hulse
On Dec 9, 2005, at 1:45 PM, Danny wrote: Simply Fantastic!. Thanks a lot! Sure thing, I am glad that I was able to help/give you some ideas. :) So for me the best solution I think, would be to read the MySQL Table, and produce the XML with a given template from a PHP Script. I will use

Re: [PHP] Writing a mailing list program with php/mysql.

2005-12-03 Thread Mark Steudel
I need to know is: given the code below, are there any examples of php/mysql driven mailing list scripts that I can use as a tutorial on helping me to convert mine to a mysql database driven program? Any ideas/recommendations would be apreciated. Thanks for all the help. The code

[PHP] MySQL C API

2005-11-18 Thread Leonard Burton
HI All, Does anyone on here use the MySQL C API? Would you mind if I asked you a few questions off the list? Thanks, -- Leonard Burton, N9URK [EMAIL PROTECTED] The prolonged evacuation would have dramatically affected the survivability of the occupants. -- PHP General Mailing List

Re: [PHP] MySQL C API

2005-11-18 Thread Curt Zirzow
On Fri, Nov 18, 2005 at 09:34:56AM -0500, Leonard Burton wrote: HI All, Does anyone on here use the MySQL C API? Would you mind if I asked you a few questions off the list? You might want to ask someone on a related mysql list. Curt. -- -- PHP General Mailing List (http://www.php.net/)

[PHP] PHP / MySQL Authentication class

2005-11-14 Thread Alan Milnes
Can anyone point me to a good User Authentication class written in PHP (Version 5 preferably) that uses MySQL as the backend. If the output is valid XHTML then even better. There are lots of hits on Google but I need some help sorting the wheat from the chaff. It's for a hobbyist site so I'm

Re: [PHP] PHP / MySQL Authentication class

2005-11-14 Thread Jochem Maas
Alan Milnes wrote: Can anyone point me to a good User Authentication class written in PHP (Version 5 preferably) that uses MySQL as the backend. If the output is valid XHTML then even better. There are lots of hits on Google but I need some help sorting the wheat from the chaff. it might

[PHP] Mysql php Load Data Infiles

2005-11-06 Thread Vizion
While I think this is primarily a mysql syntax problem I have asked on the mysql forum but not got a reply. I am trying using php to set up a system for loading a new data base using the Load Data Infile statement. I could not get it to work properly with php so I thought I would try some

[PHP] PHP MYSQL Dynamic Select Boxes: Please Help

2005-11-03 Thread Adele Botes
I have 2 tables: products table product_id (INT 11 AUTOINCRE PRI) product_name (VARCHAR 255) product_desc (VARCHAR 255) color table color_id (INT 11 AUTOINCRE PRI) color (VARCHAR 255) image (VARCHAR 255) product_id (INT 11) I would like to create the first select box (pulling the options from

[PHP] Re: PHP MYSQL Dynamic Select Boxes: Please Help

2005-11-03 Thread James Benson
Try asking in a newsgroup or forum specific to javascript, that has nothing to do with PHP Adele Botes wrote: I have 2 tables: products table product_id (INT 11 AUTOINCRE PRI) product_name (VARCHAR 255) product_desc (VARCHAR 255) color table color_id (INT 11 AUTOINCRE PRI) color (VARCHAR

[PHP] MySql connection error on win XP for script that works on Freebsd 5.3

2005-10-26 Thread Vizion
I have just installed MySql on Win XP and am attempting to run a php script to create some databases. The script works fine on FreeBSD 5.3 running mysql-client-5.0.11 and mysql-server-5.0.11. MySQL has been installed on windows XP using a download of mysql-5.0.13-rc-win32.zip. Test.php reports

RE: [PHP] MySql connection error on win XP for script that works on Freebsd 5.3

2005-10-26 Thread Jay Blanchard
[snip] I have searched the mysql website and located an article which shows reference to this error indicating that the client may need to be upgraded but as I am using the mysql-5.0.13-rc-win32.zip package I am cautious about assuming that that is the actual cause. [/snip]

Re: [PHP] MySql connection error on win XP for script that works on Freebsd 5.3

2005-10-26 Thread Vizion
On Wednesday 26 October 2005 08:35, the author Jay Blanchard contributed to the dialogue on- RE: [PHP] MySql connection error on win XP for script that works on Freebsd 5.3: [snip] I have searched the mysql website and located an article which shows reference to this error indicating

[PHP] PHP Mysql Developer needed in South Africa

2005-10-13 Thread Paul
I have a position open for someone in Johannesburg South Africa with the following skills. php mysql css xml xhtml Image and artwork a bonus (ImageReady,Photoshop, Paintshop, The gimp) Flash a bonus Please email me directly at [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net

[PHP] mysql/php date functions..

2005-09-26 Thread bruce
hi... can anybody point me to a good/basic tutorial (tested) for php/mysql date functions... basically, i want to store a date/time in a column, and be able to read it, manipulate it, and update the table. i've seen various articles/sample code, but i'm looking for something that i cna pretty

RE: [PHP] mysql/php date functions..

2005-09-26 Thread Jim Moseby
-Original Message- From: bruce [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 11:12 AM To: php-general@lists.php.net Subject: [PHP] mysql/php date functions.. hi... can anybody point me to a good/basic tutorial (tested) for php/mysql date functions... basically

Re: [PHP] mysql/php date functions..

2005-09-26 Thread Silvio Porcellana
Jim Moseby wrote: Hi Bruce! MySQL and PHP both have extensive built-in date functions that are clearly documented and extraordinarily easy to use. For the vast majority of situations, there is no need to manually write any custom date-handling code. The decision to use MySQL or PHP to

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
-Original Message- From: Silvio Porcellana [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 8:51 AM To: php-general@lists.php.net Subject: Re: [PHP] mysql/php date functions.. Jim Moseby wrote: Hi Bruce! MySQL and PHP both have extensive built-in date functions that are clearly

Re: [PHP] mysql/php date functions..

2005-09-26 Thread John Nichel
bruce wrote: how can i create a mysql sql statement to insert a php 'time()' into mysql? i've got the mysql var 't1, timestamp' but i can't figure out how to do an insert $q = time(); $sql = sprintf(insert into foo (id, ctime) values(%d, %???), $id, $q); can't figure out how to get this to

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
), it doesn't work... if i -- insert into foo (id, time) values (2, NOW()), it works!!... my question is why??? -bruce -Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 11:00 AM To: php-general@lists.php.net Subject: Re: [PHP] mysql/php date

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
, September 26, 2005 11:00 AM To: php-general@lists.php.net Subject: Re: [PHP] mysql/php date functions.. bruce wrote: how can i create a mysql sql statement to insert a php 'time()' into mysql? i've got the mysql var 't1, timestamp' but i can't figure out how to do an insert $q = time

RE: [PHP] mysql/php date functions..

2005-09-26 Thread Chris W. Parker
bruce mailto:[EMAIL PROTECTED] on Monday, September 26, 2005 11:13 AM said: i'm concerned that i can't seem to craft/create a basic sql cmd within mysql to get a value (other than NOW()) to work... [snip] my question is why??? MySQL timestamps are different from UNIX timestamps. Chris.

Re: [PHP] mysql/php date functions..

2005-09-26 Thread John Nichel
bruce wrote: thanks... but that's not it john... i'm not worried about creating the sql_statement in the php... i'm concerned that i can't seem to craft/create a basic sql cmd within mysql to get a value (other than NOW()) to work... if i do (from mysql) -- insert into foo (id, time) values

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
but that still doesn't explain why i can't slam some value directly into the timestamp var within the mysql tbl... -Original Message- From: Chris W. Parker [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 11:15 AM To: php-general@lists.php.net Subject: RE: [PHP] mysql/php date

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
-Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 11:19 AM To: php-general@lists.php.net Subject: Re: [PHP] mysql/php date functions.. bruce wrote: thanks... but that's not it john... i'm not worried about creating the sql_statement

Re: [PHP] mysql/php date functions..

2005-09-26 Thread John Nichel
bruce wrote: john... that appears to be it!! although i would have assumes it would have done a most significant bit fill with 0's... so my question also comes down to .. do i use the php date functions for date/time manipulation.. or do i use the mysql functions any

RE: [PHP] mysql/php date functions..

2005-09-26 Thread Jim Moseby
-Original Message- From: bruce [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 2:46 PM To: 'John Nichel'; php-general@lists.php.net Subject: RE: [PHP] mysql/php date functions.. john... that appears to be it!! although i would have assumes it would have done

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
Nichel [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 11:48 AM To: php-general@lists.php.net Subject: Re: [PHP] mysql/php date functions.. bruce wrote: john... that appears to be it!! although i would have assumes it would have done a most significant bit fill with 0's... so my

RE: [PHP] mysql/php date functions..

2005-09-26 Thread bruce
bruce -Original Message- From: bruce [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 12:38 PM To: 'John Nichel'; php-general@lists.php.net Subject: RE: [PHP] mysql/php date functions.. so you play with the time/date vars on the php side, and then simply store them in the mysql tbl

Re: [PHP] mysql/php date functions..

2005-09-26 Thread John Nichel
bruce wrote: or.. better yet. if i do a php - time(), i get a unix_timestamp var. how do you guys store this in mysql. you can't simply do an insert into a mysql/timestamp var. so how do you convert it? I don't convert it. I store the UNIX timestamp in an INT(11) column. also, once you

RE: [PHP] mysql/php date functions..

2005-09-26 Thread Chris W. Parker
John Nichel mailto:[EMAIL PROTECTED] on Monday, September 26, 2005 12:43 PM said: I don't convert it. I store the UNIX timestamp in an INT(11) column. This is going to be a basic question I'm sure but why INT and not VARCHAR? Is it simply because a timestamp is a number? Chris. -- PHP

Re: [PHP] mysql/php date functions..

2005-09-26 Thread Kristen G. Thorson
- the php var? thanks bruce -Original Message- From: bruce [mailto:[EMAIL PROTECTED] Sent: Monday, September 26, 2005 12:38 PM To: 'John Nichel'; php-general@lists.php.net Subject: RE: [PHP] mysql/php date functions.. so you play with the time/date vars on the php side, and then simply

Re: [PHP] mysql/php date functions..

2005-09-26 Thread John Nichel
Chris W. Parker wrote: John Nichel mailto:[EMAIL PROTECTED] on Monday, September 26, 2005 12:43 PM said: I don't convert it. I store the UNIX timestamp in an INT(11) column. This is going to be a basic question I'm sure but why INT and not VARCHAR? Is it simply because a timestamp is

RE: [PHP] mysql/php date functions..

2005-09-26 Thread Chrome
] Sent: 26 September 2005 19:46 To: 'John Nichel'; php-general@lists.php.net Subject: RE: [PHP] mysql/php date functions.. john... that appears to be it!! although i would have assumes it would have done a most significant bit fill with 0's... so my question also comes down to .. do i use the php

[PHP] mysql/php date functions..

2005-09-26 Thread info
Hello Bruce, While the date functions are well documented - http://php.net/date - here is a little example to manipulate the date with php, rather than mysql: // set the new expiry date // DATE FUNCTIONS FOR THE EXPIRY MODULE // first perform date arithmetic $listingExpiry = mktime

[PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Dave Gutteridge
. The specific distribution is CentOS 4.1. My computer is a pentium 3 with 512 MB Ram. On the web hosting service where my web sites are hosted, they have the following versions of PHP, MySQL and phpMyAdmin: PHP Version 4.3.8 MySQL 4.1.3-beta-standard phpMyAdmin 2.5.7-pl1 What I would like to do

Re: [PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Jochem Maas
Linux on my home computer. The specific distribution is CentOS 4.1. My computer is a pentium 3 with 512 MB Ram. On the web hosting service where my web sites are hosted, they have the following versions of PHP, MySQL and phpMyAdmin: PHP Version 4.3.8 MySQL 4.1.3-beta-standard phpMyAdmin 2.5.7-pl1

Re: [PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Dave Gutteridge
Thank you for your helpful assistance in explaining the situation to me. It would seem from the advice I've been given that I don't need to worry about compatibility when it comes to application versions. But I do have a follow up question. Are there any specifications or installation options

Re: [PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Jordan Miller
On Sep 19, 2005, at 8:31 AM, Jochem Maas wrote: e.g: $var = array_pop( explode('-', '1-2-3-4-5') ); .. is bad code (read the manual page for array_pop very carefully) and would work in older versions but the engine has been tightened up to disallow such fauxpas. Jochem, Whoa...

Re: [PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Jochem Maas
Jordan Miller wrote: On Sep 19, 2005, at 8:31 AM, Jochem Maas wrote: e.g: $var = array_pop( explode('-', '1-2-3-4-5') ); .. is bad code (read the manual page for array_pop very carefully) and would work in older versions but the engine has been tightened up to disallow such fauxpas.

Re: [PHP] Can I install versions of PHP/MySQL that will be compatible with my host server?

2005-09-19 Thread Jordan Miller
That is very interesting, thank you. We cannot escape politics, eh? Jordan On Sep 19, 2005, at 9:32 AM, Jochem Maas wrote: Jordan Miller wrote: On Sep 19, 2005, at 8:31 AM, Jochem Maas wrote: e.g: $var = array_pop( explode('-', '1-2-3-4-5') ); .. is bad code (read the manual page for

[PHP] mysql table row updation based on user input.

2005-09-18 Thread babu
Hi, i have a form for the user input with checkboxes and table rows for the user. The user can select the checkboxes which correspond to table rows in database. Depending on the selection of checkboxes i want to update the fields. For example:

Re: [PHP] mysql query

2005-09-15 Thread Mark Rees
for that month and insert the rows where they don't already exist. I wait they understand me what I want: I work php/mysql. create table tableA ( day int, month int ); select * from tableA where month=5 and day 19; This will select everything from the 5th month and before the 19th day

Re: [PHP] php/mysql object id question..

2005-09-15 Thread Oliver Grätz
Jasper Bryant-Greene schrieb: Oliver Grätz wrote: 3. Yes. One can abuse exceptions to return something in a constructor. Just another argument against exceptions ;-) OK, it's unorthodox, if you absolutely need to do that, do it and tell nobody *g*. This is not abusing exceptions. If

[PHP] php/mysql object id question..

2005-09-14 Thread bruce
hi... i have the following psuedo code... i'm showing the pertinent parts, and eliminating the rest... -- class sql { function sql(...) { return false mysql_ mysql_ } } $db = new sql(...) echo db = .$db;

Re: [PHP] php/mysql object id question..

2005-09-14 Thread Stephen Leaf
On Wednesday 14 September 2005 03:42 pm, bruce wrote: hi... i have the following psuedo code... i'm showing the pertinent parts, and eliminating the rest... -- class sql {    function sql(...)    {       return false       mysql_      

RE: [PHP] php/mysql object id question..

2005-09-14 Thread bruce
[mailto:[EMAIL PROTECTED] Sent: Wednesday, September 14, 2005 1:51 PM To: php-general@lists.php.net Subject: Re: [PHP] php/mysql object id question.. On Wednesday 14 September 2005 03:42 pm, bruce wrote: hi... i have the following psuedo code... i'm showing the pertinent parts

Re: [PHP] php/mysql object id question..

2005-09-14 Thread Edward Vermillion
bruce wrote: stephen, you're correct regarding what's going on... i had taken some code used in phpBB, and blindly slammed it into my app to test out their db class... i had assumed that it worked guess what!!! in their constructor, they have the 'return false' arrggghh!!! a quick look at

Re: [PHP] php/mysql object id question..

2005-09-14 Thread Jasper Bryant-Greene
bruce wrote: in their constructor, they have the 'return false' arrggghh!!! a quick look at google, and it appears that you can't return any val from a constructor. in fact, the 'object id' that's being returned appears to simply be (as you stated) the instance of the class that was created...

RE: [PHP] php/mysql object id question..

2005-09-14 Thread bruce
Vermillion [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 14, 2005 2:46 PM To: [EMAIL PROTECTED] Cc: php-general@lists.php.net Subject: Re: [PHP] php/mysql object id question.. bruce wrote: stephen, you're correct regarding what's going on... i had taken some code used in phpBB

[PHP] mysql query

2005-09-14 Thread Jesús Alain Rodríguez Santos
to insert together with the one selected, I wait they understand me what I want: I work php/mysql. sorry for my english i'm cuban Thank you and excuse the nuisances -- Este mensaje ha sido analizado por MailScanner en busca de virus y otros contenidos peligrosos, y se considera que está limpio

Re: [PHP] php/mysql object id question..

2005-09-14 Thread Oliver Grätz
bruce schrieb: but then, i'm starting to realize that there's probably a great deal of 'opensource' code that's in use that hasn't been thoroughly vetted. 1. Constructors cannot explicitly return anything because they always return the new object. 2. OpenSource project and the code in them:

Re: [PHP] php/mysql object id question..

2005-09-14 Thread Jasper Bryant-Greene
Oliver Grätz wrote: 3. Yes. One can abuse exceptions to return something in a constructor. Just another argument against exceptions ;-) OK, it's unorthodox, if you absolutely need to do that, do it and tell nobody *g*. This is not abusing exceptions. If you throw an exception then the

Re: [PHP] mysql query

2005-09-14 Thread Stephen Leaf
inserted in the table in the same month, in case that there are not them then they owe you to insert together with the one selected, I wait they understand me what I want: I work php/mysql. create table tableA ( day int, month int ); select * from tableA where month=5 and day 19

[PHP] php/mysql web question

2005-09-06 Thread bruce
hi... if an app has a webpage that has to interface/display data from a mysql db, does the app have to essentially do a new db_connection for each time that a user accesses the page during the session. as far as i can tell, it does. in other words, the page would need to look something like:

<    5   6   7   8   9   10   11   12   13   14   >