The language that will light up your Web

Java turns pages into all-singing, all-dancing events. Charles Arthur on the program that gives the Net a mind

If you have been surfing around new Web sites recently, you will probably have noticed a new word: Java. About 100,000 pages contain it right now. And they may be the key to making the Web a truly interesting, useful place. Why? If you use an older browser, you may have seen this note: "If you were using a Java-enabled browser, you would see an animated ...", followed by a text description of what you're missing: dancing coffee cups, stock market prices, flags waving in an electronic breeze (at the White House site), spinning globes. You name it, someone's beavering away at animating it, or turning it into a sound file.

If you are using Netscape 2.0, you won't have to read the words - you can see the pictures or hear the sounds for yourself, always assuming you have the patience for them to be downloaded over your data link. Even quite small animations can require 50 kilobytes of data, which - given the sluggishness of many links - can mean a minute's thumb-twiddling.

But to have reached 100,000 sites is not bad for a product that was released only last summer. Its widespread success resembles that of Netscape, in that its creator, Sun Microsystems, has been distributing it for free over the Internet, letting word of mouth (or e-mail) do much of the job of publicity.

Unlike Netscape's browser, which is a program, Java is a programming language, developed in 1990 by James Gosling, a programmer at Sun Microsystems. Originally called "Oak", it was intended to be used in domestic products such as toasters, videos and car alarms. In a world where toasters, like microwave ovens, have inbuilt software (and that's not far off), you could send a Java program down the telephone line to upgrade your toaster. Gosling never lost sight of the idea that Java should be bug-proof and easy to develop but hard to tamper with. So the toaster would not catch fire because of an error in transmission or a bug.

But before that became reality, the World Wide Web happened. The trouble with the Web to date has been that while you could have titles that blinked (which were annoying to the eyes) and you could download motion or sound files to play in your own time, the actual pages themselves were dull. As George Gilder, a writer and futurist, puts it: "Content today is dead, static." But with Java, he says, "content wins".

The reason is that Web pages come to life when your browser connects to a Java-enabled site. Part of the page's contents, besides the usual HTML text, will be a small program, called an "applet", written in Java. This is sent to your computer, where it runs: dancing, singing coffee cups and so on.

You don't even have to specify what operating system (Mac, DOS, Sun) you are using: the browser picks up the code and transfers it over to your Java-enabled browser, which reads and interprets it and follows its instructions. If your browser can't handle Java, nothing happens: it simply ignores the Java instructions.

Is the applet not like a virus? How do you know it does not have an instruction such as "Wipe clean the hard disk" in it?

Mr Gosling and his associates at Sun thought of that. The applet runs inside a "virtual machine" on your computer: in essence, it ropes off an area of electronic memory (RAM) and allows the applet to create and change data only there. The applet is not allowed to access the machine's peripherals but instead passes its data back to your browser, which then passes them to the screen or disc. (Though someone did discover a way to get the applet to bypass the browser earlier this year - a flaw that was quickly fixed by Sun.)

However, the applet's resemblance to a virus means that occasionally "firewalls" - machines installed to prevent viruses and hackers getting into a private network from the Internet - won't let them past. This problem is gradually being tackled.

If you are in an excitable mood, like Danny Hillis, adjunct professor of the Massachusetts Institute of Technology, you will agree that, "Java allows the network to have a `mind'. This is revolutionary. Communication takes place between computers that is meaningful to them."

Eric Schmidt, Sun's chief technology officer, believes that Java has a key similarity to an earlier, and fantastically successful, bit of software. "Java is going to be the DOS of the 1990s," he says. "It may not be perfect but neither was DOS at first. Its chief benefit is its ubiquity. It has shortcomings, but it's everywhere."

And, who knows, in time you might be able to download cool Java programs from the Net to upgrade your toaster or microwave.

For more information about Java, including a (rather technical) introduction, visit http://www.javasoft.com/. To get a browser capable of running Java programs, try Netscape 2.0, available at http://home.netscape.com/.

A huge list of Java applets, with reviews, can be found via http://www.jars.com/

News
peopleHowards' Way actress, and former mistress of Jeffrey Archer, was 60
Sport
Chelsea are interested in loaning out Romelu Lukaku to Everton again next season
sport
News
Robyn Lawley
people
Life and Style
Troy Baker and Ashley Johnson voice the show’s heroes
gamingOnce stilted and melodramatic, Hollywood is giving acting in video games a makeover
PROMOTED VIDEO
Have you tried new the Independent Digital Edition apps?
Life and Style
ebookA wonderful selection of salads, starters and mains featuring venison, grouse and other game
News
people
News
i100
Life and Style
Phones will be able to monitor your health, from blood pressure to heart rate, and even book a doctor’s appointment for you
techCould our smartphones soon be diagnosing diseases via Health Kit and Google Fit?
News
people
Extras
indybest
Sport
Usain Bolt confirms he will run in both the heats and the finals of the men's relay at the Commonwealth Games
commonwealth games
Life and Style
tech'World's first man-made leaves' could use photosynthesis to help astronauts breathe
Independent
Travel Shop
the manor
Up to 70% off luxury travel
on city breaks Find out more
santorini
Up to 70% off luxury travel
on chic beach resorts Find out more
sardina foodie
Up to 70% off luxury travel
on country retreats Find out more
Latest stories from i100
Have you tried new the Independent Digital Edition apps?
Independent Dating
and  

By clicking 'Search' you
are agreeing to our
Terms of Use.

ES Rentals

    iJobs Job Widget
    iJobs General

    SAP Project Manager

    competitive: Progressive Recruitment: SAP PROJECT MANAGER - 3 MONTHS - BERKSHI...

    SAP Project Manager

    competitive: Progressive Recruitment: SAP PROJECT MANAGER - 3 MONTHS - BERKSHI...

    Senior Investment Accounting Change Manager

    £600 - £700 per day + competitive: Orgtel: Senior Investment Accounting Change...

    Microsoft Dynamics AX Functional Consultant

    £65000 - £75000 per annum + benefits: Progressive Recruitment: A rare opportun...

    Day In a Page

    Save the tiger: The day America’s love of backyard tigers led to a horrific bloodbath

    The day America’s love of backyard tigers led to a horrific bloodbath

    With only six per cent of the US population of these amazing big cats held in zoos, the Zanesville incident in 2011 was inevitable
    Samuel Beckett's biographer reveals secrets of the writer's time as a French Resistance spy

    How Samuel Beckett became a French Resistance spy

    As this year's Samuel Beckett festival opens in Enniskillen, James Knowlson, recalls how the Irish writer risked his life for liberty and narrowly escaped capture by the Gestapo
    Once stilted and melodramatic, Hollywood is giving acting in video games a makeover

    Acting in video games gets a makeover

    David Crookes meets two of the genre's most popular voices
    Could our smartphones soon be diagnosing diseases via Health Kit and Google Fit?

    Could smartphones soon be diagnosing diseases?

    Health Kit and Google Fit have been described as "the beginning of a health revolution"
    Ryanair has turned on the 'charm offensive' but can we learn to love the cut-price carrier again?

    Can we learn to love Ryanair again?

    Four recent travellers give their verdicts on the carrier's improved customer service
    10 best over-ear headphones

    Aural pleasure: 10 best over-ear headphones

    Listen to your favourite tracks with this selection, offering everything from lambskin earmuffs to stainless steel
    UCI Mountain Bike World Cup 2014: Downhill all the way to the top for the Atherton siblings

    UCI Mountain Bike World Cup

    Downhill all the way to the top for the Atherton siblings
    Save the tiger: The animals bred for bones on China’s tiger farms

    The animals bred for bones on China’s tiger farms

    The big cats kept in captivity to perform for paying audiences and then, when dead, their bodies used to fortify wine
    A former custard factory, a Midlands bog and a Leeds cemetery all included in top 50 hidden spots in the UK

    A former custard factory, a Midlands bog and a Leeds cemetery

    Introducing the top 50 hidden spots in Britain
    Ebola epidemic: Plagued by fear

    Ebola epidemic: Plagued by fear

    How a disease that has claimed fewer than 2,000 victims in its history has earned a place in the darkest corner of the public's imagination
    Chris Pratt: From 'Parks and Recreation' to 'Guardians of the Galaxy'

    From 'Parks and Recreation' to 'Guardians of the Galaxy'

    He was homeless in Hawaii when he got his big break. Now the comic actor Chris Pratt is Hollywood's new favourite action star
    How live cinema screenings can boost arts audiences

    How live cinema screenings can boost arts audiences

    Broadcasting plays and exhibitions to cinemas is a sure-fire box office smash
    Shipping container hotels: Pop-up hotels filling a niche

    Pop-up hotels filling a niche

    Spending the night in a shipping container doesn't sound appealing, but these mobile crash pads are popping up at the summer's biggest events
    Native American headdresses are not fashion accessories

    Feather dust-up

    A Canadian festival has banned Native American headwear. Haven't we been here before?
    Boris Johnson's war on diesel

    Boris Johnson's war on diesel

    11m cars here run on diesel. It's seen as a greener alternative to unleaded petrol. So why is London's mayor on a crusade against the black pump?