Re: [PHP] weird timestamp problem

2006-12-07 Thread Larry Garfield
class=\timeblock\ align=\center\. $timeloop_s .br /. $timeloop_e . /td\n); } -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking

Re: [PHP] alternative method

2006-12-02 Thread Larry Garfield
. Alain Windows XP SP2 PostgreSQL 8.1.4 Apache 2.0.58 PHP 5 -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property

Re: [PHP] func_get_args as a hash? (faster constructors)

2006-11-29 Thread Larry Garfield
then. Nothing is free. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess

Re: [PHP] Self generating variables/arrays

2006-11-25 Thread Larry Garfield
. Thanks in advance Jeff K -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively

Re: [PHP] security question

2006-11-22 Thread Larry Garfield
On Wednesday 22 November 2006 22:38, Robert Cummings wrote: maybe we should all refer to forum and google Teach a man to fish... And you lose your monopoly on fisheries. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one

Re: [PHP] PHP Programmers

2006-11-18 Thread Larry Garfield
ranging from small non-profits up through multiple tier-one universities. We're based in the Chicago area. Contact me off list for details if you're interested in more info. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one

Re: [PHP] Smart Quotes not so smart

2006-11-17 Thread Larry Garfield
On Thursday 16 November 2006 14:07, Chris Shiflett wrote: Larry Garfield wrote: I've run into this sort of issue a few times before, and never found a good solution. Not sure if this is the solution you're looking for, but you can convert them to regular quotes: http://shiflett.org

Re: [PHP] Dynamic Year Drop Down

2006-11-16 Thread Larry Garfield
into the future. Obviously, I could easily hard code this or use a combination of the date and mktime functions to populate the select. However, I'm looking for a more elegant way of doing this. Thanks for pointing me in the right direction. Al Padley -- Larry Garfield AIM

[PHP] Smart Quotes not so smart

2006-11-15 Thread Larry Garfield
what those smart quotes actually are, and if they exist in ANY valid character set other than Word itself? -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property

Re: [PHP] CSS / PHP / Javascript

2006-11-14 Thread Larry Garfield
/) To unsubscribe, visit: http://www.php.net/unsub.php -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] Mysql strategy

2006-11-13 Thread Larry Garfield
free() the result set afterward then the memory usage is not a major issue either. If you're finding your query is slow, look into your indexes. Just today I cut a single query from 230 seconds to 21 seconds just by adding two indexes. :-) -- Larry Garfield AIM: LOLG42 [EMAIL

Re: [PHP] http_build_query ... argh

2006-11-09 Thread Larry Garfield
the better solution be to fix http_build_query to not break when handling fairly typical PHP URLs? -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] Nested includes - Relative paths?

2006-11-08 Thread Larry Garfield
On Wednesday 08 November 2006 07:52, Nuno Vaz Oliveira wrote: Hello Larry, Now I think I got it :) All include statements are parsed based on the defined include path, where . is interpreted relative to the active context, vis, the script that the web server itself is running. I

Re: [PHP] Nested includes - Relative paths?

2006-11-07 Thread Larry Garfield
, and a.php includes foo/b.php, and b.php includes c.php, then c.php is looked up on the file system as ./c.php, relative to a.php, since that's what apache is actually running. Got that? :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has

Re: [PHP] Closing a connection to browser without exiting the script

2006-11-05 Thread Larry Garfield
. frontend.php: ?php $fp = fsockopen(localhost, 80); fwrite($fp, GET /long_processing_script.php HTTP/1.0\r\n\r\n); stream_set_timeout($fp, 1); echo done!; ? long_processing_script.php: ?php ignore_user_abort(); set_time_limit(0); // do stuff here ? -- Larry Garfield

Re: [PHP] str_replace on words with an array

2006-10-30 Thread Larry Garfield
guarantee that the above code is the best performant method, but it works. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power

Re: [PHP] heredoc usage [WAS: OPTION]

2006-10-29 Thread Larry Garfield
me, too, when I realized single quotes were kosher (X)HTML, but it can be quite convenient. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] forms usage in web pages

2006-10-29 Thread Larry Garfield
that. Please forgive me if this is not the right mailing list to post this question. But help me out in clarifying this basic doubt. thanks in advance Karthi -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less

Re: [PHP] Job Opening

2006-10-26 Thread Larry Garfield
On Wednesday 25 October 2006 22:15, Larry Garfield wrote: Well since the consensus seemed to be to allow job postings, I'll make one. :-) My company is looking for a few good PHP programmers. We are a Chicago-area web consulting firm developing web sites and web applications for a variety

Re: [PHP] DATETIME or UNIX TIMESTAMPS?

2006-10-26 Thread Larry Garfield
to do I can do in PHP either before or after grabbing the timestamp. I am sure there is a counter point, but this for what I do I just stick to timestamps. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less

Re: [PHP] How does the Zend engine behave?

2006-10-26 Thread Larry Garfield
what it's status is, but he claimed to get a nice performance boost out of it. Cheers. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] How does the Zend engine behave?

2006-10-25 Thread Larry Garfield
of the are smarter about that. Which and how, I don't know. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called

[PHP] Job Opening

2006-10-25 Thread Larry Garfield
.   If interested, contact me OFF-LIST for more information.  Note: I am NOT in a hiring position, so do NOT send me your resume. :-)  I'm just going to pass you on to the person who is. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one

Re: [PHP] Creating Tree Structure from associative array

2006-10-19 Thread Larry Garfield
) 72 441 3355 *Fax:*+27 (0) 86 681 5885 * Web:* http://www.zlogic.co.za *E-Mail:* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others

Re: [PHP] A no brainer...

2006-10-16 Thread Larry Garfield
. The right balance will depend greatly on your use case. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] Retrieving values from array on a class

2006-10-15 Thread Larry Garfield
want the object properties, you need to use $this-a, $this-b, etc. I still think both methods are highly over-engineered, however. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others

Re: [PHP] A no brainer...

2006-10-14 Thread Larry Garfield
aren't syncing to the database periodically then you will end up with stale data objects. (An issue in any case, but the longer the object representing a view of your database exists, the more of a problem it becomes. YMMV depending on the data you're holding.) -- Larry Garfield

Re: [PHP] A no brainer...

2006-10-14 Thread Larry Garfield
if you only need it occasionally is a waste of cycles. You're better off rebuilding it each time or implementing your own caching mechanism that only loads on demand. There is no general answer here. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012

Re: [PHP] Retrieving values from array on a class

2006-10-14 Thread Larry Garfield
has the values you need. Much simpler, and much faster. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea

[PHP] [JOB] PHP Book Tech Reviewer

2006-10-10 Thread Larry E. Ullman
of a month, I think). If you are interested or have any questions, please email me off-list. Thanks, Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] OOP slow -- am I an idiot?

2006-10-10 Thread Larry Garfield
a class. I want my data to _only_ be accessed from the black box called an OOP class. CD Think you're a good person? Yeah, right! ;-) Prove it and get ten thousand dollars: TenThousandDollarOffer.com -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012

Re: [PHP] need help to build a query

2006-10-09 Thread Larry Garfield
== A Good Thing. If you can do with a join or subselect what would take n queries otherwise, do so. Also, JOIN is faster than sub-queries. Be aware, though, that MySQL doesn't support sub-queries until version 4.1. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED

Re: [PHP] Uploading files / processing with a PHP script

2006-10-08 Thread Larry Garfield
and your ftp user into the mygroup group. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] Coding Style Question...

2006-10-02 Thread Larry Garfield
that I can just pass logical data structures and get back fully semantically useful HTML. (Eg, theme_table automatically puts in even/odd classes on tr tags for me.) Again, credit here goes to the Drupal CMS, which uses a much more developed and refined version of this concept. -- Larry

Re: [PHP] Best open source project/framework to support a php training course?

2006-09-27 Thread Larry Garfield
of the server configuration. That right there is a good solid challenge, but it makes them paranoid from day one, which is how they should be. It also is code they can (and should) then use in all their later projects. 10 points off for every way you find to hack their code. :-) -- Larry Garfield

Re: [PHP] Logical OR in assignment

2006-09-27 Thread Larry Garfield
Science Engineering [www.cse.osu.edu] -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.405 / Virus Database: 268.12.8/455 - Release Date: 9/22/2006 -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has

Re: [PHP] Months between two dates

2006-09-15 Thread Larry Garfield
and dirty way to do this without a for loop. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] readdir

2006-09-15 Thread Larry Garfield
at scandir(). It gives you an array of all of the files/directories in a given directory, which you can then sort with sort() or usort() or whatever. If you're on PHP 4, there's a backport of it in PEAR::PHP_Compat that doesn't actually require the rest of PEAR to function. :-) -- Larry

Re: [PHP] register globals on

2006-09-12 Thread Larry Garfield
in the first place. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess

Re: [PHP] Re: IE session problem on one server only

2006-09-09 Thread Larry Garfield
, and on the client's desktop in another city. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] Strange server crash problem

2006-09-08 Thread Larry Garfield
. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps

[PHP] Strange server crash problem

2006-09-07 Thread Larry Garfield
. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps

[PHP] IE session problem on one server only

2006-09-07 Thread Larry Garfield
. If it were the other way around I wouldn't care, but the live site shouldn't break. :-) Any idea what could be the problem? -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive

Re: [PHP] Strange server crash problem

2006-09-07 Thread Larry Garfield
, it seems. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long

Re: [PHP] Directory Structure

2006-09-07 Thread Larry Garfield
prove useful: http://us2.php.net/scandir http://us2.php.net/manual/en/function.readdir.php http://us2.php.net/manual/en/class.dir.php http://us2.php.net/manual/en/spl (for very new PHP 5) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has

Re: [PHP] Re: Functions vs html outpuit

2006-09-03 Thread Larry Garfield
will be an order of magnitude larger than whatever it is you're doing anyway. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power

Re: [PHP] Re: Recommendations for PHP debuggers?

2006-08-26 Thread Larry Garfield
On Tuesday 22 August 2006 03:33, Colin Guthrie wrote: Larry Garfield wrote: http://www.zend.com/phpide/ I just tried to install the modular version for my existing Eclipse install. It insists it won't install without feaure org.eclipse.emf (2.2.0). Since it provides no indication

Re: [PHP] Re: Recommendations for PHP debuggers?

2006-08-26 Thread Larry Garfield
there's now a plugin for it to add projects back in, but it's only available as source. As far as I'm concerned, if it requires a compiler to install then it's not actually released and doesn't actually exist yet. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED

Re: [PHP] functions classes

2006-08-25 Thread Larry Garfield
because of the way it's built. Most code probably isn't quite that bad, though. Your code could already break down into functions quite nicely, or it could be easier to just start from scratch. No way to tell without seeing the code. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED

Re: [PHP] Recommendations for PHP debuggers?

2006-08-22 Thread Larry Garfield
On Tuesday 22 August 2006 00:26, Lester Caine wrote: Larry Garfield wrote: I'm watching this thread closely myself, as I'd love something to use at home (on Linux) that doesn't cost what Zend does. :-) Currently I use PHPeclipse, but it is frankly not that good (the code assistance feature

Re: [PHP] Recommendations for PHP debuggers?

2006-08-21 Thread Larry Garfield
own set of error handlers, which would themselves need constant tweaking, especially as I'm a newbie. -- Dave M G Ubuntu 6.06 LTS Kernel 2.6.17.7 Pentium D Dual Core Processor PHP 5, MySQL 5, Apache 2 -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ

Re: [PHP] Shopping cart

2006-08-21 Thread Larry Garfield
application, of any kind. On Monday 21 August 2006 15:18, Gerry D wrote: So if I understand you gentlemen correctly, these pre-builds serve as examples how NOT to do it? Gerry On 8/20/06, Larry Garfield [EMAIL PROTECTED] wrote: On Sunday 20 August 2006 20:17, Gerry D wrote: On 8/19/06

Re: [PHP] Re: Recommendations for PHP debuggers?

2006-08-21 Thread Larry Garfield
On Monday 21 August 2006 09:52, Colin Guthrie wrote: Larry Garfield wrote: I'm watching this thread closely myself, as I'd love something to use at home (on Linux) that doesn't cost what Zend does. :-) Currently I use PHPeclipse, but it is frankly not that good (the code assistance feature

Re: [PHP] Shopping cart

2006-08-20 Thread Larry Garfield
On Sunday 20 August 2006 20:17, Gerry D wrote: On 8/19/06, Larry Garfield [EMAIL PROTECTED] wrote: OSCommerce is crap. Don't bother. Why do you say that, Larry? I may want to get into an app like that because I think one of my clients is ready for it. What are the cons, and what are my

Re: [PHP] Shopping cart

2006-08-19 Thread Larry Garfield
! Mail has the best spam protection around http://mail.yahoo.com -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called

Re: [PHP] Dhtml/javasript layer tips or software (0.T)

2006-08-18 Thread Larry Garfield
. Probably incurring full point loss for show solution and partial point loss for show hint. As it were though, an Ajax solution is more involved and his request didn't seem to indicate a need for it so I went with KISS :) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED

Re: [PHP] Easier way to get the name of a variable?

2006-08-15 Thread Larry Garfield
that thread ended, so apologies if this is a non-issue. Gah! Please tell me you're joking. That would kill one of PHP's best features, the fact that you can have dynamic data structures. PHP != Java!!! -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012

Re: [PHP] Re: loop in horizontal direction (php-html)

2006-08-10 Thread Larry Garfield
DOM tree breaks down is critical. It also means that whenever you do start sending XHTML as XHTML, you're 90% done with your conversion already. Really, there's no reason in 2006 to not properly close your tags other than pure laziness. -- Larry Garfield AIM: LOLG42 [EMAIL

Re: [PHP] Mixing sprintf and mysql_real_escape_string

2006-08-08 Thread Larry Garfield
rules, including escaping quotes as appropriate. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] Saving a dynamic file

2006-07-29 Thread Larry Garfield
of this message or attachments may be used or reproduced in any manner whatsoever. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power

Re: [PHP] Return Values Copied? Copied if By Reference?

2006-07-26 Thread Larry Garfield
until such time as you modify one of them. If you don't need references then copies are faster than references. By the same token, then, if I have a function that generates a large string and returns it, is there any benefit to return-by-reference? -- Larry Garfield AIM: LOLG42

Re: [PHP] xml v php question

2006-07-25 Thread Larry Garfield
On Tue, July 25, 2006 3:15 pm, Kevin Waterson said: This one time, at band camp, Larry Garfield [EMAIL PROTECTED] wrote: The correct answer is (b). (PHP 6 won't even have short tags, so get used to not having them.) ummm, I think it was decided to stay in php6. I could be mildly/wildly

Re: [PHP] Re: SQL Result Set - HTML Table Fragment (but Simple)

2006-07-24 Thread Larry Garfield
) ) { echo trtd . implode(/tdtd, $row) . /td/tr; } echo /table; The above should work, I think. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] xml v php question

2006-07-24 Thread Larry Garfield
. tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] Enterprise grade CMS+Ecomm

2006-07-20 Thread Larry Garfield
disadvantage: There's a metric fuckton of modules and just as many ways to combine them. The don't code, just configure option is not always easy to figure out because it's just so flexible. (Disclaimer: I am a Drupal developer, albeit a minor one.) -- Larry Garfield AIM: LOLG42

Re: [PHP] GD to database directly

2006-07-10 Thread Larry Garfield
file that can be streamed right off the disk to the server's NIC. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called

Re: [PHP] possible IE problem

2006-07-10 Thread Larry Garfield
.Business.Solution.Developers -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may

Re: [PHP] combine implode() and array_keys() to get a string of key names

2006-07-10 Thread Larry Garfield
/node/30334 -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess

Re: [PHP] global class instance

2006-07-01 Thread Larry Garfield
() { $a-print(); } } i don't want to: - declare global $foo, - use pre-defined $GLOBALS variable, - or use a::print thanks. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others

Re: [PHP] global class instance

2006-07-01 Thread Larry Garfield
You can simulate singletons in PHP 4 as well. But you've just eliminated every option for accessing a non-local object inside a function. You've got 4 options. Pick one, but I'm fairly certain there is no magical 5th. :-) On Saturday 01 July 2006 13:02, sempsteen wrote: Thanks Larry but i'm

Re: [PHP] creating a threaded message system--sorting messages

2006-06-30 Thread Larry Garfield
On Friday 30 June 2006 07:19, Ben Liu wrote: Hi Larry, I've looked through the posts on the PHP general list going back about 3-6 weeks and can't find the thread you speak of. I searched by your name assuming that you posted into the thread and searched by the string recursive and recursion

Re: [PHP] Multiple if() statements

2006-06-29 Thread Larry Garfield
, then it's time to consider a switch -- like thus: switch is fine if your elseif comparisons are equality based. If they're not equality based, then they don't map to switch as well. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any

Re: [PHP] creating a threaded message system--sorting messages

2006-06-29 Thread Larry Garfield
once. You do the sorting in SQL, and then traverse the data recursively in PHP to build the tree. It's a single SQL query. Check the archives for this list for about 3-4 weeks ago, I think. We were just discussing it, and I showed some basic code examples. :-) -- Larry Garfield

Re: [PHP] Preventing double-clicks APPEARS TO WORK FINE

2006-06-26 Thread Larry Garfield
the same thing? Either that, or on the first click, you could disable that button. That would be the Javascript method to accomplish the same thing. :-) It's probably more efficient than a PHP-based solution, modulo the usual Javascript caveats (user can disable, etc.). --Larry Garfield -- PHP

Re: [PHP] If statement question

2006-06-26 Thread Larry Garfield
? If ($number == 1) { mysql_query($blah) } Nope. That's the definition of an if statement (conditional), in any language. If the text fails, the contents of the block never happen. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any

Re: [PHP] New install platform

2006-06-25 Thread Larry Garfield
, but if anyone can help with this, I would truly appreciate it. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea

Re: [PHP] Cookie Question

2006-06-24 Thread Larry Garfield
the cookie-saved version. Remember, cookies are user-supplied data. That means it is not to be trusted. A session key is hard to hijack, or at least harder than it is to fake a non-random-key cookie. It's easier to hijack if it's in the URL GET string rather than a cookie. -- Larry Garfield

Re: [PHP] comparing a string

2006-06-20 Thread Larry Garfield
]; Ross -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long

Re: [PHP] Includes, Require, Location, Other

2006-06-18 Thread Larry Garfield
it cause problems. exit; } else { The rest of the code } -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property

Re: [PHP] Re: File Download Headers

2006-06-16 Thread Larry Garfield
. Chris I think Richard's point, though, was that while it does nothing now, you have no way of knowing when it will start having meaning. Sending garbage headers is sloppy, and opens yourself up to the environment changing out from under you. -- Larry Garfield AIM: LOLG42 [EMAIL

Re: [PHP] Seeking recommendations for use of include()

2006-06-15 Thread Larry Garfield
hole, as explained. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively

Re: [PHP] Using PHP/HTML effectivly

2006-06-15 Thread Larry Garfield
a non-PHP-syntax for your template files, find one. Don't write it. You will thank yourself later. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] declaring a class as stdClass?

2006-06-14 Thread Larry Garfield
= array('apple' = 'red', 'banana' = 'yellow', 'plum' = 'purple'); $MYCLASS = new MyCustomClass(); foreach ($data as $key = $value) $MYCLASS-$key = $value; } ? Dante -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has

Re: [PHP] php-html rendering

2006-06-13 Thread Larry Garfield
this, was he just blowing smoke or is that true? man wget, and look for the -E option (aka --html-extension). -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property

Re: [PHP] php-html rendering

2006-06-13 Thread Larry Garfield
On Tuesday 13 June 2006 17:57, Ryan A wrote: Hey Larry, Thanks again, now i have around 3 different ways of doing this... can assure the client that all will be well, all depends now if the project is confirmed and given to us. But the info you gave me will serve me even if this project

Re: [PHP] Seeking recommendations for use of include()

2006-06-13 Thread Larry Garfield
careful about where those variables come from. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which

Re: [PHP] php-html rendering

2006-06-12 Thread Larry Garfield
wget -m -k http://www.yoursite.com/ Cheers. :-) -- Larry Garfield On Mon, June 12, 2006 10:54 am, Ryan A said: Hey all, heres the short explanation of what I am supposed to do, I need to render/convert the entire site to normal html pages so that it can be loaded onto a cd and given

Re: [PHP] php-html rendering

2006-06-12 Thread Larry Garfield
. :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he

Re: [PHP] Re: How to re-order an array

2006-06-10 Thread Larry Garfield
receiving is from a properly setup client that did the correct JS filtering, or if it's from someone writing as simple bot/script/program that's just sending GET and POST requests to you. Your PHP should never trust the client to be benign. -- Larry Garfield AIM: LOLG42 [EMAIL

Re: [PHP] Update table to get consecutive Primary keys

2006-06-09 Thread Larry Garfield
entire database. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess

Re: [PHP] When is z != z ?

2006-06-05 Thread Larry Garfield
), and resets. So just as 9++ rolls over to 10, z rolls over to aa. Does that make more sense? -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action

Re: [PHP] When is z != z ?

2006-06-05 Thread Larry Garfield
(for some definition of alphabet). It's more useful to deal with strings as strings than to make them quack like numbers. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
to it, and have a delete link which would delete it. How would I do this? I mean if I have multiple blog entry's, how would I delete them without using php my admin? -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
On Sunday 04 June 2006 03:11, Rabin Vincent wrote: On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Make each button a separate form, with the id as a hidden value. Like so: div form method='post' pMy first entry/p input type='hidden' name='id' value='1' / input type='submit

Re: [PHP] When is z != z ?

2006-06-04 Thread Larry Garfield
(0110 0001) and z is DEC 122 (0111 1010) and if I compare a to z , it will always be less by numeric definition. In C or C++, yes. In PHP, do not assume the same string-number mapping. Numeric definition is irrelevant. -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
On Monday 05 June 2006 00:41, Rabin Vincent wrote: On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Only if delete.php is a confirmation page. Never ever ever have a delete function that operates solely by GET. Here's why: http://thedailywtf.com/forums/thread/66166.aspx Yes, I've

Re: [PHP] php/mysql/phpMyAdmin on an iBook?

2006-03-05 Thread Larry E. Ullman
at all! Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Clear POST variables

2006-02-16 Thread Larry E. Ullman
, Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] LIMIT?

2006-02-06 Thread Larry E. Ullman
* FROM `x_news` LIMIT 16 , xx? What you're describing is called pagination. There are examples online. Basically you just need to pass to the second (and other) pages the LIMIT values (16 and xx above). Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP] simple DOM/XML test fails in php

2006-01-20 Thread Larry Hughes
I have a very simple DOM test set up which is failing. Environment is apacie 1.3.x, WIN xp, PHP 5.1.2 ; DOM seetings outlined in phpinfo() indicate various DOM/XML support is enabled. Failing php is: ?php $dom = new DOMDocument('1.0', 'iso-8859-1'); echo $dom-saveXML(); ? which results in:

<    1   2   3   4   5   6   7   8   9   >