views:

336

answers:

13

We're starting to think about the next stage of our company information strategy.

At the moment various departments have Delphi VCL applications that focus on the information that they manage about their Projects. Behind the scenes we've been making sure that the thinking joins up.

We're now at the point where we want to give people the opportunity to browse all the information the we have on either a Project-by-Project basis or search aspect.

We think it will be a web based interface (at least intranet) but are stuck on what to write it in!

Options seem to be Java, PHP or Ruby. Any of the above will involve us learning a new language (no budget for new hires) so we're looking for guidance

+1  A: 

Although I don't particularly like the language, PHP is probably the easiest to learn. Ruby would not be far behind, although I have no experience with it.

Java, although I love it, is extremely difficult when it comes to setting up and maintaining a web interface. Too many intricacies with XML files, JSPs, Java files, ...

Jonathan
I don't think it's fair to say Java is 'extremely difficult'. All you have to know is the structure of a Java web-archive (WAR) file, how to write HTML (that goes in your JSPs) and maybe a little JSTL. All this is incredibly well documented and after that it's mainstream OO all the way.
Nick Holt
@Nick I agree that it's straightforward, but I've been writing Java for years and recently had to create my first Web UI using it, and I thought it was difficult. I can't even imagine how it would be for someone who didn't know the language to start with...
Jonathan
Hey Jonathan - how much of that do you think was down to understanding how web-apps work in general? I know http requests/responses, forwards, redirects, sessions, css, etc was by far the most confusing bit when I first did web development and those hurdles will exist regardless of technology.
Nick Holt
I've written a couple of simple web servers in various languages, mostly for school projects. The difficulty is in knowing why you are getting various error messages, what permissions you need to give the app, ... And, if you use a framework (I've used Struts2), difficulties increase exponentially. It may be worth it for the scalability, but it's not a good place to start.
Jonathan
+1  A: 

Of course it's all very personal, but PHP doesn't have a steep learning curve like Java with its related web technologies.

After installing, you can get productive almost right away, even if you hardly have any previous knowledge of the language. I think that's once of the main reasons for PHP's popularity.

  1. create a new file with notepad
  2. type: <?php echo "hello!" ?>
  3. save as hello.php

now access it as http://www.yourserver.com/hello.php And you'll see Hello!

That's it.

The web is full of examples and documentation, and it's really easy to integrate PHP with databases like MySQL. I oftenly use MySQL as the glue between my Delphi applications and websites.

Wouter van Nifterick
yeah ... ruby is just `puts 'Hello world'` ... and using a proper ide with file templates, even the overhead required by java is not a problem at all ...
back2dos
+2  A: 

I don't believe that there's any huge advantage in either one for what you are trying to do. Plenty of people here will support each option (hopefully without a flame-war).

As none of them are familiar why don't you try creating the same tiny prototype in all three and see which you prefer? Your best option is to pick a framework from each and base your efforts on those eg. CakePHP, Ruby on Rails, GWT etc.

Damo
+2  A: 

By far the biggest hurdle you're going to face is learning about how to build web applications whatever technology you pick - the paradigms are quite different to a traditional thick client apps and while this isn't insurmountable I'd recommend hiring somebody with a web-app skill set if only to get you up and running.

Coming from a Delphi background you'll probably feel more comfortable with Java as a language but I've managed to avoid PHP and not used Ruby so can't really give a fair appraisal.

What I would say for Java is that once you've got the basics of web development down it's incredible powerful, allowing you to build code in a structured way with distinct layers and separated concerns.

There's also a huge wealth of open-source APIs, which these days allow you to focus on the business problems, simply picking and choosing libraries that support your solutions. Also throw into this mix the support for automated testing and you've got a powerful combination in Java.

Nick Holt
+1  A: 

Ruby (on Rails) is quick to learn and it has great community support. Now that I've become comfortable with it, I would not write a web app in anything else. My only negative experience with rails is when DHH rejected my friend request on Facebook - c'est la vie. ;)

cakeforcerberus
+4  A: 

You should understand the pros and cons of as many languages and frameworks that you can. I happen to know all three (PHP, Java, and Ruby) and have written many applications in all of them (plus others), but I drastically prefer Ruby. I'm not sure I would appreciate Ruby as much as I do if I didn't have experience in other languages.

Ryan McGeary
A: 

I think you should choose between Python or Ruby. Both have similar capabilities, with relevant frameworks. I think it's largely a stylistic preference, so you should spend time looking at the syntax of both languages.

Since you weren't initially considering Python, check out this video on the Django framework: http://video.google.com/videoplay?docid=-70449010942275062

Anon
A: 

From a pragmatic standpoint, Java probably has the most power and flexibility, PHP is probably the most widespread but tends to encourage bad coding if you're not careful (I have yet to see a PHP app where I said "Wow, this code is pretty"), and Ruby/Rails is easy to learn and really fast to develop on, but everything is pretty much decided for you (not necessarily a bad thing) and when you step away from the "Rails" way of doing things, it can get messy.

MattC
Just to elaborate, my comment about PHP's large installed base was in reference to being able to source talent for it if you wanted to bring someone in to help.
MattC
If you can consider the majority of PHP programmers 'talent'... (Not a slight against or PHP or any competent programmer who happens to know it, but because of how accessable it is there are far more barely capable people who "know" PHP then in any other language I can think of [even VB managed to set the entry bar to the level of community college night school grads]).
David
A: 

If you're looking for easiest transition from Delphi, consider Flex. It has the same RAD interface-builder that you're used to in Delphi, it's backed by object-oriented ActionScript and since your site is internal you can mandate using Flash on all client computers.

Besides, Flex rules. Really)

Yoni Roit
+1  A: 

The hardest part of web development is the new paradigm. The next hardest part is picking the right framework. I would add two languages to your considerations:

  1. Python (with Django)
  2. ASP.NET

In many ways the Microsoft stack will certainly take a lot of potential mistakes off of your plate, in that it gives you a lot of the framework decisions in a nice package. Of course, you may not like the whole package. Ruby on Rails is kind of the same thing in that respect (giving you the package, that is, but not as much as Microsoft).

But regardless of your choice, the just as important (with the exception of PHP since it is a web language to begin with) is the web framework.

And an important driver in your decision should be the size of the project. A small project won't shoot itself in the foot too bad even on poorly written PHP, but a very large project can certainly get very messy in a dynamic language when everyone is learning it for the first time. It depends on the type of team you have.

Yishai
Why Django? What's your reason to suggest django?
jpartogi
Mainly popularity. I don't mean that in the popularity contest sense, but rather it is the framework that gets the most support and community attention in python.
Yishai
+1  A: 

given the options, i'd go for ruby ... mostly because it is such an extremely beautiful, powerful, expressive, consistent and radical language ... you can get a very good introduction here ... plus ruby-on-rails and merb (which are united in rails 3) are very productive environements/frameworks to develop apps ... i personally don't know anything which is so suited for fast developement of server driven applications ... also ruby is very good for scripting ...

there are many things i dislike about PHP and Java, but let's not get into details ... my main accusations would be, that Java is quite verbose and bloated, and the most used frameworks even more so ... and PHP has a terrible API design and quite a lot of semantical inconsistencies, even some syntactical, although most of the latter are getting resolved recently ... plus, it is not very fast ... and also, you get many downvotes on stackoverflow, when you critisize one of the languages ... :D

however, a reason to use Java is the massive ammount of tools available (allthough only a part of them is relevant for the web) ... when it comes to PHP, the best thing is deployment ... it's very easy to get PHP running on a server ... and most servers have PHP anyway ... so if you want to write software, that can run on many servers, PHP is the best choice ... if you decide to use it, do yourself a favor, and use it only with a proper framework/environment, as Flow3, Zend, synfony, codeigniter or CakePHP ... PHP makes it easy to hack together some code (i'd even dare to say it was kind of designed for that) ... but you'll quickly regret that you relied on that ...

the microsoft stack was already mentioned as a possible alternative ... up to you to decide ... it's good, but expensive (licenses make scaling much more expensive) ... and IIS has relatively much downtime compared to other servers ...

personally, i'd suggest you use haXe ... a very nice and expressive language, that allows you to compile to

  • AVM1 or AVM2 bytecode (virtual machines for flash player 6-8 and 9-10)
  • neko bytecode (neko is a very fast and lightweight virtual machine, suitable for writing web servers, daemons or desktop apps)
  • JavaScript source code
  • ActionScript 3 source code
  • PHP source code
  • C++ source code (using neash, you can use flash player API with C++, most notably the display/graphics API, which is very easy to use)
  • Java source code for android (currently prealpha, but demo looks good) ...

you use a single language to

  • write servers (be it HTTP or TCP)
  • create rich clients (be it javascript or flash)
  • target smartphones (either flash smart phones or iPhone through C++ (well, still not optimal, but progress is being made) and, in near future, Android ...
  • build desktop apps

on top of that haXe is an open source community driven language ... plus of course haXe has a very consistent OO API design and provides many cool languages features, such as high order functions, parametrized enums, generics, and structural subtyping ... and if you decide to use it, be sure to check out haxelib for helpful frameworks/libraries ... ;)

back2dos
+3  A: 

Why learn a new language at all? Since you're Delphi developers already, use Delphi. It has VCL for the Web (formerly IntraWeb), which gives you the ability to create pretty good web applications with almost the same functional capabilities as a Delphi Win32 application. IntraWeb (under either name) works like you're used to, right in the IDE, and lets you write Delphi code just like always. It's a viable web solution, especially for shops that have lots of Delphi code already; much of the business logic can be used as is, if it's not tied to the GUI.

You didn't mention what version of Delphi you're using, but there are demos of VCL for the Web or InterWeb in both Delphi 7 (%DELPHI%\Demos\IntraWeb) and Delphi 2007 (C:\Documents and Settings\All Users\Documents\RAD Studio\5.0\Demos\IntraWeb\Win32 on WinXP). Delphi 2009 puts them in yet another location (C:\Documents and Settings\All Users\Documents\RAD Studio\6.0\Demos on WinXP). I'd start with the Features demo regardless of where it's located on your version of Delphi, as it gives a good overview of the capabilities.

Disclaimer: I am in no way affiliated with IntraWeb, VCL for the Web, or CodeGear/Embarcadero. Just a Delphi user since 1995.

Ken White
Makes perfect sense seeing as you want to add a web-based UI to an existing application that already has a ton of logic written in Delphi
Steve Claridge
I think that this probably makes the most sense in the first instance - explore whether I can do what I want in Delphi - before looking at the others. Thanks all - lot's to think on!
Dan Kelly
A: 

Going from Delphi world to web world? Use C#, since there is a spirit of Delphi in C# (all right, this spirit is Anders Hejlsberg). When learning C# I found a lot of concepts similar to Delphi.

smok1