Jump to content
xisto Community
Sign in to follow this  
hyuken

Javascript Framework - A Shortcut Javascript a shortcut javascript

Recommended Posts

hi, today im going to give you small tutorial how to use `Prototype JavaScript Framework`

1st you have to download `Prototype JavaScript Framework`library from http://forums.xisto.com/no_longer_exists/

prototype makes easy to using Javascript, ex :

when you want to point (get) the element from HTML usually we use :


document.getElementById('elementId')


with prototype we use
$('elementId')
, yeah...world getting small..with prototype.

example we`re going to get value from an element of

<input type='text' id='txt1' name='myFriend'>

with prototype we use
alert($('txt1').value)
:rolleyes::lol:;)

when you want to fill element with text :

<span id='txt1'></span>$('txt1').innerHTML = "the fox is running fastly";

OK this is little sample, we going step by step..

CU..for my next tutorial..

Share this post


Link to post
Share on other sites

How do you integrate this library ? Since, Javascript is executed on Client Side. :-)


This library is only a Javascript file, you could write it as usually, ex :

<script language="JavaScript" src="prototype.js"></script>

just download the library from URL above. the library is POWERFULL.

Share this post


Link to post
Share on other sites

Cool dude. This reduces lots of lines of codes and simplifies coding. Pleas also give more examples and explain how to implement them properly in our site.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.