Re: [PHP-DB] Developer needed in London

2005-01-28 Thread Jochem Maas
Underodog H.R. wrote: Sorry for using the list in this way, wont happen again. wtf. 'they' posted it twice with the same message... thats the definition of 'again'. the fact that 'they' can't even spell their company name correctly would make me think twice about working there ;-) Underodog H.R.

[PHP-DB] Re: [PHP] Re: [PHP-DB] Developer needed in London

2005-01-28 Thread Jochem Maas
Jochem Maas wrote: Underodog H.R. wrote: Sorry for using the list in this way, wont happen again. wtf. 'they' posted it twice with the same message... thats the definition of 'again'. I just noticed that they crossposted rather than post twice. -- PHP Database Mailing List (http://www.php.net/)

[PHP-DB] Hyphens and MySQL

2005-01-28 Thread Mark Benson
I am having problems with entering data into MySQL from a PHP script. I am taking the data from an array generated by a CSV parsing routine. That in itself works great, however I have large number of data units with '-' characters in (hyphens) and it is causing the SQL queries to dump out with

Re: [PHP-DB] Re: [PHP] Re: [PHP-DB] Developer needed in London

2005-01-28 Thread Martin Norland
Jochem Maas wrote: Jochem Maas wrote: Underodog H.R. wrote: Sorry for using the list in this way, wont happen again. I just noticed that they crossposted rather than post twice. That's three times now I've seen the statement that it won't happen again! Unforgivable! Seriously though - their name

RE: [PHP-DB] Hyphens and MySQL

2005-01-28 Thread Bastien Koert
sure, lots of way, regex replacement, str_replace, etc but its strange that a hyphen is causing an error. can you post some code? Bastien From: Mark Benson [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] Hyphens and MySQL Date: Fri, 28 Jan 2005 14:21:34 + I am having problems with

Re: [PHP-DB] Hyphens and MySQL

2005-01-28 Thread Martin Norland
Mark Benson wrote: I am having problems with entering data into MySQL from a PHP script. I am taking the data from an array generated by a CSV parsing routine. That in itself works great, however I have large number of data units with '-' characters in (hyphens) and it is causing the SQL

Re: [PHP-DB] Debian mssql_init

2005-01-28 Thread PHPDiscuss - PHP Newsgroups and mailing lists
Robert Twitty wrote: The problem is caused by the fact that the sybase extension was installed instead of the mssql extension. The sybase extension supports some of the mssql functions via aliasing. Unfortunately, mssql_init() is not supported by the sybase ext. You basically have only 2

Re: [PHP-DB] Hyphens and MySQL

2005-01-28 Thread Josip Dzolonga
On Fri, 2005-01-28 at 14:21 +, Mark Benson wrote: Is there an easy way to search and replace/remove characters in a string in PHP? www.php.net/str_replace , www.php.net/preg_replace . You can strip out the - characters with str_replace(-, , $string); -- Josip Dzolonga, dzolonga at mt dot

[PHP-DB] odd results when running this

2005-01-28 Thread Chip Wiegand
Okay, so I have got the php bits working in this web page but it is running 3 times every time the page loads, and I see no reason why (I have opened this page in two differant browsers). The code for the entire page is pasted below, it includes some calls to include files which are not

RE: [PHP-DB] odd results when running this

2005-01-28 Thread Bastien Koert
it runs three times because there are three rows of data and you are setting the same thing for each set of data. try this ? $sql=select * from hotspots; $result = mysql_query($sql); $x = 1; while ( $row = mysql_fetch_array($result)) { printf(pimg src=\hotspots/latest$x.gif\ alt=\%s\

Re: [PHP-DB] odd results when running this

2005-01-28 Thread Martin Norland
Chip Wiegand wrote: Okay, so I have got the php bits working in this web page but it is running 3 times every time the page loads, and I see no reason why (I have opened this page in two differant browsers). The code for the entire page is pasted below, it includes some calls to include files

RE: [PHP-DB] odd results when running this

2005-01-28 Thread Chip Wiegand
Thanks for the tips. I find this confusing - I have 3 statements pulling 3 differant images, so I don't understand why the script would run 3 times if there is not loop telling it to do so. Shouldn't it just load each image and then stop? Doesn't the while loop stop when it hits the last row?

RE: [PHP-DB] odd results when running this

2005-01-28 Thread Bastien Koert
What you should do then is to compare some value to only write the image data if that value matchesin my code snippet, since you are writing the same data, i just loop thru it and increment the image counter to output the correct image. A better way to manage this might be to put the image

RE: [PHP-DB] odd results when running this

2005-01-28 Thread Chip Wiegand
Thanks, I did use your code as is, and it works perfectly. Regards, Chip Bastien Koert [EMAIL PROTECTED] wrote on 01/28/2005 09:56:35 AM: What you should do then is to compare some value to only write the image data if that value matchesin my code snippet, since you are writing the

Re: [PHP-DB] Re: [PHP] Re: [PHP-DB] Developer needed in London

2005-01-28 Thread Jochem Maas
Martin Norland wrote: Jochem Maas wrote: Jochem Maas wrote: Underodog H.R. wrote: Sorry for using the list in this way, wont happen again. I just noticed that they crossposted rather than post twice. That's three times now I've seen the statement that it won't happen again! Unforgivable!

[PHP-DB] if statement

2005-01-28 Thread Craig Hoffman
Hi There, I am trying to write an if statement to see if an array has any values in it and if it does do something. for example: $ticklist2 = array('$values) if (array_values(empty($ticklist2))){ do something } else { do something else } I just can't get this to work. Any help would be

Re: [PHP-DB] if statement

2005-01-28 Thread Jochem Maas
Craig Hoffman wrote: Hi There, I am trying to write an if statement to see if an array has any values in it and if it does do something. for example: $ticklist2 = array('$values) if (array_values(empty($ticklist2))){ empty() is used to check whether a var isset and is not null, or false -

Re: [PHP-DB] if statement

2005-01-28 Thread Balwant Singh
i may be wrong but as i understand that you want to check whether a array holds any value or not -- for this u can use COUNT function of array which will count the values of the array. with best wishes balwant On Sat, 2005-01-29 at 06:29, Craig Hoffman wrote: Hi There, I am trying to write