Welcome!

Machine Learning Authors: Yeshim Deniz, Zakia Bouachraoui, Pat Romanski, Elizabeth White, Liz McMillan

Related Topics: Machine Learning

Machine Learning : Article

JavaScript Powers Up the Server Side

Be the envy of your Java, .NET, PHP, Perl, Python, and Ruby peers

Aptana Jaxer is a new open source application server built especially for AJAX application development in JavaScript. To say that "Jaxer lets you do JavaScript on the server-side" would be accurate, but an understatement. The core concept of Jaxer is that it provides a parity of environments at the client and the server to simplify the creation of rich AJAX pages, apps, and gadgets - and by so doing, gives the Web developer a unified runtime at both the client and server tiers.

How does Jaxer achieve this parity of environments? The main engine in Jaxer is the Mozilla engine - the same Mozilla engine you find in the Firefox Web browser. This means that besides JavaScript on the server, you also have the full spectrum of AJAX technologies available to you including DOM manipulations, CSS, and XHR plus other goodies that Mozilla implements like native XML support for JavaScript (E4X).

All of Jaxer's APIs are implemented in JavaScript and accessed via the Jaxer object. Using Jaxer, JavaScript developers can do all kinds of server-side coding that would have been the envy of their Java, .NET, PHP, Perl, Python, or Ruby peers. Jaxer.Session, for example, can create and manage user sessions; Jaxer.DB facilitates SQL database access; Jaxer.File lets you read/write files, and Jaxer.web lets you communicate across network sockets.

However, some of the most unique capabilities of Jaxer include the server-side manipulation of the HTML DOM and the ability to use AJAX libraries of your choice on the server side as well. Let's take a look at a simple example that puts these principles to work - in this case a simple survey application.

Building a Simple Voting Application
Let's vote...

In this example, we're going to build a simple voting tool using a single page of DHTML. The implementation is quite basic but covers a few good examples of how to use many of Aptana Jaxer's capabilities including:

  • Executing JavaScript on the server
  • Using AJAX libraries on the sever (jQuery in this example)
  • Creating and accessing a database
  • Server-side DOM manipulation
  • Storing and retrieving session data
  • E4X (native XML support for ECMAScript) as a templating mechanism
  • Handling form data

More Stories By Kevin Hakman

Kevin Hakman is Director of Evangelism for Aptana, Inc., makers of the popular Aptana Studio web development suite. As early as 2001 Kevin was pioneering AJAX web applications via General Interface, a full AJAX development and GUI toolkit which he co-founded, and later sold to TIBCO Software in 2004. Kevin is a contributor to AJAXWorld Magazine, and has spoken at numerous AJAX industry events.

More Stories By Davey Waterson

Davey Waterson is a JavaScript architect at Aptana. He started out with Cobol coded on punch cards running on a Burroughs B1700 through to a DHTML Web UI using xhtmlRequest and Async Java. Davey has more than 20 years or experience as a code junky technophile and has worked in the industry in both Europe and North America.

Comments (0)

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


CloudEXPO Stories
Headquartered in Plainsboro, NJ, Synametrics Technologies has provided IT professionals and computer systems developers since 1997. Based on the success of their initial product offerings (WinSQL and DeltaCopy), the company continues to create and hone innovative products that help its customers get more from their computer applications, databases and infrastructure. To date, over one million users around the world have chosen Synametrics solutions to help power their accelerated business or personal computing needs.
All in Mobile is a place where we continually maximize their impact by fostering understanding, empathy, insights, creativity and joy. They believe that a truly useful and desirable mobile app doesn't need the brightest idea or the most advanced technology. A great product begins with understanding people. It's easy to think that customers will love your app, but can you justify it? They make sure your final app is something that users truly want and need. The only way to do this is by researching target group and involving users in the designing process.
Digital Transformation and Disruption, Amazon Style - What You Can Learn. Chris Kocher is a co-founder of Grey Heron, a management and strategic marketing consulting firm. He has 25+ years in both strategic and hands-on operating experience helping executives and investors build revenues and shareholder value. He has consulted with over 130 companies on innovating with new business models, product strategies and monetization. Chris has held management positions at HP and Symantec in addition to advisory roles at startups. He has worked extensively on monetization, SAAS, IoT, ecosystems, partnerships and accelerating growth in new business initiatives.
Dynatrace is an application performance management software company with products for the information technology departments and digital business owners of medium and large businesses. Building the Future of Monitoring with Artificial Intelligence. Today we can collect lots and lots of performance data. We build beautiful dashboards and even have fancy query languages to access and transform the data. Still performance data is a secret language only a couple of people understand. The more business becomes digital the more stakeholders are interested in this data including how it relates to business. Some of these people have never used a monitoring tool before. They have a question on their mind like "How is my application doing" but no idea how to get a proper answer.
DXWorldEXPO LLC announced today that Big Data Federation to Exhibit at the 22nd International CloudEXPO, colocated with DevOpsSUMMIT and DXWorldEXPO, November 12-13, 2018 in New York City. Big Data Federation, Inc. develops and applies artificial intelligence to predict financial and economic events that matter. The company uncovers patterns and precise drivers of performance and outcomes with the aid of machine-learning algorithms, big data, and fundamental analysis. Their products are deployed by some of the world's largest financial institutions. The company develops and applies innovative machine-learning technologies to big data to predict financial, economic, and world events. The team is a group of passionate technologists, mathematicians, data scientists and programmers in Silicon Valley with over 100 patents to their names. Big Data Federation was incorporated in 2015 and is ...