Monday, December 7, 2009

PHP Development on Windows for Beginners

First thing is to set up a Development Environment fast. Download XAMPP from:
http://www.apachefriends.org/

Download the PHP Manual in CHM format from:
http://www.php.net/get/php_manual_en.chm/from/a/mirror

For writing code, there are loads of editors:
PDT (download this for easy installation)
PHP Eclipse (download this for easy installation)
Notepad++ (basic editor, what I use)
Dreamweaver (Commercial, but good to use if you already use it)
NetBeans


Install XAMPP on the root of any of your drives, e.g. C:\ or D:\
This will prevent most of the problems that we come across during development.
Make sure Port 80 is free (e.g. stop IIS) and you do not have MySQL installed or running from before.

Once extracted, go to the folder and double click "xampp-control.exe". Start Apache and MySQL and then go to http://localhost/xampp

To start developing, create your files/sub-folders in the folder C:\xampp\htdocs (assuming you installed on C: root)

The PHP Manual CHM file is probably the best resource I have come across when starting with PHP development. It has loads of tutorials and examples.

Sunday, August 2, 2009

History of Operating Systems GUIs

Came across this awesome list of operating system GUIs today. Just had to share it on my blog. It shows the evolution of GUI design.

Monday, May 25, 2009

Business Intelligence for the Layman

I came across a very simple explanation of what a Business Intelligence solution does for the end user that other existing solutions cannot do. Read it here.

Tuesday, May 12, 2009

How to Evaluate / Audit someone else's source code

Its very normal in a developer's life to be handed over someone else's source code and asked to work on it. The first thing you notice is the fact that the previous developer(s) have not put enough (or any) comments in the code. Then you realize there is no documentation left by the developer(s) regarding the code. You sit there thinking "Where do I start??"

Being faced with this dilemma yet once again I realized that the best thing to do would be to convert the code to UML diagrams so I can get an eye view of the mess.. uh, I mean the code.

I cam across a nice list of UML tools on Wikipedia where I found BOUML.



Its a free UML tool that can reverse engineer C++, Java and PHP (plus some others) code to UML diagrams.

Even if you are not a coder, you could use it to Audit the code. If the diagrams that are generated do not make sense to you, chances are that they will not make any sense to another developer either.

Of course there are many other metrics for evaluation of code quality and performance. But this is where I would start if I had no documentation at all for the code in front of me.

Monday, April 13, 2009

Joomla 1.5 has XML-RPC built-in

Working on a new site using Joomla 1.5 today under the Plugin Manager I found out that it has plugins for XML-RPC built right into its core. What does this mean?? Creating third party software to integrate with Joomla CMS is now going to be a piece of cake.



There are already a lot of 3rd party programs that support XML-RPC. An example is ScribeFire (which I am using to write this blog article). You could use any of these off the shelf tools to easily add articles to Joomla or edit/delete an existing article.

Something I am going to make in the near future is an iPhone app + a J2ME app that will use XML-RPC to easily add new articles to a Joomla site.



Monday, March 30, 2009

JSF and AJAX - Still no Good

AJAX is the way of life for web developers. If you are a Java Enterprise developer, more specifically a JSF developer, you will find loads of AJAX/JSF libraries. But if you decide to use one of them, you will not be able to use components from any of the other libraries (in most cases). In other words your application will be locked into the library you choose to use.

I found a good article today on JDJ "JavaServer Faces: The Importance of Components" by Jim Cook. The following paragraph was interesting:

AJAX fits in with the JSF framework very naturally. However, the early JSF specifications (1.0, 1.1, and 1.2) don't address AJAX. One of the consequences is that each vendor of JSF components has built its own AJAX engine and the various engines aren't always compatible. Although this issue is being addressed in the upcoming 2.0 specification, for the time being, component users are basically forced to choose components from only one vendor if they want to use AJAX.

According to this, until the 2.0 JSF specification has been implemented by all the major JSF libraries, its probably better to stay away from them if you want to prevent a lock-in. Look at it this way. If you do use one these AJAX/JSF libraries today, tomorrow when they come up with the new JSF 2.0 compatible version of their library, your application will not be able to use it.

So what can Java developers who need AJAX do today?

You can use a pure Javascript based AJAX library like Dojo or YUI along with Spring and Hibernate. At least you know that tomorrow when Dojo and YUI come out with their new versions, your application can make use of them. Yes, your application will be locked into YUI or Dojo. Life is not perfect.

Wednesday, March 18, 2009

Which Java Techs are HOT today?

I have been working recently with some SEO experts and was amazed at how they search for information on the net using various analytics and statistics tools. It made me think, why not search the net to get some REAL facts on which Java technologies are hot today. The goal is to help outsourcing companies and developers to focus more towards technologies that are in more use in the industry.

I started with regular Google Insights and Adwords Keyword Tool searches. But when Google Insights showed me that majority of these searches have been performed in India, I realized that these results signify what developers are searching for. But my goal is to find what customers are searching for.

Then it came to me. If I search Jobs websites in the markets that are best known for outsourcing IT projects, using Java specific keywords, that should give me a good idea of which technologies are more in use in those markets. I chose to search monster.com for USA and itjobswatch.co.uk for UK. Following are my findings.

  Jobs on Monster.comJobs on ITJobsWatch (avg last 3 months)

Application Server Platforms
Websphere825463
WebLogic
664303
JBoss47486

Backend GLUE Frameworks
Spring
546434
Struts527173
Seam154

Other Backend Frameworks
Hibernate
551334
EJB372143
DWR13
3

Client-side Frameworks
JSF
88245
RichFaces
7No Data
IceFaces9No Data
ADF21

Now this is by no means a very extensive list of technologies but I searched the most common ones I knew of. Technologies like JUnit, XML, Webservices etc. do not have to be researched. Everyone knows that its a must to know them just like HTML, Javascript CSS etc.

I was hoping to find something more conclusive for the client-side frameworks. I do know JSF is the choice for Java Programmers but which ONE JSF library is most widely being used??

Wednesday, February 11, 2009

Make your Java run 2X faster than C/C++ - without any coding for FREE

Looking around for Java and C/C++ comparisons I came across the Java Server runtime. I guess this has been around for a while now but just missed it for some reason. When running your Java apps, if you use the -server argument, your app runs and performs almost twice as fast as C/C++ applications of the same nature.



The server argument does take up a lot more RAM then the default client argument, but the performance boost is huge. I would not mind having all my Java apps set to run in server mode by default on newer Core2 with 4 GB machines.

The original article for C++ can be found here. The C benchmark is in Word doc format and can be downloaded here.

Monday, February 9, 2009

Market Statistics for Software Outsourcing Companies and Developers

The IT Jobs Watch website gives very detailed statistics on jobs in the UK with average salaries, No. of job postings, comparisons to last year's stats, various graphs etc. Although it does not represent the whole world, it can help outsourcing companies and developers to evaluate the current requirements in the software development market and thus develop their skill sets accordingly.

Developers confused about which new tech to get into next can search
for their own specific fields and see whats in demand in the market. Viewing the details of "Senior Java Architect", I noticed that J2EE, Spring, Hibernate, AJAX, JBoss and Eclipse have been mentioned by name in the job requirements. I am already working on a new project using Spring, Hibernate, AJAX and Eclipse so it seems I am on the right path. I might just add in JBoss to it.

Wednesday, January 21, 2009

2 Must Read articles for ALL smartphone developers

I came across 2 really awesome articles today regarding development for smartphones:
The first article covers ALL the development platforms currently available for application development for smartphones, e.g. iPhone, RIM, Symbian. The second one covers an alternative to native and interpreted applications, using Web Apps. Both are a must read.

Tuesday, January 20, 2009

Run your application on a 100+ servers simultaneously using Terracotta

Imagine running a server application which has to be used by thousands of users simultaneously. Now imagine having a database with millions of records which when accessed by even 1 single user ends up killing your server. Now imagine having both these situations together. This will be called the mother of all software implementations. But this is what servers in the field E-Government (think NADRA), Banking and pretty much all big Multi-National companies go through on a daily basis.

To deal with this problem companies invest in expensive solutions in the form Application Clustering, Server Clustering and Database Clustering where multiple servers work together to get the job done. The solution providers charge on the basis of number of servers/applications/databases being used. The cost runs into hundreds and thousands of dollars. Needless to say, this is not everyone's cup of tea.

But if your application was made using Java, you can use Terracotta to cluster your application for FREE. Taken from their site:

Terracotta is open source infrastructure software that makes it
inexpensive and easy to scale a Java application to as many computers
as needed, without the usual custom application code and databases used
to share data in a cluster.

Terracotta manages mission critical data using Network-Attached
Memory (NAM) technology. NAM enables Terracotta to cluster Java Virtual
Machines (JVMs) directly underneath applications, and is a proven
runtime approach to providing Java applications both high availability
and scalability.



Just another reason why beating Java in the Enterprise world can only be a dream for other technologies.

Monday, January 19, 2009

OpenID - One login to rule them all

Imagine logging to your GMail and then browsing to your Facebook, Hotmail, MySpace, Wordpress, personal Blog etc. without needing to login at all. We are not there yet but the OpenID technology will be getting us there hopefully by the end of 2009.

No longer will you have to remember multiple usernames/passwords. You will have the freedom to use any 1 website to actually have your 1 username/password. Other sites will merely ask that 1 site to authenticate you. Lets say you really don't want to trust the likes of Google to have your username/password. No problem, you can run your own OpenID server by just installing a simple Php script (or this) and have Facebook, Gmail, Yahoo etc. ask YOUR server for authenticating you.

Already big names like Google, Yahoo, Microsoft, IBM are on board. But they still have to integrate OpenID into their own websites.

Similar solutions like Microsoft Passport and Single Sign-On solutions from various vendors like IBM, Oracle and Sun did not pick up any momentum due to their propriety and single vendor only nature.

For web developers, you will have to allow users to register and login themselves to your sites using OpenID. Since OpenID also allows for the server to send you profile information once the user registers on your site, this will also mean that your website registration will be a 1-click action. This equates to more users for your site.


Thursday, January 15, 2009

Run your Application/Database server from a CD/DVD

If you are into selling server based software and you have had to give demos to clients, you know how difficult it is to set up the environment perfectly so you do not end up looking stupid in front of the client. Most companies have laptops specifically kept for demos so nothing is messed up at the time of a demo. DWebPro allows you to set up your whole server on a CD or DVD which can be run directly on any running Windows PC.

It supports:
  • PHP
  • Perl
  • Python
  • Ruby
  • Rebol
  • Delphi Web Script II
  • ASP 3.0
  • ASP.NET 1.1 / 2.0 and Embedded
  • JSP/Servlet
  • Zope
  • Railo (CFML Engine)
  • ColdFusion
  • EXE/CGI/ISAPI
  • MySQL
  • SQlite
  • Microsoft Access
  • HSQLDB
  • Firebird *
  • PostgreSQL **
  • Microsoft SQL Server 2000 / 2005 / Compact Edition
  • Oracle XE


If you have a binary version of your application code, you could even give a time-limited version of the demo to your client on CD/DVD.

Free Educational Software for Kids

Being a father of 3 I am always looking for good educational software for my kids to learn new things. I came across the Educational Freeware website today which has a long list of FREE educational software for kids. Games for toddlers, learning to type, Math, reading but my personal favorite Programming.

There is also Babysmash which is "a free keyboard banger game for very young kids." Use it to let your newborn beat the crap out of your keyboard and see colourful symbols appear on the screen.

I already have my kids using Linux (Edubuntu) and GCompris. My 6 year old is using the free Lego Digital Designer to create 3D models himself.

Friday, January 2, 2009

Choosing an AJAX Platform

When looking around for a good AJAX platform to use for development of a new application I am working on, I came across many platforms each with its own strengths and weaknesses. I would categorize them as follows:
  1. Coding is done using a server side XML which in turn generates Flash or XHTML files (Open Laszlo)
  2. Coding is done using server-side Javascript which in turn generates client side Javascript based AJAX interface (Jaxer)
  3. Coding done using a server-side language (Java, PHP, ASP.NET) which in turn generates client-side Javascript based AJAX interface (ZK, MS AJAX, YUI.NET)
  4. Pure client-side Javascript AJAX libraries which can further be categorized into:
    1. libraries only providing multi-browser javascripting capabilities along with basic animations (prototype, jquery)
    2. libraries providing a complete set of user-interface widgets along with multi-browser scripting and animations (Dojo, YUI, Ext)
The cons of each method in the same order are as follows:
  1. Single vendor only, capabilities limited by what has been implemented leaving very little room for customization
  2. Single vendor only, capabilities limited by what has been implemented leaving very little room for customization
  3. Client-side Javascript coding limited by what has been implemented leaving very little room for customization
  4. For client-side libraries:
    1. User-interface widgets not available; the source code will be split into 2 languages, 1 on the server-side and 1 on the client-side
    2. The source code will be split into 2 languages, 1 on the server-side and 1 on the client-side
I like the last option the best as it gives me the most opportunity for customization of the user interface and also provides the most needed widgets out of the box. Yes I will have to work with both Javascript and a server-side language but then web development has always involved knowledge of more than one language.

There is also the question of the licensing cost of the platform you choose. Although almost all of the platforms I have mentioned above are open-source, some of them may cost you if you decide to develop a commercial product (ZK and Ext).

So I came down to deciding between Dojo and YUI. Dojo has a huge community supporting it and provides a lot of opportunity for customization but unfortunately its documentation is not that complete. YUI on the other hand has loads of documentation right out of the box to get a first time AJAX developer up and running in no time.

For my current project I have chosen to go with YUI but definitely in the future I will user Dojo.