Showing posts with label Programming. Show all posts
Showing posts with label Programming. Show all posts

Sunday, 28 August 2011

Open Source Programming VS Closed Source Programming

Open source is a general software license that has revolutionized the software development industry. Before open source software development was limited to the combined effort of a few corporate-hired software engineers working in small groups. The open source movement has changed the way the software is developed. Open source uses broad community-based development techniques that replace a small group of profesional programmers with a large base of experienced individuals. While most large corporations are reluctant to give up the proprietary business model, some have started to realize the benefits of open source in the development of their software. In fact, free open source software, when coupled with service and support, can be profitable for major corporations. This website contains valuable information regarding the open source movement’s advantages, disadvantages, and its repercussions on the global software market.

Open source and proprietary developers have been in a heated battle over market share.
But with billions of dollars in the corporate pocket, are the open sourcers fighting an uphill battle?

Open Source Programming

Software companies from across the world have embraced the open source business model. From flavors of Linux to enterprise-class web server software, an increasing number of software companies are opening their source code to developers. Examples of this practice can be found almost everywhere. File sharing programs like Limewire have an open source model which pays private programmers to update small parts of the program. Sourceforge.net, arguably the largest online open source community, has pioneered the collaboration of open source projects. To date, they have nearly 1.25 million users and over 100 thousand projects. Sun Microsystems, a publicly traded corporation, has begun to make source for popular software like Solaris and Java open. These movements towards open source represent the general trend in the software industry.

Open source software has filled a void left by the proprietary giants. Utilities that would normally be overlooked by major corporations are being developed by individuals and shared around the world. These small programs can prove useful for both private end users and small businesses. The future of software development depends on peoples ability to openly share source amoung developers and to effectivly deliver final products to end users.

Fedora Core 4, an open source opperating system, is shown here in full swing.

Check out these links for good open source software!
Sourceforge.net
Opensource.org
mySQL.com
Red Hat Linux
Sun Microsystems

Closed Source Programming

Proprietary software, unlike open source software, is a pay-to-use service. Propriety software is developed by a small number of professionals working in a corporate think tank. These companies, to protect their intellectual property, provide the end user with only the binary code of a program (the part that only a computer can read). Because these companies make money by selling their programs, rather than their support packages, the source code proves invaluable.

Although the general trend of software development companies is to go open source, the biggest companies have resisted the temptation of open source. Microsoft, the infamous software giant, has been a leader in the proprietary software business model since the dawn of the computer age. Apple, the company holding the second largest share of the market, is also strictly proprietary. Apple even manufactures proprietary hardware, specific to Apple software. The fact that the two largest companies in the software industry have resisted opening their source code shows that proprietary software is still alive and profitable.

Apple computers have always dominated the multi-media market and are a strong force for proprietary software

Check out the following links to proprietary software companies:

Advantages And Disadvantages

Migration. It is difficult for end-users and development companies to drop their proprietary software to move to an open source model. Immature. Open source software has inexperienced developers as compared to professional developers of proprietary software companies. Hard to Deploy. Most open source software solutions don’t have GUI, making it nearly impossible for many end users to install the software.
Lacking support. Since there is no monetary incentive, open source projects can lose steam over time while proprietary software is continually improved.

Sunday, 14 August 2011

Best Introduction to PHP And Also Using PHP.


PHP (the acronym is "recursive" and refers back to itself--it stands for PHP: Hypertext Preprocessor) is a popular server-side scripting language. The fact that it is "server-side" means that special software on the web server is used each time a page with PHP is processed. This software responds to specific commands included within (embedded) in the webpage. Generally, these commands tell it to generate new HTML code which is sent back to the user's web browser. Thus, especially when it is connected to a database on a web server, PHP can be used to generate dynamic web content. There are other uses for PHP that do not involve the internet, but this use of PHP is the most common one today. (Coggeshall)


Like some other technologies, PHP is not tied to a specific software vendor, meaning it is relatively compatible with other technologies and databases. This, and the fact that PHP requires relatively simple software to write and run, makes it a popular choice among programmers, who are seeking something more interactive and dynamic than JavaScript, but not as complex or tied to a single company as ASP.NET. Though there is no formal technical specification for PHP, it is maintained de facto by The PHP Group. (PHP: Introduction)


Examples: Like ASP.NET, PHP is broadly used, especially by small and moderately sized websites. Indeed, the original meaning of PHP was Personal Home Page tools, as it was originally built for the maintenance of the personal website of its creator, Rasmus Lerdorf. PHP is also particularly prevalent in online web discussion boards. All PHP pages end in .php rather than .html or .aspx.



Using PHP


PHP requires software to run, whether it’s on the web server or on your computer. A good guide to installing this software (if you’re installing it on your computer, you’ll be installing a server as well) can be found from Christopher Heng.

PHP can be written in a simple text editor, as it is embedded in the HTML. As with JavaScript, we’ll give a brief example of how to create a sample page, one that offers a welcome message to the viewer. Within the body of a normal HTML page, you can write a PHP tag like this one:

<?php echo '<p>Hello Visitor!</p>'; ?>

If the PHP software is installed on your server correctly and if you saved the page with a file extension of .php and not .html, it will convert this tag to proper HTML for display in the browser, which ultimately renders it as “Hello Visitor!” Of course, you could have performed this task anyway, just using HTML. PHP’s true value lies in its more advanced functionality, which can be used to create interactivity. PHP, like ASP.NET, is often combined with databases. PHP can be used to communicate with a database, gather input or data from a user, and create an interactive experience from that. Of course, acquiring the knowledge to do this takes some practice and study, but PHP is a popular technology for this sort of interaction. Should you want to pursue PHP, we’ve provided a few resources below.

Note that PHP is a server-side technology. If you want .php files to work as designed on a web server, PHP must be installed on that server. Keep this in mind when you choose a web host for your website. Many hosts, but certainly not all, support PHP. Most will clearly state whether or not they support PHP.

The Best Introduction to Databases And Using it.


Database

Concept

The principle of interactivity is clearly seen in databases and their use online. The idea of a database is simple: where plain websites are entirely static (they display the same content every time you look at them, unless the have been manually updated), data-driven websites is one of the things that makes a website dynamic, with new, fresh, content. Essentially, what displays on the page is determined in some part by what's in the database. (Greenspan)
You might be familiar with how a basic webpage works. HTML code that is already written is sent to your browser. Your browser translates this code into a webpage which you can see. With a webpage that uses a database, all or some of the HTML is generated by the data in database, adding an extra step to the process, but meaning that you'll see new data fresh from the database. When the maintainer of the website wants to update a page, he or she manually or automatically (usually the latter) changes the data in the database. The next time you view the page, you'll interact with new data.
How is this interactivity, you might ask. Simple: the website provides you with fresh data from the database, and gives you the opportunity to change the database in most cases (such as when you rank an article or video). Rather than just presenting one, stale page of HTML, it presents a fresh page of generated HTML that represents real-time data. When you perform an action, the data will often update, and, the information displayed. (Chappel)

Examples

Most moderately complex websites use some form of a database. A simple example is an e-commerce site. If you view an item for sale on an e-commerce site, the website will check to make sure the item is in stock before the present a "Checkout" button. If the item isn't in stock, it won't let you buy it, but will rather display a message informing you of this. Notice how sites like Amazon.com and Newegg.com do this the next time your purchase something. Also, most user interactivity connects back to a database at some point. All of those comments and stories from users on Digg, tags on a Flickr photo, or articles on Wikipedia are stored in a database of some sort. 

Using Databases


There are many types of databases. In this getting started guide, we’ll outline what you need to set up a popular free database so that other technologies (such as ASP.NET or PHP) can interact with it.
A popular free choice for webmasters is a type of database called MySQL. You can download the free version of MySQL here. It runs on both Windows and Linux. We also recommend that you download a reference manual here. Once you have the database downloaded and installed, you need to configure your web technology to link it to your website (for example, using ASP.NET or PHP). This is typically done with something known as a “connection string.” Essentially, this is a piece of data that specifies where your database is, what data you wish to access, and what username and password, if any, you are using. Connection strings vary greatly from database to database, but mostly only in syntax—the above concepts are universal across databases and technologies. For more on virtually every type of connection string, see an excellent free resourcehere.
As with ASP.NET or PHP, databases are generally server-side, meaning that they run on your web server. If you want your database to be part of a website visible to the world (as opposed to just an experimental site on your computer), you’ll need to set your database up with your web host. The procedure varies from host to host, but generally you’ll need to upload or configure some files and change your connection string to reflect the new location of your database.
It is also worth covering how data is stored in a database, and what technologies are often used to retrieve it. Almost all data is stored in tables, with columns, called “fields,” and rows, called “records.” A sample table might be named “People” with fields of “First_Name,” “Last_Name,” and “Date_of_Birth.” Each record in this table would have data for all three fields (though some fields can be set to be left blank in some cases, if necessary). Many records can exist in one table, all with the same fields.
To query, or retrieve, this data, a language called SQL (for Structured Query Language) is often used. There are many variants on SQL and it varies slightly database by database. A basic SQL statement though, might look something like this:
SELECT * FROM PEOPLE_TABLE WHERE FIRST_NAME = “JOHN”
As you might know, the * character means all, so this statement selects all of the records—each one represents a different person—from the table with all the people listed and shows or returns the record if the person’s first name is John. This is a very basic SQL query; they are usually much more complex, but you can get the general idea from this.

Introduction To Javascript And The simplest way to use it.


Javascript



The Introduction Part


JavaScript is a client-side scripting language that many webmasters find quite useful. Essentially, JavaScript performs simple actions within the viewer's web browser. This is advantageous because it means that the viewer doesn't need to wait for the website to communicate with the server again.
JavaScript was designed to be similar to many other programming languages (for example, its syntax is quite like the C programming language). It is streamlined, with simple naming conventions, and is designed to be easy to learn. Many web designers learn JavaScript not long after becoming familiar with the basics of static web content such as HTML and CSS. (Andreessen)
Conceptually, JavaScript is similar to AJAX in that in runs within the web browser to perform simple tasks. There are numerous uses for this sort of technology; even though it won't provide the fully dynamic feel that a data-driven website will--JavaScript doesn't interact with much data on the server. Effective use of JavaScript can make your website more intuitive, and can provide your users with a more productive experience. (Web Programming)
Examples: JavaScript, in some form, is used in many websites today. Common examples include user data validation, pop-up windows, and increased responsiveness to user actions. The first is common when the user is expected to enter data; for example, if a website asks for a telephone number and an email address, but the user enters data that does not meet the specific format of telephone numbers (xxx-xxx-xxxx) or email addresses (x@y.z), JavaScript can be used to stop the submission of that data and prompt the user to correct their error. Since many forms of interactivity rely on users submitting data or comments, this form of verification is useful. So, too, is JavaScript used to create pop-up windows and boxes that ask the users to confirm their actions--this can prevent users from taking significant actions, like ordering a product online, inadvertently. As a final example, JavaScript is also used to highlight things for the user; some sites will change the background of a textbox in which the user is currently typing or the link over which the user is currently hovering his or her mouse cursor to highlight such facts to the user. Such highlighting can make submitting data and navigating a website easier.

Using it...

Getting started with JavaScript is quite easy. JavaScript is a client-side technology, which means that there’s no new software installed on the web server for it. JavaScript is part of the actual webpage itself, next to the HTML code. It has a special tag of its own, called the <script> tag. JavaScript code is contained within these tags in the header—a special section—of the HTML page.
JavaScript is also relatively easy to learn and is similar to languages such as Java, C, and C#. To get started with JavaScript, create a basic HTML page, and in the header, add a <script> tag. For example, you could write the following between the <head> tags:
<script language="JavaScript">
alert("Welcome to my page.");
</script>
This would create an alert box that pops up when the visitors views the page and displays a welcome message. Click here to visit this page with the above alert added using Javascript. This feature is one of the most basic in JavaScript.
JavaScript is best used tastefully and sparingly. Most users don’t want to be bombarded with messages each time they click a link—so don’t bombard them! Most users, however, do want to be informed when they’ve submitted invalid data into a form, so it’s certainly appropriate to inform them, often using JavaScript, of such.
There are excellent free resources for JavaScript all over the web. We encourage you to explore it, both for its own merits and as a gateway to more complex, but similar, technologies. The three resources below are excellent overviews for beginners.