If you’re finding that your Firefox browser is not caching any images (css/javascripts) and loading them multiple times on the same page, check the following cache settings of Firefox by typing in about:config in the browser’s address bar.
Both browser.cache.disk.enable and browser.cache.memory.enable values should be set to true in order to enable browser caching [...]
a {
word-wrap: break-word;
}
Works for a long text too:
p {
word-wrap: break-word;
}
Tested in IE6, IE7, Firefox, Safari, Chrome
20 Feb, 2009
Posted by: eisabai In: Snippets
By default, jQuery thickbox plugin displays a thickbox overlay window when you click on a link which class is set to thickbox. The following code lets you display thickbox on page load without hacking anything in thickbox code.
<script type="text/javascript">
$(document).ready(function(){
tb_show(“Announcement”,”announcement.html?height=300&width=300″, “”);
});
</script>
Recommended Books on jQuery
jQuery Cookbook: Solutions & Examples for jQuery Developers
jQuery in Action
HTML code:
<form action="login.php" method="post" id="login">
<fieldset>
<legend>Login</legend>
<label for="username" class="label">Username</label>
<input type="text" name="username" id="username" class="text" maxlength="30" />
<label for="password" class="label">Password</label>
<input type="password" name="password" id="password" class="text" maxlength="30" />
<input type="checkbox" name="remember" id="remember" />
<label for="remember">Remember me</label>
<input type="submit" name="submit" value="Login" />
</fieldset>
</form>
Javascript code:
The first javacript snippet will be used to store username and password into cookie if ‘Remember me’ checkbox is ticked.
The second javacript [...]
19 Feb, 2009
Posted by: eisabai In: Tutorials
Code:
<!–[if IE 6]>
Internet Explorer 6
<![endif]–>
<!–[if IE 7]>
Internet Explorer 7
<![endif]–>
<!–[if lt IE 7]>
A version of Internet Explorer which is older than 7
<![endif]–>
<!–[if gt IE 6]>
A version of Internet Explorer which is newer than 6
<![endif]–>
<!–[if gte IE 7]>
A version of Internet Explorer which is 7 and above (IE 7, IE 8, etc)
<![endif]–>
Usage:
These comments can be put inside [...]