RE: [PHP-DB] variable with NULL value

2007-05-04 Thread Ford, Mike
On 03 May 2007 16:22, OKi98 wrote: > Hi, > > one more question. > > Why the variable, that contains NULL value appears to be not > set. U -- because that's how it's defined?? (http://php.net/isset) Cheers! Mike --

Re: [PHP-DB] date problems

2007-09-06 Thread Mike Gohlke
y convert them to static values. If there's an index on theEventDate it will be used. Mike... Instruct ICC wrote: From: rDubya <[EMAIL PROTECTED]> My problem is that I have events dated for Sep 2007 and on, and yet they all come up as being on Dec 7 to 9, 2006.. any ideas? rDub

Re: [PHP-DB] date problems

2007-09-06 Thread Mike Gohlke
Argh, make sure you add the closing paren for the date_add since I forgot it. Mike... Mike Gohlke wrote: It's much better to use add_date instead of to_days since mysql isn't smart enough to do it for you. Such as: SELECT yourEventFields FROM theTable WHERE theEventDate BETWEEN

Re: [PHP-DB] ? "SELECT TABLE" Command

2007-09-10 Thread Mike W.
're trying to check that the mysql user you connected as has access to that table. It really feels like a command I may have used in the SQLite analyzer or something. However, I’m sure I copied it from an example script in a book. I’ ve put holds on all the books on PHP and (My)SQL at the l

[PHP-DB] Building WHERE SQL clauses

2008-09-15 Thread Mike Sullivan
ifferent syntax (JOIN, UNION, ...)? If not are there available some canned code snippets that build these types of strings from values passed in the $_POST array. Thanks for any insights on this. --- Mike -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] Building WHERE SQL clauses

2008-09-16 Thread Mike Sullivan
tor = "Bill" OR operator = "Jessica" but that apparently is a SQL syntax error. Thanks again for the insight and any other suggestions you might have. --- Mike ""Bastien Koert"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Mon,

Re: [PHP-DB] Building WHERE SQL clauses

2008-09-17 Thread Mike Sullivan
"Chris" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Mike Sullivan wrote: >> Hi all thanks for the responses! What I have is a 6 table db that has >> each >> >> table created from the output of 6 identical laboratory machines (chic

RE: [PHP-DB] Re: PHP and table/view names with '$'

2009-04-23 Thread Ford, Mike
On 23 April 2009 11:36, Mark Casson advised: > Hi Guys, > > Thanks to you both - you are spot on! > > Shame this is not better documented somewhere. I don't know how much better documented it can be than at http://php.net/language.types.string ... ;) Cheers! Mike -- Mi

RE: [PHP-DB] Postgres query failing, not enough info for debugging...

2009-06-17 Thread Ford, Mike
On 16 June 2009 15:57, Carol Walter advised: > Hello, > > I'm using PHP 5 and PostgreSQL 8.3.6. I have a query that is failing > and I don't know how to troubleshoot the problem. The error message > that it is giving is quite vague. The error message is as follows: > > > Warning: pg_query_pa

RE: [PHP-DB] newbie: how to return one iteration *per unique date (DAY!)* in a timestamp column?

2009-08-05 Thread Ford, Mike
as in the GROUP BY column. So: SELECT count(*) AS `CountUniqueDatesInMyTbl`, date(solarAWDateTime) AS `uniqueDate`, 'aweber_7solar_aw' AS `tableAlias` FROM aweber_7solar_aw GROUP BY `uniqueDate`; That's how I'd write it, anyway. Cheers! Mike -- Mike Ford, Elec

RE: [PHP-DB] losing MySQL resource

2009-11-11 Thread Ford, Mike
n in the script. Is this incorrect? Yes. It has to be before any actual *output*, but it would be perfectly valid to have umpteen thousand lines of PHP before session_start() so long as all the output came after it. Cheers! Mike -- Mike Ford, Electronic Information Developer, Libraries

RE: [PHP-DB] Re: Stuck in apostrophe hell

2010-08-04 Thread Ford, Mike
$_POST[prid], > > > '%s',". > > You need double-quotes here, > \"%s\", No, he doesn't. Single quotes are fine. Doubles would more than likely be a SQL error. > > > parseNull($_POST['Company']).", > > >

[PHP-DB] Configuring PHP with GD and JPEG support

2011-01-10 Thread mike dorian
Hello, Questions with regards to compiling PHP to support GD with JPEG on 64-bit CentOS 5.5. 1) Specifying folder for jpeg library When I execute the following command, am I saying the full path to libdir is at /usr/source/lib64? ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-gd

RE: [PHP-DB] Configuring PHP with GD and JPEG support

2011-01-15 Thread mike dorian
Just tried it with the following but still fails. All I'm getting is a blank page. > From: k...@designdrumm.com > Date: Mon, 10 Jan 2011 17:10:35 -0600 > To: php-db@lists.php.net > Subject: Re: [PHP-DB] Configuring PHP with GD and JPEG support > > > On Jan 10, 201

RE: [PHP-DB] SELECT

2011-10-18 Thread Ford, Mike
essages` WHERE (month>`start_month` AND month<`end_month`) OR (month=`start_month AND day>=`start_day`) OR (month=`end_month` AND day<=`end_day`); Cheers! Mike -- Mike Ford, Electronic Information Developer, Libraries and Learning Innovation, Portland PD507, City

RE: [PHP-DB] SELECT

2011-10-21 Thread Ford, Mike
> -Original Message- > From: tamouse mailing lists [mailto:tamouse.li...@gmail.com] > Sent: 20 October 2011 21:37 > > On Tue, Oct 18, 2011 at 5:36 AM, Ford, Mike > wrote: > >> -Original Message- > >> From: Ron Piggott [mailto:ron.pigg...@actsm

RE: [PHP-DB] Re: Formatting

2012-11-26 Thread Ford, Mike
ous. > > $args[] = &$_POST[$k]; // Note the addition of the ampersand here That's a perfectly valid reference assignment. Please see the Fine Manual at: http://php.net/manual/language.references.whatdo.php Cheers! Mike -- Mike Ford, Electronic Information Developer, Libraries

Re: [PHP-DB] Newbie Question $2

2014-06-16 Thread Mike Stowe
t; I'd also really suggest looking at using PDO or even the mysqli extension tho instead of just plain mysql (believe this has been deprecated). Sorry for the quick reply, on mobile. But feel free to email me directly and I'll be happy to help out more. - Mike Sent from my iPhone &

RE: [PHP-DB] Corn job anomaly

2016-09-27 Thread Ford, Mike
\"' at line 1 I don't think INTERVAL works like that - you probably need something like: ... cf.Earliest_Pickup <= DATE_ADD(CURDATE(), INTERVAL ".($Num_Days_Away+1)." DAY) AND ... Incidentally, as I understand it CURDATE() does exactly the same as DATE(NOW()), a

RE: [PHP-DB] PostgreSQL on Windows

2003-12-09 Thread Mike U. Petrov
I think yes. For more information see http://techdocs.postgresql.org/guides/InstallingOnWindows Mike U. Petrov -Original Message- From: Rosen [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 09, 2003 6:50 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] PostgreSQL on Windows Hi, Can I

[PHP-DB] Very complex query

2003-12-11 Thread Mike U. Petrov
And for each of obtained user_id I need it's nick and it's date. Does anyone know how to do it just by one mysql query? Thanx... Mike U. Petrov -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP-DB] Re: Very complex query

2003-12-11 Thread Mike U. Petrov
Do u have any other ideas? Mike U. Petrov -Original Message- From: Justin Patrin [mailto:[EMAIL PROTECTED] Sent: Thursday, December 11, 2003 10:53 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Re: Very complex query Use unique(user_id). And please don't reply to a previous post when p

RE: [PHP-DB] Re: Very complex query

2003-12-11 Thread Mike U. Petrov
No, DISTINCT isn't match my purpose cause of it rerurns unique rows but I need ONE user_id per one object_id. Mike U. Petrov -Original Message- From: Muhammed Mamedov [mailto:[EMAIL PROTECTED] Sent: Thursday, December 11, 2003 11:01 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-D

RE: [PHP-DB] Re: Very complex query

2003-12-11 Thread Mike U. Petrov
I tried to use GROUP BY and it worked almost right but i need to return user_id and mysql generated an error that notes.user_id isn't used in GROUP BY... Mike U. Petrov -Original Message- From: Justin Patrin [mailto:[EMAIL PROTECTED] Sent: Thursday, December 11, 2003 11:25 AM To: [

RE: [PHP-DB] SQL question

2003-12-11 Thread Ford, Mike [LSS]
ntax? SELECT * FROM x_table WHERE name LIKE "%part_of_name%" Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graha

RE: [PHP-DB] Another question

2003-12-15 Thread Mike U. Petrov
I think no. IMHO PHP can't have effect on user's programs. If I'm not right correct me. But window.close can close window opened not by javascript. It just ask user is he want to close or no. Mike U. Petrov PHP-programmer. -Original Message- From: Constantin Brinzoi

RE: [PHP-DB] Another question

2003-12-15 Thread Mike U. Petrov
I've tried to use this function, but it doesn't work on IE 5.0 On Opera 7.21 it works. So on what browser you've tested it? Mike U. Petrov -Original Message- From: Duane Lakoduk [mailto:[EMAIL PROTECTED] Sent: Monday, December 15, 2003 4:18 PM To: 'Constantin Brinzo

RE: [PHP-DB] Search Query

2003-12-18 Thread Ford, Mike [LSS]
t; . " and col2 = '$foo' " > $table .= "db_table"; > > $query = "select * from ".$table." where ".$criteria; > > when i try to echo $query, i get --- select * from where > > and so of course MySQL

RE: [PHP-DB] inserting dynamic drop down menu data into mysql

2004-01-07 Thread Ford, Mike [LSS]
extract($row); $output .= " value=$category>$category"; Yup, here it is -- quote the argument to the value= attribute, and everything should be hunky dorey. Cheers! Mike -- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & I

RE: [PHP-DB] Quick Question: Line Breaks

2004-01-09 Thread Ford, Mike [LSS]
you could use a multi-line string -- but this time double-quoted to give interpolation (but note that you now have to escape all your embedded double quotes): echo " ... "; Which route you choose is pretty much personal taste -- personally, if I have a page that's mostl

RE: [PHP-DB] Inserting querydata as default value in form

2004-01-28 Thread Ford, Mike [LSS]
re". Then only the > first word show. Oh dear, it's HTML 101 time again. Quote your attribute values! Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning &

RE: [PHP-DB] oracle: fetch a query result into an array

2004-02-18 Thread Ford, Mike [LSS]
ult($stmt,'COLUMN_NAME'); > $counter++; } You might also want to look up ocifetchstatement (http://www.php.net/ocifetchstatement). Cheers! Mike -- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, Ja

RE: [PHP-DB] Two Column Sort

2004-03-04 Thread Ford, Mike [LSS]
Well, your going to need an order phrase that looks like this: ORDER BY CBC DESC, NET_RECEIPTS ASC so you may need a little rethink about how you're passing those arguments. Cheers! Mike - Mike Ford, Electronic I

RE: [PHP-DB] Two Column Sort

2004-03-05 Thread Ford, Mike [LSS]
On 04 March 2004 19:04, [EMAIL PROTECTED] wrote: > On Thu, 4 Mar 2004 10:55:20 -, Ford, Mike [LSS] > <[EMAIL PROTECTED]> wrote: > > > On 03 March 2004 17:07, [EMAIL PROTECTED] wrote: > > > > > Here's the php code for the sort

RE: [PHP-DB] ocistatement

2004-03-05 Thread Ford, Mike [LSS]
;NAME' => Array ('name1', 'name2', 'name3', ...) ) So the rows of your query result are: $arr['ID'][0], $arr['NAME'][0] $arr['ID'][1], $arr['NAME'][1] $arr['ID'][2], $arr['NAME'

RE: [PHP-DB] Two Column Sort

2004-03-05 Thread Ford, Mike [LSS]
On 05 March 2004 14:49, Ken Colburn wrote: > Mike - > > I've tried your options and I get either an error message, no > sorting, or sorting that does not do both columns with B's at the > top. It's my understanding that I must still use sort_field and > sort_or

RE: [PHP-DB] win32 Timestamp problem

2004-03-10 Thread Ford, Mike [LSS]
ix. > Any help would be appreciated. Have you looked at the Calendar extension? http://www.php.net/calendar Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & In

RE: [PHP-DB] How to redirect after a valid login

2004-03-15 Thread Ford, Mike [LSS]
t; include( "mainmenu.php" ); //note parenthesies Nope. Perfectly valid without the parentheses -- do it all the time. Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learn

RE: [PHP-DB] quotations in value field

2004-04-14 Thread Ford, Mike [LSS]
mbination of htmlspecialchars and some > other function > to convert it back, before it gets sent of in the _plain text mails_. You don't need to convert it back -- that happens automatically when the form is resubmitted. Cheers! Mike ----

RE: [PHP-DB] Image / file uploader

2004-04-30 Thread Ford, Mike [LSS]
in an echo statement. What > am I missing? Curly braces: echo (" Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Gra

RE: [PHP-DB] [PHP]: session problem

2004-06-25 Thread Ford, Mike [LSS]
HP helpfully provides, thusly: header("Location: user.php?action=0&".SID); or, if you're a tidy-URL geek, something like: header("Location: user.php?action=0".(SID?"&".SID:"")); (BTW, notice the correct spelling of the "

RE: [PHP-DB] More problems with searching

2004-07-01 Thread Ford, Mike [LSS]
> $query = "SELECT * FROM keyword WHERE 1 " > > $words = explode(' ',$_GET['search_text']); > > foreach($words as $word) > > { $query .= " AND keyword = '$word' "; } > > Shouldn't that be OR? ... and, if it sh

RE: [PHP-DB] More problems with searching

2004-07-02 Thread Ford, Mike [LSS]
osted an example of this to the list). But both ways can be considered valid approaches -- it just depends on what seems better (or more elegant, if you like!) to you. > - Original Message - > From: "Ford, Mike [LSS]" <[EMAIL PROTECTED]> > > > On

RE: [PHP-DB] Date problem: data is current as of yesterday

2004-07-03 Thread Ford, Mike [LSS]
want: $yesterday = mktime(12, 0, 0, $today['mon'], $today['mday']-1, $today['year']); echo "Data is current as of ".date("F j, Y", $yesterday); (Note the use of time 12:00:00 to avoid daylight savings

RE: [PHP-DB] OCI8

2004-08-13 Thread Ford, Mike [LSS]
t;; > OCILogoff($conn); > $err=OCIError($conn); > OCILogoff($conn); > sleep(10); > } > > > > when i execute it, the number of fd on ocius.msg is growing. but > there is only 1 connection at database. > > Can someone help me ? Cheers! Mike --

RE: [PHP-DB] Check Boxes

2004-08-18 Thread Ford, Mike [LSS]
} > } > $sql .= ' FROM form'; $sql = 'SELECT ' . implode(', ', $chkboxes) . 'FROM form'; Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Servi

RE: [PHP-DB] Check Boxes

2004-08-18 Thread Ford, Mike [LSS]
On 18 August 2004 15:53, John Holmes wrote: > Ford, Mike [LSS] wrote: > > > > $chkboxes = $_POST['ch']; > > > $sql = 'SELECT '; > > > foreach($chkboxes as $k => $v) > > > { > > > $sql .= $

RE: [PHP-DB] I have a CR-LF problem when pulling stuff out of my DB

2004-08-19 Thread Ford, Mike [LSS]
On 19 August 2004 17:02, Michael Cortes wrote: > ctrl-m is a carriage return. Does anyone know what ctrl seqence is > line feed? ctrl-j (CR and LF are ASCII codes 13 and 10, so ctrl+ the 13th and 10th letters of the alphabet respectively!) Cheers!

RE: [PHP-DB] Re: Checkboxes in a table

2004-08-20 Thread Ford, Mike [LSS]
t will only ever see checkboxes which are checked -- unchecked ones won't be trnsmitted. So just foreach() over the received array, and the indexes you see are for the checked boxes: foreach ($_POST['checkbox'] as $key=>$irrelevant): // checkbox[$key] was checked end

RE: [PHP-DB] Re: Checkboxes in a table

2004-08-20 Thread Ford, Mike [LSS]
> -Original Message- > From: Ford, Mike [LSS] > Sent: 21/08/04 01:57 > foreach ($_POST['checkbox'] as $key=>$irrelevant): > // checkbox[$key] was checked > endif; OK, it's 2a.m. here and I'm about asleep, whioch is why t

RE: [PHP-DB] Inserting a ' into mySQL

2004-08-20 Thread Ford, Mike [LSS]
if an ' is keyed why it wouldn't save > and that line would create an error --- How do you work around this? That's what mysql_real_escape_string() is for -- http://www.php.net/mysql_real_escape_string. Cheers! Mike -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] Simple Search Function

2002-02-06 Thread Mike de Libero
nning MySQL 2.23.32 and have php 4 installed. I'm using the search with 5 different fields/columns in one table and 2 fields/columsn in another. Thanks for you help. TIA, Mike

Re: [PHP-DB] passing array through $PHP_SELF

2002-03-18 Thread Mike de Libero
to form again. Hope this helps. -Mike de Libero [EMAIL PROTECTED] http://www.soreye.com - Original Message - From: "John Hughes, Jomari Works" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, March 18, 2002 5:27 PM Subject: [PHP-DB] passing array through $PHP_

[PHP-DB] Creating a good search engine

2002-03-22 Thread Mike de Libero
d in the right direction. Hope you guys can help. -Mike de Libero [EMAIL PROTECTED] http://www.soreye.com

Re: [PHP-DB] using multiple checkboxes to delete from db

2002-03-30 Thread Mike de Libero
Or something of that sort. Hope it helps. -Mike [EMAIL PROTECTED] http://www.soreye.com - Original Message - From: "wesley grubbs:." <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, March 30, 2002 4:58 AM Subject: [PHP-DB] using multiple chec

Re: [PHP-DB] Database search question

2002-03-30 Thread Mike de Libero
ds IN ($query) it might be INTO but I'm dang sure it is IN. Go to Zend.com and phpbuilder.com for some good resources on search engines you can modify it to suit your needs. I this helps a little bit. -Mike - Original Message - From: "Chris Payne" <[EMAIL PROTECTED]

[PHP-DB] Using OCI, can I retrieve multiple values from DELETE/UPDATE RETURNING?

2002-05-01 Thread Ford, Mike [LSS]
lous that I should have to do a SELECT/DELETE pair, when Oracle provides such a useful feature to get the same result in a single statement. Cheers! Mike ---- Mike Ford, Electronic Information Services Adviser, Learning Support Services

RE: [PHP-DB] Retrieving a date from Oracle. Please help!

2002-05-23 Thread Ford, Mike [LSS]
OCIExecute($stmt); * Change the default value of the Oracle initialization parameter NLS_DATE_FORMAT (I haven't tried this either, as I don't have administrative control of my Oracle database!). Cheers! Mike - Mike Ford,

RE: [PHP-DB] Retrieving a date from Oracle. Please help!

2002-05-23 Thread Ford, Mike [LSS]
OCIExecute($stmt); * Change the default value of the Oracle initialization parameter NLS_DATE_FORMAT (I haven't tried this either, as I don't have administrative control of my Oracle database!). Cheers! Mike - Mike Ford,

RE: [PHP-DB] Re: Not associated with a trusted SQL Server error

2002-05-30 Thread Ford, Mike [LSS]
, there is a bug-reporting system at http://bugs.php.net/ Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graham Building, Leeds Metr

RE: [PHP-DB] MySQL/PHP dropping characters

2002-09-24 Thread Ford, Mike [LSS]
ething like that). If you don't need that support, you should turn it off -- search the bug database for the appropriate bugs, which will give you more information than my brain can! Cheers! Mike ----- Mike Ford, Electr

RE: [PHP-DB] getting mysql_fetch_row into array

2002-09-24 Thread Ford, Mike [LSS]
x27;t that do? If you don't want to refer to it using the additional first subscript every time, just create a reference to it: $b = &$a[0]; then $b[$x] is the same as $a[0][$x]. Cheers! Mike - Mike Ford,

RE: [PHP-DB] Oracle connection problem after call to unserialize()

2002-09-24 Thread Ford, Mike [LSS]
cript an OCILogon (or OCIPLogon) in every page that needs to access your database. (This is true not just for Oracle -- all the databases supported in PHP that I've looked at work the same way.) Cheers! Mike - Mike Ford, Elec

RE: [PHP-DB] Session understanding

2002-09-26 Thread Ford, Mike [LSS]
e directories. All of my PHP scripts that Apache can serve as "top-level" scripts look pretty much like this: Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning &a

RE: [PHP-DB] Current row of query

2002-09-26 Thread Ford, Mike [LSS]
probably then go on to rewrite the if line using the ?: operator instead: $bgCol = ($rowNum++ % 2) ? "#EADBC6" : "#EFE1CE"; Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support

RE: [PHP-DB] echo printing a cookie

2002-10-15 Thread Ford, Mike [LSS]
okie["cookiename"]== TRUE) { > echo"your cookie is" $_COOKIE["cookiename"]""; > } if (isset($_COOKIE['cookiename'])) { echo "your cookie is {$_COOKIE['cookiename']}"; } Cheers! Mike

RE: [PHP-DB] Oracle problem

2002-10-16 Thread Ford, Mike [LSS]
magic_quotes_sybase -- although personally I prefer not to use these as I'm averse to magic (well, other people's, anyway!). Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Serv

RE: [PHP-DB] losing my session variables

2002-10-30 Thread Ford, Mike [LSS]
e other problems which make it best to stick to manipulating the values in $_SESSION directly, rather than using the "equivalent" global variables. Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learni

RE: [PHP-DB] Passing multiple form variable in PHP

2002-11-12 Thread Ford, Mike [LSS]
x27;] will be an array of the selected values. Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graham Building, Leeds Metropolitan

RE: [PHP-DB] HTML Forms question...

2002-11-19 Thread Ford, Mike [LSS]
.form["system"] By extension, if you have multiple checkboxes all named with name="system[]", you can refer to them as: document.form["system[]"][0] document.form["system[]"][1] docume

[PHP-DB] RE: Access to Oracle db from PHP script

2002-11-28 Thread Ford, Mike [LSS]
for > me how to do > > to make. > > > > Can you have same sample code to connect to Oracle db for me. > > > > At this moment I do not know how it is the version of the > oracle but I > > think it is 8.i > > > > I hope do not trouble you a

RE: [PHP-DB] php session

2002-12-02 Thread Ford, Mike [LSS]
using cookies to store the SID. When this is the case, you see the SID on the first page served by PHP (because it hasn't set the cookie yet!), but on all subsequent pages it disappears and the SID is propagated using a cookie. You *can* configure this to work differently, but, speaking purely pe

RE: [PHP-DB] Re: Array not supported for strings???

2002-01-08 Thread Ford, Mike [LSS]
> Fatal error: [] operator not supported for strings Is this error coming from PHP or your database? And does it definitely refer to this particular line? Cheers! Mike - Mike Ford, Electronic Information Services Adviser,

RE: [PHP-DB] Oracle date conversion

2002-01-08 Thread Ford, Mike [LSS]
would give you something like: SELECT TO_CHAR(DATE, 'DD-MON-YY HH:MI:SS') AS DATE_TIME FROM TBL Look up the definition of the TO_CHAR function for the full list of format elements available for formatting DATEs. Cheers! Mike ----

RE: [PHP-DB] oracle connectivity problem

2002-01-08 Thread Ford, Mike [LSS]
installed Oracle 8 support (--with-oci8), which gives you the OCI functions, or only the older Oracle support (--with-oracle) which gives you the ORA_ series of functions? Cheers! Mike - Mike Ford, Electronic Information S

RE: [PHP-DB] mysql_num_rows

2002-01-08 Thread Ford, Mike [LSS]
t; doesn't. Have you echoed $result to see what it contains? My guess is that it contains something unexpected which, when inserted into the query, causes it to fail (or at least return no rows!). Otherwise, I can see no reason for

RE: [PHP-DB] mysql_num_rows

2002-01-08 Thread Ford, Mike [LSS]
es it to fail (or at least return no > rows!). Otherwise, I can see no reason for the addition of > the WHERE clause to cause this error. Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Su

RE: [PHP-DB] mysql_num_rows

2002-01-08 Thread Ford, Mike [LSS]
ot > sure if that's > the problem, or if it's just good practice? Depends on whether $bookid is a string or a number. If your id values are always numeric, there's really no point in quoting them in the query. On the other hand, if t

RE: [PHP-DB] RE: adding in arrays

2002-12-10 Thread Ford, Mike [LSS]
; Can you help me with it, am really not good at arrays. Is this what you want: foreach ($array as $year=>$value): // do stuff endforeach; > > Array ( [2000] => 300 [2002] => 740 [2003] => 200 [

RE: [PHP-DB] Global variables

2002-12-10 Thread Ford, Mike [LSS]
> -Original Message- > From: Jim [mailto:[EMAIL PROTECTED]] > Sent: 10 December 2002 18:51 > > Can I define a global variable in a function and then > successfully reference > it in the rest of the page? Yes. (Why didn't you ju

RE: [PHP-DB] Update Query Help...

2002-12-11 Thread Ford, Mike [LSS]
like this that is ambiguous -- and in MySQL that's with ` back ticks. (Other databases have other means of doing this -- or just restrict column names to avoid the issue!) Cheers! Mike - Mike Ford, Electronic Information Se

RE: [PHP-DB] Final question of the week :-)

2002-12-11 Thread Ford, Mike [LSS]
way. $sql = 'SELECT ... WHERE id IN (' . implode(',' $selection) . ')'; Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Informatio

RE: [PHP-DB] Sessions problems

2003-01-06 Thread Ford, Mike [LSS]
p:8) in > /var/www/html/prueba/index.php on line 10 Same thing, but for a cache limiter header. You need to re-order your script so that the header requests come before the start of real output. Cheers! Mike - Mike Ford, E

RE: [PHP-DB] sorting matrix

2003-01-13 Thread Ford, Mike [LSS]
ranslated into Romanian, but unfortunately not this page!). Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graham Building, Leeds Met

RE: [PHP-DB] Concatenate two strings

2003-01-15 Thread Ford, Mike [LSS]
or2 > > Can someone help me. Thanks. http://www.php.net/manual/en/language.operators.string.php Cheers! Mike ----- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Se

RE: [PHP-DB] getting client browser info

2003-01-20 Thread Ford, Mike [LSS]
the same because they *are* the same: $HTTP_USER_AGENT is the register_globals copy of the $_SERVER[] element. Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Informa

RE: [PHP-DB] getting client browser info

2003-01-20 Thread Ford, Mike [LSS]
ents to distinguish what > they're using. example msie 5.1 - netscape - aol...And act upon it. Perhaps you might want to look at the get_browser() function: http://www.php.net/get-browser Cheers! Mike ----- Mike Ford,

RE: [PHP-DB] getting client browser info

2003-01-20 Thread Ford, Mike [LSS]
illa-compatible. ALL versions of IE do exactly the same -- you have to look at the end of the parenthesis following it to get the real version information (in this case, MSIE 6.0). Cheers! Mike - Mike Ford, Electronic Informa

RE: [PHP-DB] Re: problems with variables

2003-02-04 Thread Ford, Mike [LSS]
> -Original Message- > From: Mark [mailto:[EMAIL PROTECTED]] > Sent: 04 February 2003 14:38 > > Just a quick correction... if the "q" part is static, I believe you > should use $(q$i) rather than ${$q . $i} Well, actually, I think you want ${'q'.

RE: [PHP-DB] More help with mysql -- solved (bizarre)

2003-02-18 Thread Ford, Mike [LSS]
ed to $result; because PHP uses short-circuit evaluation, the die() is still only executed if mysql_query returns FALSE, but the || operator still returns a simple Boolean to be assigned to $result -- which, if the die() hasn't fired, must be TRUE (which PHP generally prints as 1). QED. Ch

RE: [PHP-DB] Final Date Question :-)

2003-02-20 Thread Ford, Mike [LSS]
ate time of day with gmmktime() so as to eliminate DST shift vagaries entirely!) Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Gr

RE: [PHP-DB] Re: Does Php support Flash files ?

2003-03-20 Thread Ford, Mike [LSS]
es, it is considered rude in our culture. :D Not only rude, but, to someone of my age and upbringing, extremely offensive. Even though it has become more commonly used over the 30 years since the one and only time I used it in the presence of my father, I still wince mentally every time I

RE: [PHP-DB] Re: deleting records using a checkbox

2003-03-21 Thread Ford, Mike [LSS]
document["example"]["delete"] And, of course, an obvious extension of this is that if the input element on your form is: you can refer to this as: document.example["delete[]"] This is just a basic recipe -- add your own ingredients, and mix and cook

RE: [PHP-DB] while - if - problem

2003-06-05 Thread Ford, Mike [LSS]
case 'CB': $r_away['sport']='2'; $r_home['sport']='2'; $s_lt='PS'; $t_lt='TP'; break; case 'B': $r_away['sport']='3'; $r_home['sport'

RE: [PHP-DB] PHP sort from .... best solution?

2003-06-06 Thread Ford, Mike [LSS]
ort and has no return value, so you just want: usort($ingresser, 'obj_date_compare'); Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, J

RE: [PHP-DB] PHP sort from .... best solution?

2003-06-06 Thread Ford, Mike [LSS]
English is fine -- if you hadn't mentioned it, I probably wouldn't have guessed that you're not a native speaker! Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning Support Services

RE: [PHP-DB] Multiple inserts revisited

2003-05-29 Thread Ford, Mike [LSS]
ble-checked it and it does, then this is a somewhat more compact way of producing it: $query = "INSERT INTO specials VALUES (" . implode(',', $specials) . ')' Cheers! Mike - Mike Ford, Electron

RE: [PHP-DB] Array Pointer

2003-06-04 Thread Ford, Mike [LSS]
> -Original Message- > From: Ian Fingold [mailto:[EMAIL PROTECTED] > Sent: 03 June 2003 16:58 > > Ok I'm trying to write this function to up date some fields > in my database > so i'm grabbing some info from a query and throwing it into > an array (with > mysql_fetch_array). > > one of

RE: [PHP-DB] PHP sort from a database variable..?

2003-06-04 Thread Ford, Mike [LSS]
if($ingresser = array_merge($i1 ,$i2)) { $ingresser = usort($ingresser, 'obj_date_compare'); listIngresser($ingresser); } Cheers! Mike - Mike Ford, Electronic Information Services Adviser, Learning

RE: [PHP-DB] Is this query even possible?

2003-06-10 Thread Ford, Mike [LSS]
fully-blown if(), like this: $sql = "UPDATE newdacs" . " SET emailfwd='$emailfwd'" . ",mformat='$mformat'" . ",filter_code='$filter_code'"; i

<    1   2   3   4   5   >