Archive
HTTP REDIRECT
PHP Redirect
<?php
header("Location: http://www.example.com/"); /* Redirect browser */
/* Make sure that code below does not get executed when we redirect. */
exit;
?><script type="text/javascript"> <!-- window.location = "http://www.arunrajr.com/" //--> </script>
Toggle visibility between none and inline
function toggle_it(itemID){
// Toggle visibility between none and inline
if ((document.getElementById(itemID).style.display == ‘none’))
{
document.getElementById(itemID).style.display = ‘inline’;
} else {
document.getElementById(itemID).style.display = ‘none’;
}
}
JavaScript Frame work
A powerful javascript frame work.
ProtoType.Js
Prototype is a JavaScript Framework that aims to ease development of dynamic web applications.
Featuring a unique, easy-to-use toolkit for class-driven development and the nicest Ajax library around, Prototype is quickly becoming the codebase of choice for web application developers everywhere.
Light Weighted javascript Libraries
This website provides Ultra lightweight JavaScript libraries . That helps JavaScript developers
http://orangoo.com/labs/Main/
main OpenSource pojects are:
- GoogieSpell is a spell checker that you can use in your own web-application.
- GreyBox can be used to display websites, images and other content in a beautiful way.
- AJS is a ultra lightweight JavaScript library that is around 2 years old. It is inspired by MochiKit, but differs by being small and expressive. The current version is only 33 KB (uncompressed!), whereas MochiKit and other libraries such as JQuery, Mootools or Prototype is over/around 100 KB.
JAVA SCRIPT PAGE REFRESH
<a href=”#” onclick=”javascript:window.location.reload();”><strong>refresh</strong></a>
Javascript Back button
<a href="#" onclick="history.go(-1)">back</a>
Input Field accepting only numbers using javascript
<input name=”demo” type=”text” id=”demo” onkeypress=”var unicode=event.keyCode? event.keyCode : event.charCode;if ((unicode < 32 || unicode > 33)&&(unicode < 45 || unicode > 57)) return false; return true;”>
This code compatible to all browsers !