Slashdot Mirror


User: MacFanMR

MacFanMR's activity in the archive.

Stories
0
Comments
6
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 6

  1. It's correct, but but not complete on PHP Hacks · · Score: 2, Insightful

    All of those observations are true, but that doesn't mean you shouldn't use PHP. As with any tool, you must consider the user, their skill level, and the project requirements when making your decision.

    Many of PHP's inconsistencies stem from the fact that it is an open source language. While it has likely changed now, many functions were accepted into the source without anyone ensuring a consistent naming scheme, parameter order or behavior. To maintain backward compatibility for what is now a very large user base, this cannot be easily changed at this point.

    Several of the examples of redundant functions are not redundant at all. The escaping functions relate to the specific database they are escaping the data for. Oracle requires that things be escaped differently than MySQL, a single function wouldn't work.

    That aside, there are many functions that perform tasks you could accomplish in other ways. For instance, finding if a string contains another string. I might use strpos('mystring', 'my') but there is also a function that is named specifically for the purpose of finding whether a string contains another string. That function would return a simple true/false while my example would actually return the position of the substring or false but I can interpret it to tell me what I need to know. My guess was that the extra functions are an attempt to make the language accessible to less experienced programmers. For me, I would rather write my own functions as needed than muddy the PHP parser with extra functions, but I'm not on the development team so it's not my decision to make.

    PHP has namespaces though they are not formal and therefore not as efficient. For example, all the MySQL functions begin with mysql_ and pSpell functions begin with pspell_. Starting with PHP5 and full OOP support, they now have class based namespaces like SOAPServer::addFunction(). Each namespace regardless of type, represents a package compiled into PHP. Though the default compile comes with many packages installed, you can decrease the number of functions by compiling without support for DBs and other packages you don't need. This would decrease the number of functions PHP is parsing for (correct me if I'm wrong on this.)

    Perl may be compact, but if you notice in the examples, for someone who isn't familiar with Perl, the code provided wouldn't be immediately understandable, and Perl code can be optimized and obfuscated even more than that.

    On the flip side is Java, which at its core is compact, but with the Java standard library of methods, there are nearly unlimited numbers of methods to do just about anything and everything you could ever think of. Add to that the frameworks that exist: struts, beans, servlets, jsp... just to scratch the surface and we find that Java is infinitely flexible and powerful. For those that know it, it is probably the greatest thing ever, but for someone starting out, it is incredibly overwhelming.

    If you use PHP and it fulfills your needs, then keep using it. If you run into a lot of limitations or frustrations because it can't do things you could do in xyz language, or because you are building projects that become difficult to maintain due to their scale, then you might want to explore other options. Ruby/Perl/Java/ASP/Cold Fusion has its pros and cons as much as PHP or anything else. It's up to you as the professional to evaluate your specific needs and options and make the right decision for you.

    Michael

  2. One room schoolhouse on Improving Education? · · Score: 1

    Maybe we need to go back to the one room schoolhouse style of teaching. This would provide many benefits:

    - For students who excel, they could be learning things at the higher levels aimed at the older kids. There would be no real grade level exactly, more just a decision by the teacher of when to move on.

    - Students who need review of prior teachings, would automatically get that when it was taught to the younger students.

    - The mixed age levels would help students gain skills in working with people older or younger than they are. This is important in the job world. This and having no real grade levels could possibly break down some of the 6th graders are better than 5th graders attitudes.

    - The classes should have a significant amount of time when content is not taught by the teacher, but by other students. While they shouldn't be expected to learn something this hour, and teach it the next, students who are further along could help those who are not. This would provide a sense of responsibility and respect among their peers. It would develop valuable teaching skills, something you will need no matter what the field you go into. Being able to teach something, often requires the ability to put it into different terms based on your audience, this requires advanced thought and a deeper understanding of the subject. Both would benefit from this. Additionally, a fellow student might be able to present it in a way that another student might understand better, possibly by relating it to something more relevant to the age-group.

    You could have maybe 2 levels.. grades 1-6 and 7-12... You could advance through both levels in the time it takes you... more or less than the rest, it doesn't really matter. In fact, since your "class" would effectively encompass 6 years worth of students, you could graduate with a portion of those students at any given time so the idea that being held back (not that it would be the case in this scenario) preventing them from graduating with their friends, would be less of an issue.

    Michael

  3. Re:Have a taste... on Apple Switching to Intel · · Score: 1

    "Too bad. I'd like to run OS X w/out having to pay an Apple hardware premium."

    As much as we would all like lower prices, one of the reasons that Apple has been able to achieve the features, integration and "it just works" operability they have (with some exceptions, I admit) is because they control the hardware.

    If they had to support every Tom, Dick and Harry's generic $20 DVD-R drive, I doubt burning a DVD would be simply a matter of dropping in a disc and clicking a button. I'm sure Windows would be much more reliable if they didn't have that precedent.

    It is definitely not always the case, but sometimes you do get what you pay for. You are paying for a certain amount of "name recognition" in a BMW. But you can look at everything in the car and tell that it was thought out fully during the design process. Other cars have many features that result in asking "what were they thinking?"

    Michael
  4. DirecTV not dropping Tivo on DirecTV's 1st MPEG4 Satellite Launch Successful · · Score: 1

    DTV is not dropping Tivo. DirecTV was purchased by NewsCorp which is owned by Rupert Murdoch as we know. One of his other companies happened to be working on a DVR already. So yes, they will be offering that as an option as well.

    But... the NDS DVR isn't out yet and DTV is still actively promoting Tivo both on-air and through combo deals to sign up for service. DTV's contract with Tivo lasts through 2007, and even then they can't just drop Tivo overnight. By the end of January, Tivo had signed up 3 million subscribers, and approx 2/3 of those are DTV subscribers. DTV would be foolish to drop support for something that 2 million of their customers know and love, especially since even if the NDS box is free, if it has problems or just doesn't live up to Tivo, there will likely be a customer backlash.

    Take for example Comcast's own foray into DVR land. Users were less than satisfied [login required] and as a result, Comcast recently struck a deal with Tivo to co-develop a DVR based on Tivo technology.

    Meanwhile Tivo has released a SDK and encouraged Java programmers to develop applications to make Tivo even more useful. Imagine shows like Survivor! that auction off props at the end of the season for charity being able to send you directly to Ebay on your Tivo!

    There are also rumors of a partnership or aquisition of Tivo by Google for an as yet announced Video search/play on-demand product. Tivo already has a partnertship with Netflix to explore and develop technology for on-demand movie downloads.

    Tivo needs to work hard in the coming months, but overall I think rumors of Tivo's imminent demise have been greatly exaggerated.

  5. Government should provide where companies do not on SBC Promotes Texas Anti-Wireless Bill · · Score: 1

    When a commercial entity such as SBC considers installing broadband access in a neighborhood, they have to consider the business case for it. I built a house a year and a half ago in a quickly developing affluent area. It was in an established community with my house going into Phase 4. SBC said that although they would only need to add a DSL switch in their nearby office, they had no plans to offer DSL service in my area for at least 6-12 months (I haven't heard if they ever did install it.) The 3 local cable providers each thought the other was installing service and as a result I was stuck with remote access to work over dial-up for my first 6 months there. Meanwhile I worked my way up to the community developer who pressured Charter into putting in service.

    In time, there will be no need for phone books, landline phones, music CDs, or DVD movies. But we're not going to get there without widespread accessibility to broadband service. And widespread accessibility won't happen without a compelling business case for each area. Therefore, if governments want to promote technology and the benefits it brings (despite the negatives), their only option in many cases is to provide the service that commercial entities see no need for.

    Just because it is installed by the government doesn't mean it is free. Though there is a move toward privatization, many public sewers and water services, are still provided by government entities in many communities, and those things don't come without a monthly bill.

    Still, for the cost of some lawyers and lobbiests, companies such as SBC are trying to prevent this from occurring "just in case" they might want to offer service some day... at their convenience.... if they feel like it.

    I don't think government should compete with existing installs, but in areas where there are none, I applaud the goal of governments changing that for their citizens. If a company wants to object, then they should have to show proof that they were intending to install there and then be given a reasonable deadline for installation of their service. If they are unable to complete it, then the government is free to do it themselves. Governments may in time, want to sell off that division to a local company but it should be priced as any company with existing customers would. The government took the business risk where the other company didn't, that company shouldn't be able to benefit from that by getting a special deal on it.

  6. Go Phish on Millions of Pages Google Hijacked using ODP Feed · · Score: 2, Insightful

    This has very real potential to be taken advantage of for phishing scams.

    Imagine someone searching for their bank's website on Google (because some think that [searching] is how the web works!) and clicking the wrong link. That link takes them to a site that looks just like their bank's website, and maybe there is a security alert on the front page asking them to verify their information. After doing so, they could be redirected to their real bank's site, never having realized their error.

    Experience has shown me that most non-techies know they type an address into their browser, but after that, they pay no attention to it which makes this a real possibility.