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/
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.