[PHP] Re: WOT [PHP] REQUEST

2013-05-29 Thread Jay Blanchard
[snip]We're not your dudes/guyz/bros or anything like that. [/snip] Don't taze me bro'! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Problems with array_push?

2013-05-07 Thread Jay Blanchard
I know that I must be missing something really ridiculous, but when I print_r these arrays they are empty. I have confirmed that $arrayElement is properly formed, it just seems that array_push is not working. I know I have done this before, but I cannot find my older code. Can someone clear

Re: [PHP] Problems with array_push?

2013-05-07 Thread Jay Blanchard
[snip]Globals being used in a function. [/snip] *smacks forehead* -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] mysqli nested queries - maybe I'm rusty...

2013-04-02 Thread Jay Blanchard
Anyone? I have not been able to find a solution online. On 4/1/2013 11:33 AM, Jay Blanchard wrote: I am putting together an application where we are almost exclusively using stored procedures in MySQL because most of the heavy lifting (as it should be) is done in the database. I have exactly

Re: [PHP] {SOLVED] mysqli nested queries - maybe I'm rusty...

2013-04-02 Thread Jay Blanchard
[snip] ...stuff... [/snip] I rewrote everything so that I could get the data in a single query and then performed some manipulation with PHP to get the proper output. No need to call multiple queries in this case, just had to sleep on it. -- PHP General Mailing List (http://www.php.net/) To

[PHP] mysqli nested queries - maybe I'm rusty...

2013-04-01 Thread Jay Blanchard
I am putting together an application where we are almost exclusively using stored procedures in MySQL because most of the heavy lifting (as it should be) is done in the database. I have exactly one situation where I need to execute a stored procedure and while returning the results if I run a

[PHP] Undefined index....

2013-03-15 Thread Jay Blanchard
I have inherited a mess of a home-grown PHP framework that literally fills the error_log with 100's of thousands of messages each day. First order of business was rotating the logs, now we are working through each error to solve them. This is a fairly basic error, but I for the life of me

Re: [PHP] Undefined index....

2013-03-15 Thread Jay Blanchard
[snip] Two questions: Where is $xml defined and where is $pos defined? [/snip] $xml is defined in other functions, just not in this function. $pos is irrelevant to the question - it is just the string position within the file. -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Undefined index....

2013-03-15 Thread Jay Blanchard
[snip] function includeXML($file, $locale, $url, $level = 1) { // stuff $xml = ''; Should work here ... Since the call below is ADDING to $xml you do need something existing to add to so what does that give? [/snip] Thanks Lester, that worked. I had just put that in the wrong place.

Re: [PHP] Introduction ... !

2013-03-02 Thread Jay Blanchard
[snip] ...good conversation... [/snip] I have been on this list for years and I have watched it ebb and flow. I have heard all the bad and good about PHP. The fact remains that we use PHP in some very heavy applications and it never fails us for what we want or need to do. I always encourage

Re: [PHP] Introduction ... !

2013-03-02 Thread Jay Blanchard
[snip] I've been on this list since the early 2000's. I used to participate a lot back then but then took up a non-php related job and I stopped paying attention to the list. I've been working again with php for the past 4.5 years but choose to just monitor the list and haven't participated

Re: [PHP] Introduction ... !

2013-03-02 Thread Jay Blanchard
[snip] Speak for yourself, I'm an autumn turkey! -Stuart [/snip] My body is an Autumn turkey, my head says differently - save on certain mornings when too much popping and cracking occurs. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Creating an Advanced Form

2012-11-02 Thread Jay Blanchard
[snip] Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /var/www/vhosts/numyspace.co.uk/web_users/home/~unn_w11014928/public_html/search.php on line 261[/snip] It would appear that your query is not returning a result. Echo out the query and try running

Re: [PHP] URGENT! Need help with command line for list all new/modified files within the last 24 hours

2012-10-25 Thread Jay Blanchard
[snip] Third, if it is Linux, man find and you will find the answer you seek [/snip] RTFMP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Round help needed

2012-09-28 Thread Jay Blanchard
On 9/27/2012 10:05 PM, Chris Payne wrote: Hi everyone, I'm having one of those nights where nothing is working, please help What I have is this: $rounded_number = round($test, -3); Here's the problem i'm having, I need it to increment to the nearest 1000 but it seems to only work if the

Re: [PHP] Creating drop-down menus - use AJAX and jQuery

2012-07-17 Thread Jay Blanchard
[snip]On 7/17/2012 4:55 PM, Daevid Vincent wrote: * jQuery for production (minified) is a scant 32k. http://jquery.com/ LOL That's like a TCP/IP packet. I bet your images are bigger than 32k. * Unlike stupid PHP frameworks (which everyone knows I detest) - JS frameworks are cached by the

Re: [PHP] Is this list less busy than it used to be?

2012-07-04 Thread Jay Blanchard
[snip] Is this list less busy than it used to be? Or is it just me? When I used to be on this list ISTR sometimes being overwhelmed by email. [/snip] One other factor is Stackoverflow - there is a tremendous amount of traffic there for PHP related questions. I have been a subscriber to this

Re: [PHP] What's happened to our newsgroup?

2012-06-28 Thread Jay Blanchard
[snip] We now all have php.net open all the time so no more questions need to be asked! : [/snip] You mean everyone finally RTFM? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] test

2012-06-07 Thread Jay Blanchard
On 6/7/12 1:07 PM, Sven Kowalski wrote: does it work now? It pretty much always did. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: PHP: a fractal of bad design

2012-04-17 Thread Jay Blanchard
[snip] a simple +1 will do [/snip] Ahthe good old days. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: php in windows

2012-04-11 Thread Jay Blanchard
On 4/11/2012 9:42 AM, Steven Staples wrote: -Original Message- From: Kirk Bailey [mailto:kbai...@howlermonkey.net] Sent: April 11, 2012 1:02 AM To: php-general@lists.php.net Subject: Re: [PHP] Re: php in windows ok, there is a copy of index.php ion the cgibin, and this got WAY

Re: [PHP] PHP: a fractal of bad design

2012-04-11 Thread Jay Blanchard
On 4/11/2012 7:06 PM, Daevid Vincent wrote: http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/ Can't say he doesn't have some good points, but he sure goes about it in a dickish way. Yes, he does have some good points and most, if not all, of those points have been discussed on

Re: [PHP] php in windows

2012-04-10 Thread Jay Blanchard
On 4/9/2012 9:05 PM, Kirk Bailey wrote: The edition of php for windows I instaklled does not work. Which flavor of windows php DOES work properly in windows? You need to give us more details than this. What version did you install? What do you mean by does not work? All flavors of PHP will

Re: [PHP] desk top interactive environment

2012-04-09 Thread Jay Blanchard
[snip] On Apr 9, 2012, at 8:38 PM, Kirk Bailey wrote: Php would (IMHO) benefit from an interactive desktop application where you can test and experiment with code interactively, instead of edit, dsave, run, view webpage result, edit... Python has this; why not php? [/snip] Because you

Re: [PHP] Thinking out loud - a continuation...

2012-04-02 Thread Jay Blanchard
[snip] function getTiersJson( $company ) { $tiers = getTiers( $company ); $json = JSON_encode( $tiers ); } $tiersJson = getTiersJson( 1 ); ? This will output JSON with the following structure: [/snip] OK, now I know I am being dense - but don't I have to add return $json; to

Re: [PHP] Thinking out loud - a continuation...

2012-03-31 Thread Jay Blanchard
[snip] On 3/30/2012 1:14 PM, Robert Cummings wrote: On 12-03-27 11:11 AM, Jay Blanchard wrote: [snip]On 3/27/2012 12:21 AM, Robert Cummings wrote: [-- SNIP --] Essentially, entries at the root and entries for the children are just auto indexed array items but the actual entries in those

Re: [PHP] Thinking out loud - a continuation...

2012-03-27 Thread Jay Blanchard
[snip]On 3/27/2012 12:21 AM, Robert Cummings wrote: I think you need two things... the recursive post processor that removes the string indexes for the children. And then a function that creates a JavaScript array expression from an object or array. The question I have for you... is given the

Re: [PHP] Thinking out loud - a continuation...

2012-03-27 Thread Jay Blanchard
[snip]On 3/27/2012 12:21 AM, Robert Cummings wrote: I think you need two things... the recursive post processor that removes the string indexes for the children. And then a function that creates a JavaScript array expression from an object or array. The question I have for you... is given the

Re: [PHP] List working?

2012-03-27 Thread Jay Blanchard
[snip] y u no help me !! i have white page withg my php codes in my page ! help please !! asap please i put codes in my file and is white [/snip] You put code in your e-mail? Or code in your web page? If it is your web page you need to start a new thread and post the code that you used

Re: [PHP] Thinking out loud - a continuation...

2012-03-26 Thread Jay Blanchard
[snip] This is one of those projects. It is apparently going to be trying every step of the way. [/snip] I was proven right this morning after all of Robert's good work and what I had added to make this work. It turns out that the one service who was anxious to consume the JSON output expects

Re: [PHP] Thinking out loud - a continuation...

2012-03-26 Thread Jay Blanchard
[snip] Square brackets in JSON represent arrays. Take their JSON, run it through json_decode, and assuming it decodes correctly compare the structure to what you already have. You should then be able to modify what you have so it generates JSON in the format they are expecting. [/snip]

Re: [PHP] Thinking out loud - a continuation...

2012-03-26 Thread Jay Blanchard
[snip] *lol* No worries... it's all about solving problems :) [/snip] the other folks who needed to consume the JSON have all done so successfully today - just this one. The guy who runs it was plenty arrogant when I discussed with him. He is the one who wanted me to remove the extra array

Re: [PHP] Thinking out loud - a continuation...

2012-03-26 Thread Jay Blanchard
[snip] Did you end up with a satisfactory output? It's not overly difficult to generate an array instead of an object. [/snip] I did for all but this one instance. Are you saying that it would be easy to make of the children arrays? I thought they were already - am I missing something? --

Re: [PHP] Thinking out loud - a continuation...

2012-03-26 Thread Jay Blanchard
[snip] On Mar 26, 2012, at 5:58 PM, Robert Cummings wrote: On 12-03-26 06:52 PM, Jay Blanchard wrote: [snip] Did you end up with a satisfactory output? It's not overly difficult to generate an array instead of an object. [/snip] I did for all but this one instance. Are you saying

Re: [PHP] Thinking out loud - a continuation...

2012-03-25 Thread Jay Blanchard
[snip] a necessary part of building the structure. It can be removed but only as a post process. Why does it have to be removed? You can loop through the structure in JavaScript without paying heed to the key's value. If it absolutely must go... you need to recurse through the final structure

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
[snip] Did you send me a sample dump for your table :) [/snip] I'll do that today. I got side-tracked last night. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
On Mar 23, 2012, at 11:24 PM, Robert Cummings wrote: On 12-03-23 05:41 PM, Jay Blanchard wrote: [-- DELETED GARBAGE --] :) I just realized... I've been stuck in a thinking rut. I latched onto one solution that works well in some case but didn't fully examine the nuances of your own

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
[snip]The crux of it is: $focus = $focus[$name]; [/snip] It works as I expect so far. All I have to do is figure out how to make the element a name: element in the JSON. for instance an element would look like this { name: Bob, children: [] } So the PHP array would have to look

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
[snip] A little tweak here... a little tweak there: [/snip] if( !isset( $focus[$name] ) ) { $focus[$name] = array ( 'name' = $name, 'children' = array(),

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
[snip] A little tweak here... a little tweak there: [/snip] One more little tweak may be required. The JSON looks like this {Executives and Management:{name:Executives and Management,children:{ The first part {Executives and Management: needs to be removed. I think I know what to do. --

Re: [PHP] Thinking out loud - a continuation...

2012-03-24 Thread Jay Blanchard
[snip] One more little tweak may be required. The JSON looks like this {Executives and Management:{name:Executives and Management,children:{ The first part {Executives and Management: needs to be removed. I think I know what to do. [/snip] It has become painfully obvious that I do not

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] Your data structure doesn't appear to be very ummm normalized... Nonetheless, the following should do it: [/snip] You're absolutely correct. Unfortunately I am not the designer and cannot really do anything about it. I just have to work with what I have. Thank you very much for this -

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] $json = JSON_encode( $root ); [/snip] Update on my test. This works perfectly Robert - thank you very much! But there is one small problem that I am trouble-shooting: it only goes one layer and doesn't progress any further. I suspect it is on this section of code that I am going to

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] $json = JSON_encode( $root ); [/snip] Update on my test. This works perfectly Robert - thank you very much! But there is one small problem that I am trouble-shooting: it only goes one layer and doesn't progress any further. I suspect it is on this section of code that I am

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
On Mar 23, 2012, at 2:25 PM, Robert Cummings wrote: On 12-03-23 03:17 PM, Jay Blanchard wrote: [snip] $json = JSON_encode( $root ); [/snip] Update on my test. This works perfectly Robert - thank you very much! But there is one small problem that I am trouble-shooting: it only goes

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] Did you get any results form the database on the second run through the query loop? [/snip] Actually, no. I just ran the raw query - SELECT DISTINCT `TIER3DATA` AS id, `TIER2DATA` AS parentId FROM `POSITION_SETUP` WHERE `COMPANY_ID` = '3' AND `TIER2DATA` IN ('Executives and

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] No, I'm performing assignment... intentionally. Parent's becomes the previous children to move down a level. The following: if( !($parents = $children) ) performs assignment and an empty array check in one statement. [/snip] Gotcha'. So all I am ever getting back right now is

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] SELECT DISTINCT `TIER3DATA` AS id, `TIER2DATA` AS parentId FROM `POSITION_SETUP` WHERE `COMPANY_ID` = '3' AND `TIER2DATA` IN ('Executives and Management','Professionals','Technicians','Craft Workers-Skilled','Operatives','Contractor','Sales Workers','Laborers and Helpers','Admin

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] $item['children'] should be an array, somehow a string has been assigned :/ [/snip] Yep. I am trying to figure that out now. I'm sure it is something really small. BTW, after making the change to the for loop there are results returned as we expected. -- PHP General Mailing List

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] $item['children'] should be an array, somehow a string has been assigned :/ [/snip] Yep. I am trying to figure that out now. I'm sure it is something really small. [/snip] I have been hammering away at it for a while now and still cannot find the issue. I'll push away for a while

Re: [PHP] Thinking out loud - a continuation...

2012-03-23 Thread Jay Blanchard
[snip] …stuff…. [/snip] For those interested here is where the problem seems to occur - $child = array ( 'id' = $id, 'parentId' = $pid, 'children' = array() );

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] Would it not be easier to get the data from a view which has the tables joined? Then it would be one query and it's a simple matter to format the results into the multi dimensional array then json? [/snip] The data is all from one table. I'll write up a more thorough explanation in a

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] ...stuff... [/snip] Here is the explanation for what I have done and what I am trying to do - (based on the customer's request). A week or so ago I took a set of queries from one table and made them into an unordered list. This will be pseudo-code so that you get idea. SELECT

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] Fix this code... I've come across codebases that did this specific type of nested querying and it resulted in 1 queries to the database on every page. Instead, create a layered approach: 1. Select your root elements. 2. Loop over in PHP and create an array of child IDs.

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] On 3/22/2012 11:17 AM, Robert Cummings wrote: On 12-03-22 11:58 AM, Jay Blanchard wrote: [snip] Fix this code... I've come across codebases that did this specific type of nested querying and it resulted in 1 queries to the database on every page. Instead, create a layered approach

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] Sorry, I just realized I didn't make the optimization explicitly obvious... when I say Select the children I mean to select them using an IN( id1, id2, id3 ) clause instead of a query for each. This is why we build the array of parent IDs (also I wrote build an array of child IDs, it

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
On 3/22/2012 11:40 AM, Robert Cummings wrote: On 12-03-22 12:34 PM, Jay Blanchard wrote: [snip] Sorry, I just realized I didn't make the optimization explicitly obvious... when I say Select the children I mean to select them using an IN( id1, id2, id3 ) clause instead of a query for each

Re: [PHP] Thinking out loud - a continuation...

2012-03-22 Thread Jay Blanchard
[snip] At one point you indicated all the data was coming from one table. Can you send me the table fields and indicate which fields are used to determine parent child relationship? Also 2 sample rows of data which have a relationship would be helpful. [/snip] Columns - tier1, tier2,

[PHP] Thinking out loud - a continuation...

2012-03-21 Thread Jay Blanchard
This is a continuation of the nested query thing I posted to the list a while back. I was finally able to output a nested unordered array that worked out well, but scope-creep has come in the door and I have to change gears. I have a project where I have multiple queries and each query uses the

Re: [PHP] Thinking out loud - a continuation...

2012-03-21 Thread Jay Blanchard
[snip] I would, yes, but that's not the point. Is Anna single? I'm ready to trade Debs in for a newer model. [/snip] I'm thinking that Debs would upset your array if you traded her in. Anyhow, I have spent the last hour trying to output valid JSON but the whole thing is making me

Re: [PHP] Thinking out loud - a continuation...

2012-03-21 Thread Jay Blanchard
[snip] Why are you trying to create the JSON structure in parts? When I have nesting like this i build the full nested structure as PHP, then export to JSON. [/snip] As PHP? An array? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] PHP 5.3.2 on IIS Fast CGI Timeout error

2012-03-20 Thread Jay Blanchard
Good afternoon PHP gurus, I am trying to troubleshoot a problem on a Windows server (*UGH*). This is the error - The FastCGI Handler was unable to process the request. Error Details: * The FastCGI process exceeded

Re: [PHP] PHP 5.3.2 on IIS Fast CGI Timeout error (SOLVED)

2012-03-20 Thread Jay Blanchard
[snip] ..the craziness of it all [/snip] Found out that the PostGreSQL .dll was not loaded and that the server had been configured to not give up any errors regardless of how I set error reporting. Reconfigured the server and restarted it. Viola'! It all works now. -- PHP General Mailing List

Re: [PHP] Got HTML5 History API + caching LICKED, I think, grin

2012-03-17 Thread Jay Blanchard
[snip] As for minifying the javascripts, it would take me another day, maybe 2, to build a script for that. And I don't think it would matter much, all the animatedJavascriptWidgets JS is gzipped 25kb and if I shave 5kb off that (upper estimate) then I don't consider that worth the effort, at

Re: [PHP] fgetcsv doesn't return an array?

2012-03-16 Thread Jay Blanchard
[snip] Not sure why, but ok. Thanks everyone! An empty line would lead to $csvCurrentLine == array() which as a boolean would be false but would not necessarily mean EOF. By using === to check the value the expression will only evaluate to false at EOF or an error. -Stuart [/snip] Makes

[PHP] fgetcsv doesn't return an array?

2012-03-15 Thread Jay Blanchard
the solution? Thanks! Jay |

Re: [PHP] fgetcsv doesn't return an array?

2012-03-15 Thread Jay Blanchard
On 3/15/2012 12:23 PM, Matijn Woudt wrote: On Thu, Mar 15, 2012 at 6:09 PM, Jay Blanchard jay.blanch...@sigmaphinothing.org wrote: I thought that fgetcsv returned an array. I can work with it like an array but I get the following warning when using it |Warning: implode(): Invalid arguments

Re: [PHP] fgetcsv doesn't return an array?

2012-03-15 Thread Jay Blanchard
[snip] Please, don't do that. Use this instead: while (($csvCurrentLine = fgetcsv($csvFile, 4096, ',')) !== FALSE) { } [/snip] Not sure why, but ok. Thanks everyone! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
Good morning PHP groupies! I am off on my next tangent now and I have not really thought about this too much yet but have you seen a method to convert a nested unordered list into JSON using PHP? Thanks! Jay -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

Re: [PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
On 3/5/2012 9:53 AM, Stuart Dallas wrote: On 5 Mar 2012, at 15:50, Jay Blanchard wrote: I am off on my next tangent now and I have not really thought about this too much yet but have you seen a method to convert a nested unordered list into JSON using PHP? There's a very useful search

Re: [PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
[snip] $json = json_encode($nested_unordered_list); As I said, whether that works or not depends on what type $nested_unordered_list is. If it's not made of standard types you'll need to massage it into a structure using standard types. :D [/snip] Stewie, Stewie, Stewie. :) So what

Re: [PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
[snip] Difficult to answer without knowing how your data is currently stored. Gimme a var_dump or var_export of your data and I'll be able to give you an answer. -Stuart [/snip] It is an unordered nested list as in the following example - ul lifoo/li libar ul liglorp/li /ul /li /ul -- PHP

Re: [PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
[snip] Sounds like your tangents are efforts to accomplish things that you know too little about and don't want to spend too much time getting acquainted with. To borrow from your crude response to Mr. Dallas: You may have RTFM, now try DTFW. :) [/snip] Seriously Jim? I have been a member

Re: [PHP] Converting an unordered list into JSON

2012-03-05 Thread Jay Blanchard
[snip] Ahh, the list is in an HTML document, suddenly it all becomes clear. DOMDocument is probably your best bet here. Other HTML parsers are also available. -Stuart [/snip] Ah! Thanks for the heads up on that Stuart - I'll start my work there this afternoon. -- PHP General Mailing List

Re: [PHP] iphone php

2012-03-05 Thread Jay Blanchard
[snip]In the last few mins I re-booted my phone and it is now doing something even worse! [/snip] Have you also cleared the cache and the cookies? You can also add Firebug to your iPhone - http://www.iphone-my.com/ipad/geting-firebug-iphone-ipad/ -- PHP General Mailing List

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-02 Thread Jay Blanchard
My usual approach to a problem like this to to includes a parent column in the table ID (int pk) Parent ( default null ) // no parent Item Itemtype [etc] Parent will then hold either a null if a top level item, or a structured path ( 1/10/24 ) that notes the parents of the item all

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-02 Thread Jay Blanchard
[snip] Doesn't this SQL query return everything that has company_id set to 3 which would it not contain all the data from the other queries combined into one large data set? [/snip] I could do that, I can return one large dataset for all of the columns shown in the tiers array. I have to

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-02 Thread Jay Blanchard
[snip] ...stuff ... [/snip] A thought occurred to me - I need to call the function at the end of the while loop and then again with different criteria after the while loop? I'll have to test that later today. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-02 Thread Jay Blanchard
[snip] I'm not saying you should get rid of the recursive function calls, but rather, why not pull all your data in one SQL call, then use recursive functions on the returned array of data. It will save a little time by not hitting the DB on each function call too. [/snip] I'll just need

[PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
with the proper syntax, but I am not worried about that now. I was hoping that a fresh set of eyes would point me to a solution that I obviously cannot see at the moment. Thanks! Jay -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
Thanks FeIn, I'll give these articles and methods a look this afternoon. I'm sure that it will lead to more questions, so I'll be back. On 3/1/2012 9:16 AM, FeIn wrote: And see also this, which focuses only on the database part of the problem:

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
On 3/1/2012 9:59 AM, Jay Blanchard wrote: Thanks FeIn, I'll give these articles and methods a look this afternoon. I'm sure that it will lead to more questions, so I'll be back. I also forgot to say that I cannot modify the database structure - the client is very strict about

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
[snip]…stuff…[/snip] I am getting close, but I am also getting frustrated. I probably need to walk away for a bit. I have an array of tiers…. Array ( [0] = TIER1DATA [1] = TIER2DATA [2] = TIER3DATA [3] = BUSTIER1DATA [4] = BUSTIER2DATA [5] = BUSTIER3DATA [6] =

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
On Mar 1, 2012, at 6:36 PM, Jay Blanchard wrote: [snip]…stuff…[/snip] I am getting close, but I am also getting frustrated. I probably need to walk away for a bit. I have an array of tiers…. Array ( [0] = TIER1DATA [1] = TIER2DATA [2] = TIER3DATA [3] = BUSTIER1DATA

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
On Mar 1, 2012, at 7:45 PM, Jim Lucas wrote: On 03/01/2012 04:39 PM, Jay Blanchard wrote: On Mar 1, 2012, at 6:36 PM, Jay Blanchard wrote: [snip]…stuff…[/snip] I am getting close, but I am also getting frustrated. I probably need to walk away for a bit. I have an array of tiers

Re: [PHP] Nested database loops and completing an unordered list....

2012-03-01 Thread Jay Blanchard
[snip] Can you show the output of the function above? [/snip] 0 SELECT DISTINCT `TIER1DATA` FROM `POSITION_SETUP` WHERE `COMPANY_ID` = '3' Executives and Management Normally this query alone returns 9 rows of data. Each of these rows should be included in the next query where TIER1DATA =

Re: [PHP] SimpleXML and the Single String (SOLVED)

2012-02-22 Thread Jay Blanchard
On 2/22/2012 8:32 AM, ma...@behnke.biz wrote: There is another nice way. You can pass a second value to the simple xml constructor which is a class name to be used instead of SimpleXMLElement. You can write your own class that extends SimpleXMLElement and override the magic methods to skip the

Re: [PHP] SimpleXML and the Single String (SOLVED)

2012-02-22 Thread Jay Blanchard
I don't really see a need to add an extra layer or class extension when casting works fine. Am I wrong? Why add several lines of code in an extension class? To keep the code readable? $value = $xml-node; vs. $value = (String)$xml-node; I like the first one. Plus you handle it to

Re: [PHP] Test

2012-02-21 Thread Jay Blanchard
It's like coming home, I knew I could count on certain of you to make light of this and that makes me strangely happy. On 2/21/2012 7:55 AM, Tedd Sperling wrote: On Feb 20, 2012, at 2:49 PM, Daniel Brown wrote: On Mon, Feb 20, 2012 at 14:40, Bastienphps...@gmail.com wrote: Definitely

[PHP] Test

2012-02-20 Thread Jay Blanchard
Does this work? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Test

2012-02-20 Thread Jay Blanchard
I'll be darned - it finally works. What's up with that? On Feb 20, 2012, at 1:49 PM, Daniel Brown wrote: On Mon, Feb 20, 2012 at 14:40, Bastien phps...@gmail.com wrote: Definitely doesn't work The list works just fine, it's you goofs who need to work now! ;-P -- /Daniel P. Brown

[PHP] SimpleXML and the Single String (SOLVED)

2012-02-20 Thread Jay Blanchard
Howdy, My PHP chops are a little rough around the edges so I know that I am missing something. I am working with SimpleXML to retrieve values from an XML file like this - $xmlCompany = $xml-SignonRq-SignonTransport-CustId-SPName; If I echo $xmlCompany I get the proper information. If I use

[PHP] Hi!

2011-11-24 Thread Jay S
Hi, Hope you are doing awesome! My name is Jay and I am the Affiliate Account Manager at InstallMonetizer. I wanted to connect with you and show you how you can make more money by using our services to monetize your install path. :) Currently, I see you are offering your software

RE: [PHP] Fwd: ezmlm warning

2011-07-20 Thread Jay Blanchard
[snip] I got it too, so its not just limited to gmail. Maybe a server in between not working correctly. I'm in the UK, are the rest of you who had problems this way too? [/snip] I'm in Texas and got it. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] str_replace around a character??

2011-07-13 Thread Jay Ess
On 2011-07-13 09:54, Karl DeSaulniers wrote: $cc = ema...@domain.com ,ema...@doamin.com,ema...@domain.com , ema...@domain.com, $cc = trim($cc,,); $result = preg_replace('/(\s?)(,)(\s?)/i', ',', $cc); -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] str_replace around a character??

2011-07-13 Thread Jay Ess
On 2011-07-13 10:36, Vitalii Demianets wrote: On Wednesday 13 July 2011 11:09:45 Jay Ess wrote: On 2011-07-13 09:54, Karl DeSaulniers wrote: $cc = ema...@domain.com ,ema...@doamin.com,ema...@domain.com , ema...@domain.com, $cc = trim($cc,,); $result = preg_replace('/(\s?)(,)(\s?)/i

RE: [PHP] best ways to recruit volunteers for a PHP framework

2011-06-28 Thread Jay Blanchard
[snip] I have developed an ORM framework in PHP for the last 2 years and it's becoming a more professional and nice solution so before doing a new complete revamp I am going to look for volunteer developers to do a real good version. [/snip] https://github.com/ -- PHP General Mailing List

RE: [PHP] php hide menu

2011-06-07 Thread Jay Blanchard
[snip] I would like to pass the value from the prior menu to the next. Would you please show me how to handle this? [/snip] As several have mentioned, this is a job for AJAX and JavaScript. Here is a good tutorial: http://www.yourinspirationweb.com/en/how-to-create-chained-select-with-p

RE: [PHP] iPhone sadness

2011-05-31 Thread Jay Blanchard
[snip] I can remember when it first started, no moaning about this or that, just pure PHP, and no sarcastic comments either, bring back the good old days :) [/snip] I beg to differ - the sarcastic remarks have been here since day one. -- PHP General Mailing List (http://www.php.net/) To

RE: [PHP] iPhone sadness WOT

2011-05-31 Thread Jay Blanchard
[snip] I beg to differ - the sarcastic remarks have been here since day one. Yeah *SHSH* What was he thinking?! ;) [/snip] I know huh? Whatevs. I added something to the subject so that those who don't want to read these can send them to /dev/null appropriately. -- PHP General Mailing

  1   2   3   4   5   6   7   8   9   10   >