Re: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread Nisse Engström
On Wed, 17 Jun 2009 22:51:55 +0100, Ashley Sheridan wrote: > I read somewhere that the XHTML standards say that for all attributes > that would normally be standalone in HTML, they should be given a value > that is the same as the attribute name, so you would use > multiple="multiple", selected="s

Re: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread Nisse Engström
On Wed, 17 Jun 2009 18:59:36 -0400, tedd wrote: > As I understand it and is my experience, that is > true -- a stand-alone HTML attribute should be > equal to itself, such as selected="selected", or In HTML (as opposed to XHTML), there are a bunch of shortcut features[1] that allow you to writ

RE: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Ford, Mike
On 17 June 2009 15:01, PJ advised: > It does, indeed. This confirms my inexperienced conclusion that > in_array() does not work on associative arrays per se; it works on > simple arrays and I just don't have the experience to think of > extracting only the id fields. Let's squash this misconcepti

RE: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread Ford, Mike
On 17 June 2009 22:05, Nisse Engström advised: > On Wed, 17 Jun 2009 10:18:09 +0100, "Ford, Mike" wrote: > >> This is very true -- but XHTML requires *all* attributes to have a >> value, so an XHTML conformant page will use > name="selector"> (or something similar such as > name="selector">). The

RE: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Ford, Mike
On 17 June 2009 14:30, PJ advised: > For the moment, I am trying to resolve the problem of > extracting a value > from a string returned by a query. I thought that in_array() would do > it, but the tests I have run on it are 100% negative. The only thing I > have not used in the tests is third pa

RE: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Ford, Mike
On 17 June 2009 22:12, tedd advised: > Hi gang: > > Here's the problem. Let's say you have a collection of > arrays, such as: > > $a = array(); > $b = array(); > $c = array(); > $d = array(); > > And then you populate the arrays like so: > > while(...) > { > $a[] = ... > $b[] = ...

RE: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread Ford, Mike
On 17 June 2009 23:56, PJ advised: > Nisse Engström wrote: >> On Wed, 17 Jun 2009 10:18:09 +0100, "Ford, Mike" wrote: >> >> >>> This is very true -- but XHTML requires *all* attributes to have a >>> value, so an XHTML conformant page will use >> name="selector"> (or something similar such as >>

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Peter Ford
PJ wrote: > I'm including the relevant code: > > // select categories for book to be updated > $sql = "SELECT id, category FROM categories, book_categories > WHERE book_categories.bookID = '$bid' && > book_categories.categories_id = categories.id"; > if ( ( $results = mysql_query($sql, $db

[PHP] Object of class could not be converted to string

2009-06-18 Thread Angelo Zanetti
Dear all, We are experiencing this error: "Object of class xxxClass could not be converted to string" I have searched google a lot mostly the results are for Drupal or badly coded sites. I have further found out that the issue is with PHP 5.2 version. There isn't a problem with the script as

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Robert Cummings
Ford, Mike wrote: On 17 June 2009 22:12, tedd advised: Hi gang: Here's the problem. Let's say you have a collection of arrays, such as: $a = array(); $b = array(); $c = array(); $d = array(); And then you populate the arrays like so: while(...) { $a[] = ... $b[] = ... $c[]

RE: [PHP] Object of class could not be converted to string

2009-06-18 Thread Yuri Yarlei
But what you trying to pass to the variable? I already see this error, but I see when I write $$ in the variable, you can see if you have some $$ in variables or try casting type with the function settype(); ex: settype($foo, "array"); settype($foo, "integer"); settype($foo, "string"); Or maybe

RE: [PHP] Object of class could not be converted to string

2009-06-18 Thread Yuri Yarlei
But what you trying to pass to the variable? I already see this error, but I see when I write $$ in the variable, you can see if you have some $$ in variables or try casting type with the function settype(); ex: settype($foo, "array"); settype($foo, "integer"); settype($foo, "string"); Or ma

Re: [PHP] how to extract fields from associative array into different variables

2009-06-18 Thread Nisse Engström
On Tue, 16 Jun 2009 08:50:45 -0400, PJ wrote: > Ashley Sheridan wrote: >> On Mon, 2009-06-15 at 17:38 -0400, PJ wrote: >> >>> Then I have to add some loopy thing to assign the values to the >>> $variables... a real pita since my variable do not lend themselves too >>> well to linear alterations

RE: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Bob McConnell
From: Ashley Sheridan > On Wed, 2009-06-17 at 19:27 -0400, tedd wrote: >> At 10:54 PM +0100 6/17/09, Ashley Sheridan wrote: >> >I'd probably go with some sort of custom bubble sorting function. Base >> >the sorting on your $d array, and then update the other arrays as >> >necessary. Should be OK if

RE: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Bob McConnell
From: Ashley Sheridan > On Wed, 2009-06-17 at 19:27 -0400, tedd wrote: >> At 10:54 PM +0100 6/17/09, Ashley Sheridan wrote: >> >I'd probably go with some sort of custom bubble sorting function. Base >> >the sorting on your $d array, and then update the other arrays as >> >necessary. Should be OK if

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread PJ
Stuart wrote: > 2009/6/18 PJ : > >> I snipped to make it short... continue at bottom... >> >>> Step back from the code and consider the steps you need to perform... >>> >>> 1) Get an array of the categories, ideally in the form $cats[] >>> = categoryname. >>> >>> 2) Get an array of the cate

RE: [PHP] how to extract fields from associative array into different variables

2009-06-18 Thread Yuri Yarlei
You can try use the foreach function. ex: if ($res = mysql_query ($sql, $db)) { /* I personally prefer "res" for "resource", not "results" */ while ($r = mysql_fetch_assoc ($res)) { $rows[] = $r; } } foreach ($rows as $row){ echo $row['first_name']; echo ""; } the foreach function trans

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Stuart
2009/6/18 PJ : > Stuart wrote: >> 2009/6/18 PJ : >> >>> I snipped to make it short... continue at bottom... >>> Step back from the code and consider the steps you need to perform... 1) Get an array of the categories, ideally in the form $cats[] = categoryname. 2) Get a

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread PJ
Ford, Mike wrote: > On 17 June 2009 15:01, PJ advised: > > >> It does, indeed. This confirms my inexperienced conclusion that >> in_array() does not work on associative arrays per se; it works on >> simple arrays and I just don't have the experience to think of >> extracting only the id fields.

Re: [PHP] Object of class could not be converted to string

2009-06-18 Thread Martin Scotta
PHP tries to convert the class to string, but he can't because in your class is missing the __toString magic method. try to add this one and the error must be gone. On Thu, Jun 18, 2009 at 9:06 AM, Yuri Yarlei wrote: > > But what you trying to pass to the variable? > > I already see this error,

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Daniel Brown
On Thu, Jun 18, 2009 at 05:11, Ford, Mike wrote: > > array_multisort($d, $a, $b, $c) should do what you want, That'll actually hit it right on the head, too, Mike. My example from last night sorted and combined the arrays to be keyed and sortable by $d --- which, re-reading this morning, is n

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread PJ
Ford, Mike wrote: > On 17 June 2009 14:30, PJ advised: > > > >> For the moment, I am trying to resolve the problem of >> extracting a value >> from a string returned by a query. I thought that in_array() would do >> it, but the tests I have run on it are 100% negative. The only thing I >> have n

Re: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread PJ
Ford, Mike wrote: > On 17 June 2009 23:56, PJ advised: > > >> Nisse Engstr�m wrote: >> >>> On Wed, 17 Jun 2009 10:18:09 +0100, "Ford, Mike" wrote: >>> >>> >>> This is very true -- but XHTML requires *all* attributes to have a value, so an XHTML conformant page will use >>>

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Martin Scotta
It is a sintax error if (in_array($ex, $selected) <--- missing ) echo "yes"; else echo "no"; On Thu, Jun 18, 2009 at 10:13 AM, PJ wrote: > Ford, Mike wrote: > > On 17 June 2009 14:30, PJ advised: > > > > > > > >> For the moment, I am trying to resolve the problem of > >> extracting a value >

Re: [PHP] how to extract fields from associative array into different variables

2009-06-18 Thread PJ
Nisse Engström wrote: > On Tue, 16 Jun 2009 08:50:45 -0400, PJ wrote: > > >> Ashley Sheridan wrote: >> >>> On Mon, 2009-06-15 at 17:38 -0400, PJ wrote: >>> >>> Then I have to add some loopy thing to assign the values to the $variables... a real pita since my variable do

Re: [PHP] how to extract fields from associative array into different variables

2009-06-18 Thread Eddie Drapkin
Total nitpick, but foreach is a control structure, not a function :P On Thu, Jun 18, 2009 at 8:40 AM, Yuri Yarlei wrote: > > You can try use the foreach function. > > ex: > if ($res = mysql_query ($sql, $db)) { >  /* I personally prefer "res" for "resource", not "results" */ >  while ($r = mysql_f

Re: [PHP] how to extract fields from associative array into different variables

2009-06-18 Thread PJ
Yuri Yarlei wrote: > You can try use the foreach function. > > ex: > if ($res = mysql_query ($sql, $db)) { > /* I personally prefer "res" for "resource", not "results" */ > while ($r = mysql_fetch_assoc ($res)) { > $rows[] = $r; > } > } > > > foreach ($rows as $row){ > echo $row['first_name'];

[PHP] aesthetic beauty in conception, execution

2009-06-18 Thread PJ
I just thought I would share a revelation. Someone just pointed me to a site that IMHO is superb for elegance of artistic design and programming. I was blown away. http://www.apfq.ca You won't regret it. 8-) -- Hervé Kempf: "Pour sauver la planète, sortez du capitalisme."

[PHP] Re: aesthetic beauty in conception, execution

2009-06-18 Thread Peter Ford
PJ wrote: > I just thought I would share a revelation. > Someone just pointed me to a site that IMHO is superb for elegance of > artistic design and programming. > I was blown away. > http://www.apfq.ca > You won't regret it. 8-) > Il y a seulement une problème - je ne lis pas Française... I18N

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Robert Cummings
PJ wrote: I just thought I would share a revelation. Someone just pointed me to a site that IMHO is superb for elegance of artistic design and programming. I was blown away. http://www.apfq.ca You won't regret it. 8-) Can I have my 5 minutes back please? It's about as simplistic a site as it g

[PHP] Re: aesthetic beauty in conception, execution

2009-06-18 Thread Shawn McKenzie
PJ wrote: > I just thought I would share a revelation. > Someone just pointed me to a site that IMHO is superb for elegance of > artistic design and programming. > I was blown away. > http://www.apfq.ca > You won't regret it. 8-) > Superb for a mass of validation errors. It must be in the design

[PHP] Can someone tell me why this is not working?

2009-06-18 Thread Gary
The center echo does not show. It will show if I replace $newmort with anything else. I have copied the first "if" statement,pasted it in the second position, and it works fine. Once I change the var to $newmort, it will not show. The third echo shows fine, it is only if I use newmort. I ha

Re: [PHP] Can someone tell me why this is not working?

2009-06-18 Thread Robert Cummings
Gary wrote: The center echo does not show. It will show if I replace $newmort with anything else. I have copied the first "if" statement,pasted it in the second position, and it works fine. Once I change the var to $newmort, it will not show. The third echo shows fine, it is only if I use

Re: [PHP] Can someone tell me why this is not working?

2009-06-18 Thread Gary
Thanks for your reply, but that is not it. I had already removed it$, slashed it, and no, plus it is working in the others. Gary "Robert Cummings" wrote in message news:4a3a5e7c.8000...@interjinn.com... > > > Gary wrote: >> The center echo does not show. It will show if I replace $newmort wi

[PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Shawn McKenzie
Gary wrote: > The center echo does not show. It will show if I replace $newmort with > anything else. I have copied the first "if" statement,pasted it in the > second position, and it works fine. Once I change the var to $newmort, it > will not show. The third echo shows fine, it is only if I

[PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
Nope, I added slashes to all of the $, still no go. Thank you for your help. Gary "Shawn McKenzie" wrote in message news:53.c2.08167.5206a...@pb1.pair.com... > Gary wrote: >> The center echo does not show. It will show if I replace $newmort with >> anything else. I have copied the first "if

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Bastien Koert
On Thu, Jun 18, 2009 at 11:44 AM, Gary wrote: > Nope, I added slashes to all of the $, still no go. > > Thank you for your help. > > Gary > > > "Shawn McKenzie" wrote in message > news:53.c2.08167.5206a...@pb1.pair.com... >> Gary wrote: >>> The center echo does not show.  It will show if I replace

[PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
Everything is exaclty the same, but this one will not work. I have retyped them, copied from those working, changed the name, changed the input name...If I change the var to $zip, it works. Any other suggestions? Thanks again. ""Gary"" wrote in message news:89.71.08167.d8d5a...@pb1.pair.com.

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Martin Scotta
if ($newmort) { echo "Mortgage Amount:$ $newmort"; } check $newmort value var_dump( $newmort ); if ($newmort) { echo "Mortgage Amount:$ $newmort"; } you "if" fails is $newmort is there but empty On Thu, Jun 18, 2009 at 1:11 PM, Gary wrote: > Everything is exaclty the same, but this one wil

Re: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread tedd
At 8:47 PM -0400 6/17/09, Robert Cummings wrote: tedd wrote: As I understand it and is my experience, that is true -- a stand-alone HTML attribute should be equal to itself, such as selected="selected", or more specifically selected="SELECTED". How is that MORE specific? XHTML is like a cro

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Kirk . Johnson
> [PHP] Re: Can someone tell me why this is not working? > > > The center echo does not show. It will show if I replace $newmort with > > anything else. I have copied the first "if" statement,pasted it in the > > second position, and it works fine. Once I change the var to $newmort, it >

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gabriel Sosa
on this line echo "Mortgage Amount:$ $newmort"; the echo is trying to evaluate the string... in your case you should escape the $ sign... like this \$ echo "Mortgage Amount:\$ $newmort"; regards On Jun 18, 2009, at 1:15 PM, Martin Scotta wrote: if ($newmort) { echo "Mortgage Amount:

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
Thanks...Now I get NULL I have another set of these if($) echo, and the all work, it is just this one that refuses to give it up. "Martin Scotta" wrote in message news:6445d94e0906180915o392d1500hd906b23dbf5c4...@mail.gmail.com... > if ($newmort) { > echo "Mortgage Amount:$ $newmort"; > } >

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Daniel Brown
On Thu, Jun 18, 2009 at 12:22, Gary wrote: > Thanks...Now I get NULL > > I have another set of these if($) echo, and the all work, it is just this > one that refuses to give it up. Gary, if you can, send the link to the live development copy on which you're working. Even if it's just a tempor

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
Thanks, but that is not it, have already slashed the $, but the others without the \ still work. "Gabriel Sosa" wrote in message news:c4316a8f-3ee4-43d0-9b30-c4b447428...@gmail.com... > on this line > >> echo "Mortgage Amount:$ $newmort"; > > the echo is trying to evaluate the string... > > in

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
Ok, I dont really know how it got working, but it is. I did try the test, and after that it worked, however I had tried one before But thank you all for your time and help. Gary wrote in message news:of24965909.4acbeaf3-on872575d9.00598a62-872575d9.0059e...@zootweb.com... >> [PHP] Re: C

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread PJ
Martin Scotta wrote: > It is a sintax error > > if (in_array($ex, $selected) <--- missing ) > echo "yes"; > else echo "no"; > > On Thu, Jun 18, 2009 at 10:13 AM, PJ > wrote: > > Ford, Mike wrote: > > On 17 June 2009 14:30, PJ advised: > > > > >

Re: [PHP] Re: aesthetic beauty in conception, execution

2009-06-18 Thread PJ
Peter Ford wrote: > PJ wrote: > >> I just thought I would share a revelation. >> Someone just pointed me to a site that IMHO is superb for elegance of >> artistic design and programming. >> I was blown away. >> http://www.apfq.ca >> You won't regret it. 8-) >> >> > > Il y a seulement une pr

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread PJ
Robert Cummings wrote: > PJ wrote: >> I just thought I would share a revelation. >> Someone just pointed me to a site that IMHO is superb for elegance of >> artistic design and programming. >> I was blown away. >> http://www.apfq.ca >> You won't regret it. 8-) > > Can I have my 5 minutes back pleas

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread Stuart
2009/6/18 PJ : > Martin Scotta wrote: >> It is a sintax error >> >> if (in_array($ex, $selected)   <--- missing ) >> echo "yes"; >> else echo "no"; >> >> On Thu, Jun 18, 2009 at 10:13 AM, PJ > > wrote: >> >>     Ford, Mike wrote: >>     > On 17 June 2009 14:30, PJ ad

Re: [PHP] Re: sloppiness & stupidity

2009-06-18 Thread Robert Cummings
tedd wrote: At 8:47 PM -0400 6/17/09, Robert Cummings wrote: tedd wrote: As I understand it and is my experience, that is true -- a stand-alone HTML attribute should be equal to itself, such as selected="selected", or more specifically selected="SELECTED". How is that MORE specific? XHTML is l

Re: [PHP] Re: aesthetic beauty in conception, execution

2009-06-18 Thread PJ
Shawn McKenzie wrote: > PJ wrote: > >> I just thought I would share a revelation. >> Someone just pointed me to a site that IMHO is superb for elegance of >> artistic design and programming. >> I was blown away. >> http://www.apfq.ca >> You won't regret it. 8-) >> >> > > Superb for a mass o

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Robert Cummings
PJ wrote: Robert Cummings wrote: PJ wrote: I just thought I would share a revelation. Someone just pointed me to a site that IMHO is superb for elegance of artistic design and programming. I was blown away. http://www.apfq.ca You won't regret it. 8-) Can I have my 5 minutes back please? It's a

[PHP] accessing level above $_SERVER['DOCUMENT_ROOT']

2009-06-18 Thread LAMP
hi, I have this structure: /home/lamp/mydomain/html /home/lamp/mydomain/logs /home/lamp/mydomain/config etc. html directory is the only one accessible from outside. to access config file I can use this: required_once('/home/lamp/mydomain/config'); but this is the structure on my local/developm

Re: [PHP] populate form input option dropdown box from existing data

2009-06-18 Thread PJ
Stuart wrote: > 2009/6/18 PJ : > >> Martin Scotta wrote: >> >>> It is a sintax error >>> >>> if (in_array($ex, $selected) <--- missing ) >>> echo "yes"; >>> else echo "no"; >>> >>> On Thu, Jun 18, 2009 at 10:13 AM, PJ >> > wrote: >>> >>> Ford, Mike wrot

Re: [PHP] Re: Can someone tell me why this is not working?

2009-06-18 Thread Gary
I was about to do something really stupid. I had gotten it to work (even a blind squirell gets a nut every now and again), and had copied the code to send to you to look at.and then realized it was working so you would be chasing ghosts. Thank you for your help. Gary "Daniel Brown" wr

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread PJ
Robert Cummings wrote: > PJ wrote: >> Robert Cummings wrote: >>> PJ wrote: I just thought I would share a revelation. Someone just pointed me to a site that IMHO is superb for elegance of artistic design and programming. I was blown away. http://www.apfq.ca You won't r

RE: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread tedd
At 10:11 AM +0100 6/18/09, Ford, Mike wrote: On 17 June 2009 22:12, tedd advised: -snip- > Now, let's say you want to sort the $d array, but you also want the > arrays $a, $b, and $c to be arranged in the same resultant order as $d. > For example, please follow this: Before sort of $d:

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread tedd
> Ash: You missed the point. I could use the built-in sort (i.e., sort() ) and sort the $d array. However, I would like the indexes of the other arrays to match the new sort. Cheers, > tedd > I think I might need a for-instance here, as you lost me! Thanks Ash Ash: You can sort an

Re: [PHP] sloppiness & stupidity

2009-06-18 Thread Eric Butera
On Tue, Jun 16, 2009 at 8:43 PM, PJ wrote some nonsense: > I'm sorry, guys, but I am really getting po'd. Fail. Please try again. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread tedd
At 12:43 PM -0400 6/18/09, Robert Cummings wrote: I'm Canadian as are you. Cheers, Rob. Oh that explains a lot. :-) Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http:/

Re: [PHP] Re: aesthetic beauty in conception, execution

2009-06-18 Thread Tom Worster
On 6/18/09 12:35 PM, "PJ" wrote: > Peter Ford wrote: >> PJ wrote: >> >>> I just thought I would share a revelation. >>> Someone just pointed me to a site that IMHO is superb for elegance of >>> artistic design and programming. >>> I was blown away. >>> http://www.apfq.ca >>> You won't regret i

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Paul M Foster
On Thu, Jun 18, 2009 at 12:39:35PM -0400, PJ wrote: > American movies, for the most part and what goes with them, are > pollution of the senses. My take, of course. ;-) :-P Clear proof you are insane. The Matrix. Alien. Terminator. Star Wars. Star Trek II: The Wrath of Khan. Cannibal Women in t

[PHP] PEAR Spreadsheet_Excel_Writer setLocked method

2009-06-18 Thread Skip Evans
Hey all, Any one use the PEAR Spreadsheet_Excel_Writer package? I need to know how to implement the setLocked method to lock out a cell, but can't figure out how this would be done. Do you add it as a format? But then how is it applied to a cell. It's not documented on the PEAR pages. Any

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread tedd
At 1:16 PM -0400 6/18/09, Paul M Foster wrote: On Thu, Jun 18, 2009 at 12:39:35PM -0400, PJ wrote: American movies, for the most part and what goes with them, are pollution of the senses. My take, of course. ;-) :-P Clear proof you are insane. The Matrix. Alien. Terminator. Star Wars. Sta

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Robert Cummings
tedd wrote: At 10:11 AM +0100 6/18/09, Ford, Mike wrote: On 17 June 2009 22:12, tedd advised: -snip- > Now, let's say you want to sort the $d array, but you also want the > arrays $a, $b, and $c to be arranged in the same resultant order as $d. > For example, please follow this: Befor

[PHP] edit db fields

2009-06-18 Thread PJ
How to deal with pre-selected input fields. To edit db fields in a table, I have a page that is basically the same as an insert page to create entries in the db. The table displays all the entries for a particular book that is selected from a search page. From the search page results a link leads t

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Bastien Koert
On Thu, Jun 18, 2009 at 1:34 PM, tedd wrote: > At 1:16 PM -0400 6/18/09, Paul M Foster wrote: >> >> On Thu, Jun 18, 2009 at 12:39:35PM -0400, PJ wrote: >> >> >> >>>  American movies, for the most part and what goes with them, are >>>  pollution of the senses. My take, of course. ;-) :-P >> >> Clea

[PHP] isset question

2009-06-18 Thread Gary
I have a form that gives the submitter a choice or either one set of questions, or another. I am still getting the message even if the input was left blank. So on the line below, $msg.= isset($_POST['mort']) ? "The mortgage amount is $mort\n" : " "; I get The mortgage amount is What am I m

Re: [PHP] about locale settings

2009-06-18 Thread Per Jessen
Daniel Brown wrote: > On Tue, Jun 16, 2009 at 15:33, Per Jessen wrote: >> >> Environment >> >> Variable => Value >> LC_ALL => de_DE.utf8 >> >> Is that what you were after? > > Sure is. Unfortunately, that means it's not an environment-import > issue as I had originally suspected. I'll take

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Skip Evans
Okay, had to chime in here... Jesus Christ, Vampire Hunter See the trailer here http://www.youtube.com/watch?v=4LRIypcaIX4 Skip Bastien Koert wrote: On Thu, Jun 18, 2009 at 1:34 PM, tedd wrote: At 1:16 PM -0400 6/18/09, Paul M Foster wrote: On Thu, Jun 18, 2009 at 12:39:35PM -0400, PJ wrot

Re: [PHP] about locale settings

2009-06-18 Thread Daniel Brown
On Thu, Jun 18, 2009 at 14:52, Per Jessen wrote: > > Now Dan, I hate to be a pest, but them minutes of yours seem to be > running a teeny bit slow? :-) It's the uhh time difference between Zurich and Scranton...? [*blushes*] Sorry about that. Let me finish this one final task a

Re: [PHP] isset question

2009-06-18 Thread Stuart
2009/6/18 Gary : > I have a form that gives the submitter a choice or either one set of > questions, or another. I am still getting the message even if the input was > left blank.  So on the line below, > > $msg.=  isset($_POST['mort']) ? "The mortgage amount is  $mort\n" : " "; > > I get > > The m

Re: [PHP] isset question

2009-06-18 Thread Steve
Use !empty($_POST['mort']) instead of isset() for form input since the form will still set an empty value if left blank. Gary wrote: I have a form that gives the submitter a choice or either one set of questions, or another. I am still getting the message even if the input was left blank. So

Re: [PHP] isset question

2009-06-18 Thread LAMP
Steve wrote: Use !empty($_POST['mort']) instead of isset() for form input since the form will still set an empty value if left blank. Gary wrote: I have a form that gives the submitter a choice or either one set of questions, or another. I am still getting the message even if the input was le

Re: [PHP] isset question

2009-06-18 Thread Waynn Lue
I notice that you're checking $_POST['mort'] but you're echoing $mort, is that your actual code? On 6/18/09, Gary wrote: > I have a form that gives the submitter a choice or either one set of > questions, or another. I am still getting the message even if the input was > left blank. So on the li

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread tedd
At 1:45 PM -0400 6/18/09, Robert Cummings wrote: Thanks to Rob and Daniel for also playing, better luck next time. :-) <- note smiley -- I do appreciate your time. Mine version retains key associations. It wasn't a complete waste of time. Cheers, Rob. Rob: Nothing you provide me is a comple

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Robert Cummings
tedd wrote: At 1:45 PM -0400 6/18/09, Robert Cummings wrote: Thanks to Rob and Daniel for also playing, better luck next time. :-) <- note smiley -- I do appreciate your time. Mine version retains key associations. It wasn't a complete waste of time. Cheers, Rob. Rob: Nothing you provide me

[PHP] Re: isset question

2009-06-18 Thread Gary
This is what I have now and it works. I do know that on the second line I have $_POST['mort']}\n" : " "; in the second half. I'm not sure I understand the comment about use the !empty if you dont care about PHP. But this is working, and unless someone sees a problem with it, I will leave it as

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Paul M Foster
On Thu, Jun 18, 2009 at 01:58:26PM -0500, Skip Evans wrote: > Okay, had to chime in here... > > Jesus Christ, Vampire Hunter > > See the trailer here > > http://www.youtube.com/watch?v=4LRIypcaIX4 > Ohmygosh! That's a *real* movie! Doubtless in the fine tradition of "The Toxic Avenger", but with

[PHP] need someone to bounce some thoughts with for a project!

2009-06-18 Thread bruce
hi list... sorry to post here, but i figured you might be able to help... i'm working on a project, that deals with building a crawler, and i'm working out the details for the mgmt app for the crawler. i'm currently looking at how to deal with the status/actions of the crawler, and how the differ

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Eddie Drapkin
It's the greatest movie I've ever seen. Canadians, Jesus, vampires and lesbians, what hte hell else could you ask for in a film? On Thu, Jun 18, 2009 at 3:50 PM, Paul M Foster wrote: > On Thu, Jun 18, 2009 at 01:58:26PM -0500, Skip Evans wrote: > >> Okay, had to chime in here... >> >> Jesus Chris

Re: [PHP] Re: isset question

2009-06-18 Thread LAMP
Gary wrote: This is what I have now and it works. I do know that on the second line I have $_POST['mort']}\n" : " "; in the second half. I'm not sure I understand the comment about use the !empty if you dont care about PHP. " if you don't care about PHP Notice... " eror_reporting: http://us

Re: [PHP] Multi-Sort -- how to do this?

2009-06-18 Thread Ashley Sheridan
On Thu, 2009-06-18 at 13:04 -0400, tedd wrote: > > > Ash: > >> > >> You missed the point. I could use the built-in sort (i.e., sort() ) > >> and sort the $d array. However, I would like the indexes of the other > >> arrays to match the new sort. > >> > >> Cheers, > >> > > > tedd > > > > >I t

Re: [PHP] Re: isset question

2009-06-18 Thread Martin Scotta
error_reporting( E_ALL | E_STRICT ); if you want to be extremely sure about your app (only in develop) On Thu, Jun 18, 2009 at 5:04 PM, LAMP wrote: > Gary wrote: > >> This is what I have now and it works. I do know that on the second line I >> have $_POST['mort']}\n" : " "; in the second half.

RE: [PHP] isset question

2009-06-18 Thread Yuri Yarlei
The isset or empty, it's return a boolean (true 1, false 0), the isset will return true if the variable will have been initiated, the empty will return true if the variable is empty, but for that the variable need to be initiated. You can do it in a many ways, like: $msg.= (isset($_POST['mort

Re: [PHP] Re: isset question

2009-06-18 Thread LAMP
Martin Scotta wrote: error_reporting( E_ALL | E_STRICT ); if you want to be extremely sure about your app (only in develop) Actually, I use error_reporting(E_ALL) while developing :-) Afan On Thu, Jun 18, 2009 at 5:04 PM, LAMP > wrote: Gary wrote: This

Re: [PHP] aesthetic beauty in conception, execution

2009-06-18 Thread Skip Evans
I have to to cite one more, but that is actually quite funny and a fun watch, and not only because my nephew plays the FBI agent who gets his face blown off... ...Blood Car...! The plot is great. In the not too distant future, like next week I think it says in the opening, gas is about $75 pe

[PHP] sessions tutorial

2009-06-18 Thread PJ
Top of the list is for real dummies at tizag.com. So I don't have to search 282,000 entries for php sessions tutorial (doesn't this say something about the stupidity on the internet - just how many of those entries could possibly be real and worth looking at? Since you "gurus" (I kowtow) have been

[PHP] Calendar

2009-06-18 Thread salmarayan
Does Any body please have the code of A Java Script Calendar that works with a PHP Html Form.. if yes can you please send it as i have one but does not work that Efficiently. Thanks in advance -- View this message in context: http://www.nabble.com/Calendar-tp24099681p24099681.html Sent from t

[PHP] PHP 5.3.0RC4

2009-06-18 Thread Johannes Schlüter
Hello! we have packaged PHP 5.3.0RC4, which you can find here: http://downloads.php.net/johannes/ Windows binaries are available here: http://windows.php.net/qa/ This fourth release candidate focused on bug fixes and stability improvements and we hope to only require minimal changes ahead of the

Re: [PHP] Calendar

2009-06-18 Thread Daniel Brown
On Thu, Jun 18, 2009 at 18:16, salmarayan wrote: > > Does Any body please have the code of A Java Script Calendar that works with > a PHP Html  Form.. No. > if yes can you please send it as i have one but does not work that > Efficiently. No. -- daniel.br...@parasane.net || danbr...@p

[PHP] Why does simpleXML give me nested objects for blank tags?

2009-06-18 Thread Daevid Vincent
I'm trying to use http://us2.php.net/manual/en/function.simplexml-load-string.php $xml_url = file_get_contents('http://myserver/cgi-bin/dart.cgi?request=c901c906e4d06a0d 4bd4e2932379d7c6'); try { $xml = simplexml_load_string($xml_url, 'SimpleXMLElement', LIBXML_NOBLANKS & LIBXML_COMPACT & LIBXML