Re:PHP is good but....
on
Spring Into PHP 5
·
· Score: 2, Insightful
"Plus the fact that it is a functional language at its core is not too appealing from a OOP perspective. Though, I use it to program my blog, go figure."
I figure that OOP is not the magic bullet many proclaim it to be. That some tasks fit the OOP model very well and others fit the functional model very well. And that PHP is a good language for certain applications, such as your blog.
I don't think 'most people' (i.e. at least 50% of the population) buy a new computer every 3 years. And you even admit that it's only 'most' of them that get a new OS when they do. I think your claim that Windows operating systems are installed on more than 100% of desktop machines is inaccurate. I'll call you when the multinational I work for starts adopting Windows XP on desktop machines over Win2K.
"And we can all reasonably expect that sites want some kind of revenue."
I can accept that SOME sites want some kind of revenue. I didn't mean to imply that I am against all advertising, as such. What I am for is valuable, useful, high quality content and, yes, I am even prepared to pay for that. More so, than I am prepared to pay to download huge images or flash files of no interest to me whatsoever.
I would certainly pay to access some of the sites I visit, incuding those I only visit once or twice. I would only be prepared to spend 'micropayments'; that is all it would take for such sites to pay for themselves several times over. These are the real challenges: how we can develop websites that offer real value for little money to many people. I believe we're close, and I also believe that aim is far more creative and worthwhile than current mainstream advertising. Google revolutionized that already... and they just used text!
Spammers earn huge amounts of money. They spend significant capital - pay for bandwidth, equipment, etc. - yet still make a healthy profit. Almost everyone filters, ignores, or deletes spam. The proportion of the 'target audience' that repays any outlay is minute. Slashdot is probably garnering more hits each day than the number of mailboxes the average individual piece of spam reaches. Slashdot advertises products that are highly targeted to its user base.
My theory: the percentage of users, blocking ALL adverts, that it would take to reduce slashdot's earnings to a level below its expenditure is as near to 100% as to render it pointless discussing anymore.
Ever noticed how the sites that tend to shove flashing adverts down your throat (OK, the current one is not a great example...) also tend to follow it down with mindless amounts of 'data': pointless detailed images, inefficient HTML, the blinking adverts themselves!? Any idea how you might be able to reduce 90% of your bandwidth costs with a few presses of the delete key?
... or at least they don't once someone who is willing to post them publicly buys them.
I totally agree, and maybe that's the kind of model McVoy could be evaluating instead of wasting time bashing the open source community. BigCompanyTM will always be willing to pay for software that does what it needs it to do, open source or not. If it wants OSProduct to implement a certain feature, is willing to pay for that and is willing for the resultant code to be publicly released, might OSDevelopers have a chance of earning some revenue? Just because the code is Open Source, it doesn't mean that every user has the skill and time and desire to hack the code themselves just to implement a desired feature. Does any individual have the time to hack their own kernel AND all the applications they use? No-one knows the code quite as well as the writers.
The description was based on a reading of the article to which I linked. Bind variables may well be the same as parameterized queries; maybe this is all just application-specific semantics.
Parameterized queries are pretty much a given if you're writing stored procs anyway (yes, we're all doing that). And I bet there's a single occurence somewhere of a non-parameterized query that's more efficient than a parameterized one.
OK, I generally agree, but I'll play devil's advocate on a couple of points.
"#1 wastes space with colons." It actually looks like it's using the colon as the field separator to avoid having to deal with whitespace in the message. Although colons could also be present in the message, they're far less likely to occur than spaces. True, it's probably a nasty optimization, and I'm not sure why the colons are augmented with spaces, but it's not all bad.
"#2 doesn't put the date first." Agreed, but, as you point out in #3, his date format makes just that one file non-sortable anyway! And if you're going to be merging and sorting logs of different formats, cut'ing out one field isn't too much of an overhead.
"#3 uses some bizarre ridiculous date format..." Yeah, can't argue with that!;)
"#4 The severities can't be matched by Perl and Ruby's..." I so nearly know what you're referring to here...:)
I'd quite like a site that offers unbaised news, with cleverly moderated user discussion from a broad, representative community. Google news is, well, just news!
Thank you for encouraging me to go learn something new. I'll try to summarise; others more experienced than myself will have to forgive or correct any misinterpretation.
'Bind variables' are, essentially, a database optimization. If you repeatedly execute many queries with the same structure, but different data values, you'll cause the underlying DBMS to repeatedly parse those statements. If you give the DBMS enough of a hint that the statements are, essentially, of the same structure, you can buy quite a lot of that parsing time back.
doing interesting things with computers is much more pleasant with fast hardware
What? Sorry, but that's incredibly subjective. Sure, you might find ray-tracing, video editing, or playing yet-another-first-person-shooter 'interesting'; others prefer designing beautiful frameworks, exploring self-modifying algorithms, or optimising for speed/memory. 'Challenging' is often far more interesting than 'comfortable'.
If everyone had your attitude, we'd be even bigger slaves to the penis-competition that Intel/AMD host.
definitely? That's some claim. Forgive me for being flippant, but... "You can easily automate tasks such as renaming a large group of files". F*** ME! Renaming files!!
Furniture and cars ARE, essentially, free - to 'modify' and 'distribute'. You're using free software because it's gratis, not because it's non-proprietary; otherwise, you agree with the argument...
Is enabling javascript really a problem? Seriously, I think I have an above-average level of web-paranoia (often browse with "warn on cookies", don't have java installed, etc.) but I don't see a reason to disable javascript, especially if it enables me to block what is probably a far more annoying and intrusive technology. AFAIK, javascript has no real privileges over your environment; certainly not as much as java does. If there's a concrete concern regarding javascript, please let me know!
This whole 'report' seems pretty bogus to me. How on earth was this data obtained? I cannot think of any means other than asking people "do you ever delete cookies?". I'd be surprised if 58% of web users could give an at-least-semi accurate description of cookies, let alone know how to delete them. If this percentage is supposed to include cookies deleted 'indirectly' via anti-spyware apps, do these users really know they're deleting cookies? What is the use of a statistic detailing how many people have ever deleted at least one cookie? "Yeah, I deleted a cookie in '97, but I religiously accept all cookies from google.com nowadays..."
If you want to decrease the amount of knowledge you have, remember this statistic.
You had me up until "so programmers can reuse the code and not have to write the same program repeatedly. For example, I use my own networking library". I guess we should all be using your library...
When you say 'Yes' you are explicitly granting the applet full access to your system.
So why doesn't the dialog say "Do you want to grant this applet full access to your system?"? I seriously had no idea an applet could bypass the JVM sandbox - why on earth is this behaviour supported? Couldn't we at least have a set of finer-grained privilege levels?
"Plus the fact that it is a functional language at its core is not too appealing from a OOP perspective. Though, I use it to program my blog, go figure."
I figure that OOP is not the magic bullet many proclaim it to be. That some tasks fit the OOP model very well and others fit the functional model very well. And that PHP is a good language for certain applications, such as your blog.
I don't think 'most people' (i.e. at least 50% of the population) buy a new computer every 3 years. And you even admit that it's only 'most' of them that get a new OS when they do.
I think your claim that Windows operating systems are installed on more than 100% of desktop machines is inaccurate.
I'll call you when the multinational I work for starts adopting Windows XP on desktop machines over Win2K.
But I can't see what it used to be, now! Change it back ;)
"And we can all reasonably expect that sites want some kind of revenue."
... and they just used text!
I can accept that SOME sites want some kind of revenue. I didn't mean to imply that I am against all advertising, as such. What I am for is valuable, useful, high quality content and, yes, I am even prepared to pay for that. More so, than I am prepared to pay to download huge images or flash files of no interest to me whatsoever.
I would certainly pay to access some of the sites I visit, incuding those I only visit once or twice. I would only be prepared to spend 'micropayments'; that is all it would take for such sites to pay for themselves several times over. These are the real challenges: how we can develop websites that offer real value for little money to many people. I believe we're close, and I also believe that aim is far more creative and worthwhile than current mainstream advertising. Google revolutionized that already
Spammers earn huge amounts of money. They spend significant capital - pay for bandwidth, equipment, etc. - yet still make a healthy profit. Almost everyone filters, ignores, or deletes spam. The proportion of the 'target audience' that repays any outlay is minute. Slashdot is probably garnering more hits each day than the number of mailboxes the average individual piece of spam reaches. Slashdot advertises products that are highly targeted to its user base.
My theory: the percentage of users, blocking ALL adverts, that it would take to reduce slashdot's earnings to a level below its expenditure is as near to 100% as to render it pointless discussing anymore.
Ever noticed how the sites that tend to shove flashing adverts down your throat (OK, the current one is not a great example ...) also tend to follow it down with mindless amounts of 'data': pointless detailed images, inefficient HTML, the blinking adverts themselves!? Any idea how you might be able to reduce 90% of your bandwidth costs with a few presses of the delete key?
I totally agree, and maybe that's the kind of model McVoy could be evaluating instead of wasting time bashing the open source community.
BigCompanyTM will always be willing to pay for software that does what it needs it to do, open source or not. If it wants OSProduct to implement a certain feature, is willing to pay for that and is willing for the resultant code to be publicly released, might OSDevelopers have a chance of earning some revenue?
Just because the code is Open Source, it doesn't mean that every user has the skill and time and desire to hack the code themselves just to implement a desired feature. Does any individual have the time to hack their own kernel AND all the applications they use? No-one knows the code quite as well as the writers.
The description was based on a reading of the article to which I linked. Bind variables may well be the same as parameterized queries; maybe this is all just application-specific semantics.
Parameterized queries are pretty much a given if you're writing stored procs anyway (yes, we're all doing that). And I bet there's a single occurence somewhere of a non-parameterized query that's more efficient than a parameterized one.
OK, I generally agree, but I'll play devil's advocate on a couple of points.
;)
:)
"#1 wastes space with colons."
It actually looks like it's using the colon as the field separator to avoid having to deal with whitespace in the message. Although colons could also be present in the message, they're far less likely to occur than spaces. True, it's probably a nasty optimization, and I'm not sure why the colons are augmented with spaces, but it's not all bad.
"#2 doesn't put the date first."
Agreed, but, as you point out in #3, his date format makes just that one file non-sortable anyway! And if you're going to be merging and sorting logs of different formats, cut'ing out one field isn't too much of an overhead.
"#3 uses some bizarre ridiculous date format..."
Yeah, can't argue with that!
"#4 The severities can't be matched by Perl and Ruby's..."
I so nearly know what you're referring to here...
I'd quite like a site that offers unbaised news, with cleverly moderated user discussion from a broad, representative community. Google news is, well, just news!
But what if your email is down? ;-)
...
Seriously, there's no way out of this one. Anyone have a logging-to-file system that, er, logs its logging in a file
Thank you for encouraging me to go learn something new. I'll try to summarise; others more experienced than myself will have to forgive or correct any misinterpretation.
:cust_no;
'Bind variables' are, essentially, a database optimization. If you repeatedly execute many queries with the same structure, but different data values, you'll cause the underlying DBMS to repeatedly parse those statements. If you give the DBMS enough of a hint that the statements are, essentially, of the same structure, you can buy quite a lot of that parsing time back.
A good example piece of SQL using a bind variable:
(culled from http://www.rittman.net/archives/000832.html)
SELECT first_name, last_name, postcode FROM customers WHERE id =
Each time you execute that statement, you'll pass it a different value for cust_no, but the DBMS will only parse that statement once.
This almost certainly varies with application - not sure MySQL offers this support quite yet.
Not sure how this combines with stored procs, either.
Got any good suggestions?
What? Sorry, but that's incredibly subjective. Sure, you might find ray-tracing, video editing, or playing yet-another-first-person-shooter 'interesting'; others prefer designing beautiful frameworks, exploring self-modifying algorithms, or optimising for speed/memory. 'Challenging' is often far more interesting than 'comfortable'.
If everyone had your attitude, we'd be even bigger slaves to the penis-competition that Intel/AMD host.
Or of any kind of optimization.
definitely? That's some claim. Forgive me for being flippant, but ... "You can easily automate tasks such as renaming a large group of files". F*** ME! Renaming files!!
Furniture and cars ARE, essentially, free - to 'modify' and 'distribute'. You're using free software because it's gratis, not because it's non-proprietary; otherwise, you agree with the argument...
Is enabling javascript really a problem? Seriously, I think I have an above-average level of web-paranoia (often browse with "warn on cookies", don't have java installed, etc.) but I don't see a reason to disable javascript, especially if it enables me to block what is probably a far more annoying and intrusive technology. AFAIK, javascript has no real privileges over your environment; certainly not as much as java does.
If there's a concrete concern regarding javascript, please let me know!
"It's a BIG improvement over the vanilla IE, and it uses the same rendering engine."
;)
Aren't those two mutually exclusive?
This whole 'report' seems pretty bogus to me. How on earth was this data obtained? I cannot think of any means other than asking people "do you ever delete cookies?". I'd be surprised if 58% of web users could give an at-least-semi accurate description of cookies, let alone know how to delete them. If this percentage is supposed to include cookies deleted 'indirectly' via anti-spyware apps, do these users really know they're deleting cookies? What is the use of a statistic detailing how many people have ever deleted at least one cookie? "Yeah, I deleted a cookie in '97, but I religiously accept all cookies from google.com nowadays..."
If you want to decrease the amount of knowledge you have, remember this statistic.
You had me up until "so programmers can reuse the code and not have to write the same program repeatedly. For example, I use my own networking library". I guess we should all be using your library...
So why doesn't the dialog say "Do you want to grant this applet full access to your system?"? I seriously had no idea an applet could bypass the JVM sandbox - why on earth is this behaviour supported? Couldn't we at least have a set of finer-grained privilege levels?
It takes you 7.2 hours to nuke a hard-drive and (re)install XP??
Too right. In my opinion, letting users load any binary they haven't hand-compiled from their own code is just BEGGING for problems...