Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Perl vs. Javascript

by Chady (Priest)
on Mar 07, 2001 at 12:12 UTC ( #62690=note: print w/replies, xml ) Need Help??


in reply to Perl vs. Javascript

I have been into that matter for some time; not being able to decide what type of language to use for a specific task.

But since you are working on the web and processing forms, you're down with two solutions; Perl and JavaScript.

Here are some of the diffrences :

    JavaScript

    • This is Client-Side scripting, so you will be depending on the user's browser to support or not your scripts.
    • In order to access specific objects (form fields values, or list values) you will need to setup a way to access them supporting all the browsers ex: Netscape calls the form diffrently than IE, and another diffrent one is NS6 (and that's only two types of browsers)
    • Processing texts of forms is a little hard to do right with JavaScript
    • I'm sure you will find more...

    Perl

    • This is Server-Side scripting, so all your scripts will run whatever browser asks them to.
    • In order to access specific objects, you just use CGI.pm and you have an object with all the values you need in it.
    • Processing text is as simple as "writing the right RexEx" in Perl.

Finally, If you have a lot of text to process, and you need to do it quickly and efficiently, go for Perl, it's faster(in programming) and more reliable.

If you only need to 'get the contents of a field and put it in another' you can make it in JavaScript.

I hope this information helps you decide

Chady | http://chady.net/

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://62690]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2021-07-27 10:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?