Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Client -server side Javascripts

 
Angela Jessi
Ranch Hand
Posts: 428
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
What is difference between client & server side javascript?
Can server side javascript open URL or Socket of any server,open any file from server,get the values from file,close the file and store the value of the server file into array of server script.
if this possible, can client-side script display the updated value from serverside array value(which is value from server)?
Thanks
Angela
 
seems_josh
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello
in client side scripting you can use validation which you will be able to run on browser, but in server side scripting you have to pass a request and accordingly the server side scripting will
perform the request
eg if the username is incorrect than the server side scripting message will be display that username is not valid
while in clientside if you miss to type passward than alert message will be display that you are requested to write passward
seema
 
Ray Hunter
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Angela Jessi:
I think the best way for explaining this is by visiting netscapes development pages and review the javaScript API's for both client and server.
Client-side JavaScript is used many ways in browsers; whereas, Server-side JavaScript "you can create dynamic HTML pages that process user input and maintain persistent data using special objects, files, and relational databases. Through Java LiveConnect functionality, you can let Java and JavaScript code communicate with each other. From JavaScript, you can instantiate Java objects and access their public methods and fields. From Java, you can access JavaScript objects, properties, and methods."
-above quote from JavaScript Documentation http://developer.netscape.com/docs/manuals/index.html
Check out the above url, it has tons of information.
~Ray
 
Frank Carver
Sheriff
Posts: 6920
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And just to add extra fun to the mix, the Resin web server and servlet container (free, good, and available from http://www.caucho.com/ ) lets you use JavaScript as the language to write JSPs in . It's server side JavaScript, but not as we know it ...
 
Angela Jessi
Ranch Hand
Posts: 428
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ray,Frank,seems_josh
Thanks a lot for your responses.
I have a question:
Is it possible to access Java application(Not applet) in Javascript? If yes, how?
Please let me know,
Thanks
Angela
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic