Lua vs PHP/Python/JSP/etc [closed] - php

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I'm about to begin my next web development project and wanted to hear about the merits of Lua within the web-development space.
How does Lua compare to PHP/Python/JSP/etc.. for web development?
Any reason why Lua would be a poor choice for a web application language vs the others?

In brief:
Lua gives you a smaller, simpler system that you can understand in its entirety, but it is in a much smaller ecosystem; Kepler is all you get, and you will probably have to build some of your own stuff. I find this easy and fun (I make heavy use of the Lua bindings to the Expat parser and the Lua Object Model, which are part of Kepler), but others may prefer to use what everyone else is using.
PHP started out as more of a macro processor than a language, and although it has improved over the years, when people say "X has really gotten a lot better", I tend to be wary of X. I find PHP offputting, but there is a huge ecosystem for web development.
Python is a nice language but much bigger than Lua, and in the throes of a major revision (transition from 2.5 to 3.x). Again you get a big ecosystem; the problem I have with Python is that the language and system are too big for any one person to understand all of. I don't like to be in this situation if I don't have to.
Ruby is a bit of a cleaner language design, and the large Rails ecosystem is a winner. Ruby is less complex than Python but more complex than Lua. Rails is a bit of a beast.
It comes down to this question:
Would you rather understand all the software in your system, even if you have to build a lot of things yourself?
Or would you rather have a lot of things already built for you, even if you wind up not understanding exactly how every piece works?
If you want to understand everything, Lua is your game. If you want a lot of stuff already built for you, I can't advise you how to pick among PHP/Python/JSP/Rails and so on.
More on Lua and Python at Which language is better to use, Lua or Python?

Using Lua for web development is pretty rare...you could do it, but it will be a lot more time consuming than using a language that has matured as a web developing language (PHP) or has good web related libraries (python/ruby/etc.) If you do go with Lua, this means you may end up "recreating the wheel" a lot for what may be easily available in mature web languages.
The better question is, what does Lua offer that you need which is not offered in the other languages you listed? Or do you want to help Lua become a better web development platform by creating a Lua MVC framework like Rails did for Ruby?

The Kepler project is probably the best known starting point for web application development in Lua. They have a mailing list whose archives will have a lot of discussion of the merits of various approaches.
The Kepler site is itself built in a CMS framework called Sputnik written almost entirely in Lua, and based on the Kepler project.
The typical approach with Lua is to use a language suited to interfacing to various system components to implement those interfaces, and to use Lua for business logic and glue. Kepler provides libraries written largely in C that provide access to file systems, databases, and the network to Lua code. It also provides a defined API layer to interface with the web server, with implementations for Apache, any CGI capable server, and Xavante which is a complete web server implemented mostly in Lua.

I'm coming a little late ... but i wanted to throw in another language: Haxe
why?
Haxe is an open source language, driven by a quite small, but active community
Haxe is a platform indepented language ... targets are:
flash player 6-8 and 9-10 bytecode or ActionScript 3 source code
JavaScript source code
PHP source code
NekoVM bytecode or Neko source code (NekoVM is a lightweight and extensible VM, suitable for both server developement, and desktop apps)
C++ source code
Android Java source code is currently being worked on
this means, that as a web developer, you can write both rich clients as well as servers in the same language ... the same code can be later reused for desktop/mobile apps
Haxe is a very expressive and powerful language, featuring:
first class functions (anonymous functions and methods, which are the same in Haxe) and closures as well as Enums with parameters (much like algebraic types) that allow the use of functional approaches
good type system, including generics, structural subtyping etc. ... to simplify its use, the compiler has a very helpful type inference, that ensures code is strictly typed, but saves you a lot of redundancy (variable type is determined by initialization, function return type by type of returned expressions) ...
cross-platform API, including everything from dynamic arrays, to reflection/introspection and a remoting package, that alows you to send whole objects from client to server, from one platform to another ...
consistent and radical language design ... of course it has a few flaws, but these mostly come from the fact, that it targets extremely different platforms ...
girls love it and it'll make you real rich ... :D
the biggest flaw about Haxe is, that it allows untyped coding, at the cost of platform specific execution of untyped code ... when well typed (which is not a lot of work with Haxe in fact), code will be executed the same way on all platforms ... if not, result vary depending on runtime handling of the platform itself ...
to put it in a few words: it's a great language, that allows you to target many platforms ... it's young, it's growing, and you can participate ...

If it's only the language, then I agree with Norman. If the web development framework is important to you, then you have to consider Ruby because RoR is a very mature framework. I love Python, but there seems to be quite a few frameworks to choose from, none of them is dominant. CherryPy, Django, Pylons, web2py, Zope 2, Zope 3, etc. One important indicator to me is that there are more RoR jobs on the market than any other (language, framework).

As far as Lua web frameworks, there is also LuCI. It is mostly used for small embedded systems. We're just starting a project using it, so I can't comment on it too much right now. We're just doing some simple configuration screens similar to what is already provided as examples, so I'm sure it will be sufficient for our needs.

Related

Web programming Python [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I'm a amateur developer with a little experience in PHP.
I recently learnt Python, I've to admit that it is awesome as a programming language and its great libraries, but using that for web development seems to be a big pain in the ass. As far as what i read, I've to use CGI, mod_wsgi, etc. to deploy (http://docs.python.org/howto/webservers.html), Restart the server to see the changes (http://stackoverflow.com/questions/581038/python-web-programming)
My question is, Python being used so widely for web development, Why cant it be as simple as PHP?
ie i would love to write index.py:
print """
<html>
<head>
<title>Hello world</title>
</head>
<body>
Hello world
</body>
</html>"""
First to your question on why Python isn't as easy for web development as PHP: It hasn't been designed for it. PHP has had a lot of work towards making it a good language to write HTML pages in, including mod_php for apache. Python, while it is a very capable web language, it is also capable of far more than PHP. For example, the majority of Dropbox's software, both the desktop client and the server side code is Python. I use Python in my day job and have used it to integrate legacy C code into new Python code via Cython.
Moving on. There are a number of Python frameworks out there that can make your web development experience far less complicated. 2 of note that are widely used professionally and by hobbyists are Django and Pyramid (formerly Pylons). As a new user I'd recommend you start with Django, it's a great way to get started and can be used for large and complex sites (and more) as your experience grows.
You will find that Django and Pyramid include "development servers". These are web servers written in Python that are packaged with the frameworks to enable faster development. Using these development servers you can get up and running very quickly.
There are also pure Python web servers that are infact incredibly fast, robust and very production ready. To deploy a Pyramid application on Gunicorn, a very good Python server, only takes a couple of extra lines in your Pyramid configuration. Typically you would reverse proxy to these pure Python servers via Apache or Nginx.
If you want to go the Apache server route, you just need mod_wsgi. Serving a Python site with mod_python or as a CGI is a somewhat outdated way of doing it. WSGI defines a standard for Python to handle web requests so mod_wsgi enables apache to pass requests to your Python application in the expected format.
When it comes to deploying Python to a hosting provider, you have to look a little further than you would for PHP hosting, but there is a good list maintained on the official Python wiki. The 4 links at the bottom provided different lists to meet your requirements.
[If] Python being used so widely for web development, Why cant it be as simple as PHP? ie i would love to write index.py...
Python can be as simple as PHP, as per your example. The simplest way to make the above work is to use CGI (and call your file index.cgi rather than index.py, then your script will work just fine. Though you should really specify the content type first, like this:
print 'Content-type: text/html'
This would apply in PHP as much as Python. Python's CGI module will get you up and running very quickly.
As far as what i read, I've to use CGI, mod_wsgi, etc. to deploy
You would normally choose one or the other, and realistically you would most likely choose a framework which is based on the more modern WSGI and not worry about the low-level stuff. But if you don't want to, you don't need to bother with these low-level interfaces.
Restart the server to see the changes
Probably not. Having to restart the server is a limitation of the framework and deployment configuration, and is typically not required. If you use mod_python this may apply, but generally not (many frameworks support auto-reloading, for example).
Python has a great wealth of resources for web development. There are bare-bones systems (eg. CGI, mod_wsgi), lightweight systems (eg. CherryPy) and entire frameworks (eg. Zope). You can choose one that best suits your needs.
Being able to create a simple file and produce some output might help get something going quickly, but it is not really a sign of a rich, mature, featureful framework. Sure, you can start displaying something straight away, but what then? All of a sudden you will need to either import or write all the same sorts of functionality that web frameworks provide. For a non-trivial web app, you need non-trivial framework.
For example, something like Django will give you a persistence framework, auto-generated admin interface, a tempting language, URL dispatch system, and much more. You can focus on your app logic, and not worry about the lower level details. Django is a good place to start, as it has great documentation and the tutorial will get you going very quickly.
As others have said, google "python web framework". There are quite a few, they are all quite different. To get you started the fastest (hours), I'd look at bottle.py.
Python being used so widely for web development, Why cant it be as simple as PHP?
Because Hello World don't scale. Because Python ain't PHP. From wikipedia[1] [2]:
Python is a general-purpose, high-level programming language
PHP is a general-purpose server-side scripting language originally designed for Web development
Python is great, python is DRY friendly. Unfortunately, when it comes to web developement, DRY isn't enough. If you actually want to get things done (efficiently): don't reinvent the wheel. That was pretty well summarized here:
What seems the biggest shame to me is that everyone is currently rebuilding this stuff over and over again and rationalizing it as some sort of secret sauce competitive advantage when it’s really infrastructure – stuff that really should be standardized so you can actually get around to doing the new and interesting stuff.
So, use the right tool for the right job, if you go the python way:
use python and
use a web framework, Django is great (or another one)
reuse packages, browse them at django-packages
maybe use a "meta-framework" like Pinax to get started
use Twitter Bootstrap as an UI framework
use a PaaS like Heroku to deploy (or another one)
Yeah it's more complicated than a hello world but remember there ain't no such thing as a free lunch. You're an amateur developer, you're not a professional coder and a sysadmin and a database admin and a designer and a system architect, etc. Don't be too shy to stand on the shoulders of giants because now, it's free. Please, don't build nothing less than a modern web app.
Also, PHP isn't anymore popular as it was [1][2], cf. PHP's fractal bad design, PHP hammer, etc.
PHP was solely meant for web application development, to be more precise for building Personal Home Page(s) (thats where P, H and P came). Python on the other hand is a general purpose programming language. It was meant for a whole lot of things (and had to include all sorts of batteries for all sorts of tasks). So, please do not expect Python to behave the same way PHP does.
Stand alone python scripts will require quite a bit of efforts to run. I would suggest to pickup a web framework. You might want to learn django (https://www.djangoproject.com/) to begin with. You might also want to give Google App Engine a try. Besides heroku, dotcloud, nuagehq and other cloud hosts make python (and django) deployment very simple and easy.
Hope you'd enjoy developing web apps with Python! :)

What are the relative advantages of various Python/PHP web frameworks (particularly for my project)?

I'm deciding on a web framework for an upcoming project, and I'd appreciate any advice. We've decided to use jQuery for the JavaScript, and are heavily leaning toward Python or PHP (more Python) for our server-side logic. I'm especially interested in web2py because of its jQuery integration.
About our project
Our project is to develop a security console for a complex
cybersecurity system operating within an organization's internal
network.
This console will be largely server-driven, as messages come in from the network and must be pushed by the server to the user.
The user will also be able to initiate security actions, the implementation for which will likely be in C++.
The interface we've planned will be relatively rich, and I want to leverage jQuery's power as much as possible.
We have some control over the browser environment we'll be running in (e.g., we don't have to worry about clients with JavaScript disabled).
Our site is likely to have only a few, long-lived client connections.
We are looking for software components with permissive licenses, though we're using some copyleft components (I see that web2py is LGPL while Django is BSD, so +1 to Django)
We have about a month to create a functional demo of our system, of which this interface is a small (but visible) part.
About us
We are two developers with about 5 years of programming experience, but little web development experience. I have several years of Python experience and a summers' worth of experience messing around with PHP. My coworker has some Python experience and has never touched PHP.
I used Django once back in 2008, and was frustrated by the file and code structure, which I found highly unintuitive. Perhaps this structure is inherent to the MVC model (I've had similar experiences with Django and CakePHP since), and I just need to bite the bullet and memorize it.
My Question
Given the information above, what are the relative advantages of the various Python/PHP web frameworks for our project? As mentioned above, I'm especially interested in web2py because of its jQuery integration, though Django's dominance is (once again) hard to ignore.
Thank you very much for your time!
Before deciding on a framework, you should first decide if you want to commit to a language you are unfamiliar with.
You said you've both got minimal PHP experience, so you have to weigh up the advantages here; Will the pros for going PHP (if any) out weigh the amount of time the developers will need to spend to retrain?
(Although depending on your background experience, PHP should be very easy to pick up.)
If you frame it like that, PHP would have to have a pretty convincing offering to give you. From what I'm seeing, specifically Django vs web2py, they both seem very close in functionality - which is good, but doesn't provide the "you must use x!" scenario you may be after.
However, If you will be bringing more people in later and feel finding people to work with web2py will be difficult, it may tip it to PHP. You said your self, Django's popularity (and BSD license) is hard to ignore, and it should make it easier to find people for later expansion.
If it were me, in your shoes, I would go with web2py. Assuming the development team will continue to be Python focused for the foreseeable future.
Python vs PHP: Python
With python, you can always write wrappers for C code so you won't have to mess with starting other processes and passing args to them. That might be useful for your security functions.
Web2py will allow you to easily write a webservice for this too, to more easily integrate the C portions with the web-site infrastructure.
If you already prefer python, I would go with that. If you need to bring on web-developers later that are trained in PHP, teach them Python. It won't take long, and I'm sure they'll appreciate it in the long run. Plus, moving from a PHP MVC framework to web2py or even django would make things easier. I've used CodeIgniter for PHP and find that web2py was so much simpler and easy to understand.
Also as for the directory structure, django is not actually true MVC -- it's MTV (model, template, view).
I find web2py's organization a little more straight-forward. But yes, either way it can seem strange at first. I would say YES, you should bite the bullet and use MVC.
In web2py, the "view" is html markup with the ability to write raw python code. The controller extracts data from the model (database), attaches any needed files (css/js etc) and the model of course simply defines the structure of the data and allows you to access it in an OO way.
Lastly, I wouldn't tip my hat in favor of web2py just because of jQuery integration. It does use it, and a some of the built-in framework stuff (like response.flash/session.flash, the LOAD function that loads a page or data from another controller) rely on jQuery, but using it in another framework only means you have to write an include statement (e.g. ).
But, the way it allows/forces you to focus on development is what takes the cake for me.
I've been using Django as part of my work for a couple years now and truly enjoy it when I can make it work. Unfortunately, and maybe it's just me, but I end up spending hours working on configuration every time I start a new server, or try to make it work in a development IDE.
It's relatively simple to start a new project and start coding. But there are all sorts of little catches that keep things from working if you deviate from the norm. Things like if you want your django project to serve from a subdirectory like example.com/django. The information is out there to make it work. But it's hard to find.
I can't tell you if web2py has those same problems or not. I only just learned about it from your question. It does look slick and simple though. I can tell you that after the hassles of getting the applications to serve properly from whatever server configuration I'm using, django is way more fun to program with than plain php. PHP frameworks may differ.
From my understanding the project not usual web application, you must need event driven program, web server in python.
Django won't help you here.You should look into Flask, Flask has inbuilt console too.http://werkzeug.pocoo.org/, you might need to use twisted, gevent,Flask jquery.
I would recommend asking about web2py on its mailing list -- you'll get lots of help and advice there. Regarding the LGPL license, note that it only applies to the framework, not your application -- you can license your application however you like, including closed source/commercial.
It sounds like you'll need some server push functionality, but if you'll really only need a few long-lived connections at a time, you might not need to bother with solutions like Twisted or gevent. If necessary, though, web2py does include this (requires Tornado, and works using WebSockets, though can be adapted to use other methods).

What are the fundamental differences between ASP.net and PHP? [duplicate]

This question already has answers here:
Closed 12 years ago.
Possible Duplicate:
.NET & ASP vs PHP
Are there speed differences, performance issues, and what reasons do businesses have when they choose one or the other, is the learning curve steeper for one over the other?
Also... are you likely to be paid more using one over the other?
Microsoft has published a great overview of migrating from PHP to ASP.NET which reveals differences and similarities.
http://msdn.microsoft.com/en-us/library/aa479002.aspx
ASP and PHP are similar in that both tend to put their code in with the HTML, and so the logic can be quite similar.
But, ASP.NET will be very different from PHP in design, as there is a strong incentive to use code-behind in ASP.NET, where you basically have the html template and all the code is in another separate file
Depending on what you are doing, how busy your site is, you may find that the speed difference is inconsequential, though one is compiled and the other isn't.
PHP is probably going to be faster to develop, as you can more easily code a little and test, than you can with ASP.NET, but ASP and PHP are similar in how you can develop.
If you don't know any of these languages then PHP may be the easier one to learn, as the php manual is so well written, with lots of comments from users, and ASP.NET has replaced ASP, so learning ASP for a new project, IMO, is of limited use.
If you go with ASP.NET then you are learning a new syntax and one of the .NET languages, but depending on your background, C# may be relatively easy to learn.
With ASP or ASP.NET you are stuck with using IIS for your server, but with PHP you can use IIS or Apache, so there is considerable flexibility there.
With ASP.NET you will find more options to help with code development, as they now have the classic ASP.NET and ASP.NET MVC (http://www.asp.net/%28S%28d35rmemuuono1wvm1gsp2n45%29%29/mvc/), both with pros and cons, but I believe this site is still written in the latter.
So, which would be better depends on what you are going to be doing with it, and what languages or frameworks you have already gained experience with.
The Microsoft route will have a better learning curve if you are coming from a VB6 or other Microsoft platform. You'll probably have more hardware & licensing requirements to run the Windows Server/IIS/SQL Server/.NET platforms than LAMP. Whether or not you can manage one better than the other is a matter of skill set & probably opinion.
An really important feature of .NET is that it can be used for developing web apps (ASP .NET), desktop apps, web services, Palmtop development, in short pretty much anything (the only problem being it is not cross-platform, unless you count the open source Mono project, which is coming along well). So ASP .NET is only one part of its capability. If you were writing a suite of applications for desktop, web, palm then the same business logic libraries could be re-used for all of these projects.
PHP is pretty much web-only and is specialised in that area.
If you are only interested in creating a web app, then PHP competes well and the learning curve would be much smaller.
.NET is in essence Java rebadged and developed further, with the cross platform capabilities removed.
The most fundamental difference between the two is the language. PHP uses a C-like syntax, while ASP uses Visual Basic as its syntax.
ASP.NET, however, is an entirely different beast; I note you've listed ASP in your title, but ASP.NET in your tags.
ASP.NET is a templating language that can work in front of any .NET programming language, the most common being C# and VB.NET. ASP.NET uses (and comes with) the .NET framework, and is far more object-oriented than either PHP or ASP.
In general, PHP and ASP will seem faster for many tasks, but ASP.NET will provide a better chance at building a robust, maintainable application.
Personally I like the flexibility you get when using PHP. However, ASP.net is quite fast to write a quick application in. It is used by a lot of large companies for web dev as well. Page layout can be done using point and click in Visual Studio though you can directly access the HTML markup and use templates, css etc.
With no adjustments to the languages (besides turning on page caching in asp.net) the benchmarks I have seen point to ASP.net being slightly to moderately faster.
The reason for this is that ASP.net is compiled whereas PHP is an interpreted language.

To ColdFusion (from PHP) for Flex/Flash backend? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 3 years ago.
Improve this question
I'm starting to learn about Flex/Flash and come from a PHP background. It seems that ColdFusion has been the language of choice for Flash/Flex backend. But (the big but for me) I don't plan to build websites that will heavily depend on Flash (for SEO etc.), just websites that will incorporate Flash in small parts of them. I'm thinking for this reason, I'm not going to gain any advantage switching my backend work from PHP to ColdFusion. Since I'm new to the technologies, I'm not sure if that's the right thinking though. Can someone help out comparing PHP vs. ColdFusion (which I'm assuming is Adobe's favorite backend language)? in the context of what I said above would be helpful too. Am I going to be losing a lot of libraries, functionality, convenience, etc. by not doing my backend stuff in ColdFusion.
FWIW. Flash Remoting (AMF) in ColdFusion is much faster than the PHP alternatives. On the magnitude of 40x faster! If performance matters, then ColdFusion is really the only choice.
I have used both CF and PHP for a similar purpose: to execute database queries in the backend from a flash movie front end. These flash movies were, similar to your situation, more or less standalone, not heavily integrated into the website
I found that there is not much that you can acheive with CF that you can with PHP. Database operations are a tad easier to accomplish in CF than PHP, and that's about it. However, if your SQL skills aren't too shabby, this is not much of an issue.
IMHO, your needs are better suited by PHP because it's free, and you can get a WAMP or LAMP rig easily set up as your sandbox. If you just want a sandbox for CF, you either have to pay the sticker price* for the official Adobe software, or get vastly inferior imitations available, such as Railo Server.
Do note that for me, I was able to accomplish database operations on the backend using WAMP/LAMP and Adobe CF, but not with Railo, so that greatly limits your sandboxing experiments with CF. This was 9 months ago though, so you may want to check if Railo has improved since.
As for libraries, there are many more out there available for PHP than CF, due to a much larger developer community. Evidence from Google:
PHP : 15 million hits
CF : 0.5 million hits
In summary: go with PHP.
HTH
Edit:
As mentioned by Al, CF developer's edition is free.
I as well as many others wrote a length answers to ColdFusion Vs PHP which may provide a greater language comparison.
If you only doing small tasks you can stick with HTTP and XML data transfer on the flash side. Unless your moving a lot of data you won't see a great benefit from the AMF ( Adobe Messaging Format ). If you need such binary data transfer PHPAMF is available as is Adobe's open source BlazeDS which comes with ColdFusion and is available separately.
I personally feel you should stick with what ever tool is more comfortable to you. But don't be confused by those who treat ColdFusion as inferior. ColdFusion is a java application as such if you can pull in any and all of the vast java libraries available. Java has more libraries than ANY language even the coveted PHP. Also for development Adobe's ColdFusion is free and well as Railo's Open source offering which bundles with Blaze DS the same open source Java/AMF server that ColdFusion 9 comes with. I personally use Railo and BlazeDs with great success as free open source CFML options.
A few thoughts on the matter, from someone who has developed in both PHP and ColdFusion
ColdFusion has better OO support than PHP5 (or maybe I'm just doing PHP5 OO wrong)
ColdFusion works better with a wide variety of other technologies (Flash/AMF, Databases, LDAP, .NET, Outlook, SMS, SOAP, JSON etc..) out of the box with no addons.
PHP has a smaller memory footprint
PHP is more easily available from shared hosting providers
Having said all of that, if you're looking at building small addons to your website using Flash/Flex there's no reason why you should feel obligated to learn a new language, and redo the rest of your site into CF. PHP will work fine. If you're solely a PHP developer, and you've already got experience with PHP, it might be worthwhile to pick up CFML as a side language, just to open up contracting opportunities, and broaden your horizons, but it's probably not worth it if you're just trying to get this project done quickly, and "the right way"
I'd just like to add another vote for the "Stick with PHP" bandwagon (from an active Coldfusion developer):
PHP is free and has great resources and a good community.
Coldfusion has an ever-decreasing community.
Syntax wise, Coldfusion is an eyesore.
Although Adobe makes both Coldfusion and Flash/Flex, I've found that the advantages to using Coldfusion over PHP for Flash/Flex support are minimal.
As bguiz said, Coldfusion has better support for databases. Specifically, switching from one database to another is easy and painfree. However, once again, the advantages over PHP are minimal.
PHP has full OO support, and support for closures and other helpful functionality.
Learning PHP and using PHP will help you in the future. Learning Coldfusion will (more than likely) make you regret learning Coldfusion.
To me, they are both viable, good options. This isn't necessarily an easy choice, as each language has it's own strengths and weaknesses. Having used both extensively, however, I have to give PHP the edge.
IMO, based on what you're saying (the projects your working on integrating flash and flex with right now only make use of these technologies in small and limited scopes), you'd be insane to switch to CF. That's far too much misery and grief for next to no gain.
That being said, if you ever intend on broadening your scope of usage with these products, you should at the very least concurrently pick up some CF knowledge. If either of these technologies are going to be a significant part of your future development plans, you'll need a knowledge of Coldfusion to determine if switching to Coldfusion is going to provide you with significant ease-of-integration and/or performance benefits.
Unfortunately, there isn't a good online source that can hand-hold you while you learn Coldfusion (like the hundreds that exist for PHP); But finding a Volume 1 for the Coldfusion Web Application Construction Kit (WACK) for either 7 or 8 can give you a good foundation to build on (while I don't know about the CF7 WACK, the Flash and Flex integration are covered in depth in Volume 2 of CF8's WACK; but you'll still need to understand the basics before reviewing that).

Importance of PHP in web oriented platforms

Why is PHP the most used programming language for a web based platform?
PHP:
is easy to learn;
has been around for ~15 years;
runs fairly efficiently;
is cheap to host; and
actually scales really well (some of the largest sites on the internet use it).
PHP is basically the ultimate grass-roots success story.
PHP is:
Built for the web, that is not an extension of an existing language like Perl.
Free of any default framework; this allows it to be fairly lightweight and powerful, a good example of the KISS (Keep It Simple, Stupid) principle.
Because software that values simplicity over everything else propagates faster.
Probably because PHP is easy to learn and it was really simple at first start. With the upcoming of OOP from PHP4 we cannot really say it's simple anymore but at least it tries to keep simple.
Plus from the start the language was really Web oriented, easy access to get/post variables.
You can also note the PHP community is really wide and Zend do a great job to make it a real concurrent of Java/Dotnet/all the others.
Perl/Python/Ruby are also good scripting language but they require some libraries to develop web application
While most CGI language extensions require you to write HTML/JS/CSS within that languages syntax, PHP is able to be used within the contents of an HTML file structure. For someone who doesn't really get the concept of CGI (like I did a while back), it's really nice and offers room to grow with libraries and a universally familiar syntax.
It's also a strategic isue to
choose PHP over Java/Ruby/...
Because you will find PHP
programmers every time, but it is
really difficult to get (cheap)
Java/Ruby/... programmers.
PHP has become the third most be
liked programming language. * **
Its Open Source.
Its old and therefore very stable.
Its the best documented language in the internet.
It has the most string functions (necessary for web/HTML programming).
It has a very huge community, you will find the answer for every PHP question in the internet (or ask stackoverflow).
Its the only language which was designed for the internet.
PHP is fairly easy to install and fairly easy to understand. For that matter, you don't even have to install it. Fifteen dollars a month (or less) will get you a PHP webhost at hundreds of hosting companies.
There are no shortage of "Build a website in 5 minutes with PHP" books. Therefore, it's often the first choice to new web developers or people who want to get something done quickly.
PHP certainly has it warts, but done properly, it can be a good solution as well. Despite its warts, it runs an awful lot of successful websites.
I think it is easy to learn, it is faster, it has lots of forums, it has lots of example codes, it has ...
A lot of emerging php framework like Symfony, Zend, and Cake make rapid development, good mvc design easy. A lot of extremely popular blogging software/cms's are built using php eg. Drupal, Wordpress, and Joomla!.

Categories