Language Barriers

Preview:

DESCRIPTION

Common language barriers in web development and how to bend/break them.

Citation preview

Ă

Language Barriers

PHP vs. JavaJava vs. PHPRails vs. PHPPython vs. RailsEtc..

Enter Web-Development

Language Barriers

Client-Side (Everyone)

HTML,XHTML,CSS,JavaScript,Flash, Flex …

Server-Side (Normal People)

PHP(Cake/Zend/other), Perl, Python(Zope/Turbogears/etc.),

Ruby(Rails/Merb)

Server-Side (“Enterprise”)

Java (JSP,JSF,Seam), ASP.NET(C#,…)

Clear limits to most people

Let’s bend (break) them.

Who here programmed in PHP?

Who here hates PHP ?

By free-will or other reasons.

Introducing Quercus

http://quercus.caucho.com/

Quercus

• PHP5 Interpreter implementation• …• IN JAVA!

Quercus

• Open Source (GPL)• Implements most common php extension

functions.• Can run non-trivial php apps:

Wordpress,Drupal,MediaWiki,phpMyAdmin

Why use it?

1. It’s FAST

Same as PHP+APC, but with more potential for improvement

2. It’s “Enterprisey”

Deploy on your company’s existing J2EE servers/infrastructure.

3. Java Integration

Plays well with your company’s existing java code/modules.

Easy to write extensions in java (hell of a lot easier than c extensions.. )

Code Samples/Workshop

So who is interested in Quercus now?

Drop a line at xmpp:deathy@deathy.info or

cristian.vat@gmail.com

Moving on…

Who here has programmed in JavaScript?

JavaScript +

• Nice language• Multi-paradigm, prototype-based, functional,

imperative, scripting..• Very powerful but very easy entrance level.

JavaScript -

• Browser-incompatibilities• You only use it in the front-end• Can be disabled on some clients.• A lot of libraries (problem of too many choices)• And did I mention.. Browser incompatibilities ?

Introducing SSJS

Server-Side-JavaScript

For the love of God, WHY?!

Geeky reason: Because we can.

Actual Reasons

• You already know JavaScript– Why use it only on the client? Make your skill

more valuable.

• Become a better programming by knowing server-side programming.

• Access to: databases, files, system commands, server-side DOM, etc.

• NO Browser-incompatibilities!

Two major players

• Rhino (by Mozilla, Java)

• SpiderMonkey (by Mozilla, C/C++, APIs for a lot of languages )

Some more advanced solutions

• Aptana JAXER

• AppJet

• Phobos

Code Samples/Workshop

Questions?

The end.

Of the presentation and of common language barriers.

Recommended