Professional PHP

PHP Programming, Web Development, PHP Advocacy and PHP Best Practices.
« Modularity
Why is PHP Popular? »

Classpath Considered Harmful

April 26th, 2004

I am glad to see I am not the only one who has problems with classpaths in java. Many of the advantages that python has over java, PHP has as well. Lack of classpath is certainly one of them, but dynamic typing is my favorite.

categories PHP
tags java, language-comparison, PHP

Related Posts

  • Exceptional PHP
  • goto in PHP
  • Happy 20th B-day Corewars
  • Why is PHP Code Considered Hard to Maintain?
  • James Gosling on PHP
You can leave a response, or trackback from your own site.

2 Responses to “Classpath Considered Harmful”

  1. #1 Harry Fuecks responds...
    April 27th, 2004 at 2:42 am

    Comparing PHP with Python is an interesting experience; there is alot of common ground, although Python aims to be a general purpose language while PHP targets web applications. The other division on typing is strong vs. weak and I think it’s fair to say Python is strongly typed while PHP is weakly typed e.g.;

    Python;

    $myInt = 4;
    print "The number is "+myInt; # Illegal interpolation
    print "The number is "+str(myInt); # Cast to string

    PHP;


    myInt = 4;
    print "The number is ".$myInt;

    That works in PHP’s favor when it comes to generating HTML while, at the same time, more effort is needed if you want to validate a submitted variable, to check it’s an integer.

    Python generally feels “better rounded”; there are many things I’d love to see in PHP, import in particular plus things like distutils and the notion that everything is an object.

    At the same time think PHP’s class syntax is preferable, hiding you from the fact that the interpreter really regards objects as glorified hashes while Python requires you specify the self reference inside a class.

    Also Python hasn’t got databases nailed down yet, at least when it comes to using a DB to “drive” a website. John Lim is working on porting ADOdb to Python: http://php.weblogs.com/adodb_python

  2. Die wunderbare Welt von Isotopp trackbacked on May 2nd, 2004 at 4:24 am

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

code: use [code=php][/code].

Comment Preview

  • Search

  • Subscribe

    Subscribe All Posts
    Subscribe All Comments
    Subscribe All Bookmarks
    Subscribe with Bloglines Subscribe with My Yahoo Add to netvibes Subscribe in NewsGator Online Add to Google
  • Share This

  • Categories (Home)

    • Agile Methods (14)
    • Mac (14)
    • Misc (16)
    • Open Source (14)
    • PHP (95)
    • Software Design (28)
    • Usability (14)
    • WACT (7)
    • Web Design (20)
  • Recent Comments

    • Working with PHP 5 in Mac OS X 10.5 (Leopard)  94
      noujoum, Michiel Van Kets, isorabins [...]
    • Sarah Snow Stever  24
      Dubai Web Design, Development, Snowcore, ennah [...]
    • Benchmarking PHP's Magic Methods  8
      stas, minikperi, Shelon Padmore [...]
    • Keywords and Language Simplicity  7
      olmse, Handy, minikperi [...]
    • Even the Big Guys Get Validation Wrong  4
      James Benson, Michael, Enric Naval [...]
    • Improved Error Messages in PHP 5  12
      James Benson, Iron, baggreeddog [...]
    • How to Transfer Mac OS X Application Data between Computers  36
      Secret Santa, micala, Khaled bin Alwaleed [...]
    • Programming Language Trends via Google  15
      MattW, Jeff Davis, retry [...]
    • PHP Development From Java Architects Eye  10
      Grrkkvho, Bobrila, FelhoBacsi [...]
    • The value of MVC  9
      Euvmetkk, Bobrila, Vulchak [...]
    • nofollow and comment spam  5
      Scopmazo, Qmumqckx, sss [...]
  • Pages

    • Tags
  • Recent Posts

    • php | tek Wrapup
    • php | tek 2008
    • Sarah Snow Stever
    • Benchmarking PHP’s Magic Methods
    • The Endpoints of the Scale of Stupidity on Video
    • Working with PHP 5 in Mac OS X 10.5 (Leopard)
    • Keywords and Language Simplicity
    • Improved Error Messages in PHP 5
    • Michigan Taxes Graphic Design Services
    • Ruby versus PHP or There and Back Again
  • Archives

    • 2008: May
    • 2007: Jan Feb Mar Apr May Sep Oct Nov
    • 2006: Jan Feb Mar Apr May Jun Jul Oct Nov Dec
    • 2005: Jan Feb Mar Apr May Sep Oct Nov Dec
    • 2004: Apr May Jun Jul Aug Sep Oct Nov
  • Menu

    • Register
    • Log in