its wrking in ie but not in mozilla wats the alternate
function preventBackspace(e) {
var evt = e || window.event;
// alert(evt);
if (evt) {
var keyCode = evt.charCode || evt.keyCode;
// alert(keyCode);
if (keyCode === 8) {
if (evt.preventDefault) {...
With this code I've been able to capture the mousewheel movement and apply it to the horizontal scroll bars instead of the vertical default.
$('html').bind('mousewheel', function(event, delta) {
window.parent.scrollBy(-120 * delta, 0);
return false;
});
Is there any way that I could add this jQuery easing animation to the scroll...
Hi,
I have used curvey redraw library from google code(http://code.google.com/p/curvycorners/) & it has solved my purpose, though now as per new req i am struggling with IE. I want to have two tab rows each containing 2 tabs.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org...
I would like to start using Cassandra with a node.js deployment, but I can't find a Thrift or Cassandra client for Node.js and/or JavaScript.
Is there one?
Is there a simple means of generating Thrift connections?
Update: The short answer to this question turns out to be no, there is no JS client for Thrift that is compatible with Ca...
I have a checkbox Birthdate which shows the mm/dd only.And below it there is another checkbox called ShowYear which shows the year and this checkbox is only visible if the Bithdate checkbox is checked.
Now I want to uncheck the ShowYear checkbox automatically if the Birthdate checkbox is
unchecked through javascript.
...
i've been modified the code like below
<script type="text/javascript">
function addtext() {
var barCode = this.(text);
$("#model").change(function() {
barCode = $this.val();
var data = barCode.split("");
$("#model").val(data[0]);
$("#serial").val(data[1]);
});
};
</script>
but..still not s...
I have 11 checkboxes with individual ids inside a modal popup.I want to have a hyperlink called SelectAll,by clicking on which every checkbox got checked.I want this to be done by javascript/jquery.
Please show me how to call the function
...
What "ugliness" does the following solve? There's something I'm not getting, and I'd appreciate help understanding what it is.
For example, by augmenting Function.prototype, we can make a method available to all functions:
Function.prototype.method = function (name, func) {
this.prototype[name] = func;
return this;
};
By...
I'm reading "Javascript: The Good Parts" and am totally baffled by what's really going on here. A more detailed and/or simplified explanation would be greatly appreciated.
// BAD EXAMPLE
// Make a function that assigns event handler functions to an array of nodes the wrong way.
// When you click on a node, an alert box is supposed to ...
How to make a frameless modal popup using javascript
...
function Player() {
var score;
this.getScore = function() { return score; }
this.setScore = function(sc) { score = sc; }
}
function compare(playerA, playerB) {
return playerA.getScore() - playerB.getScore();
}
var players = [];
players['player1'] = new Player();
players['player2'] = new Player();
Array(players).sort(compare)...
Hi all
Trying an example piece of code for scriptaculous for doing some drag and drop. It works fine in IE8 but Firefox and Chrome generate an error of 'sections.each is not a function'
Here is the code:
function getGroupOrder() {
var sections = document.getElementsByClassName('section');
var alerttext = '';
sections.each(...
Hi,
I am using oscommerece. i m trying to customize this,but in product info page there is option for click to enlarge.its not working.i saw the javascript for popup .function name was popupWindow and passing variable is url.but this function has not called from the code.that is the actual problem.
Please help me what modification is ...
For a back office application which is going to be used in house and users trained to use it, does it make sense to have browser side validation. After training users will seldom make mistakes. These mistakes would get caught at the server side. Also bearing in mind that the bandwidth availability is a lesser concern I feel we should avo...
I have got the list of my friends and i can traverse through the collection to list them as per my requirement. But I want to show them in different pages as the people on myspace may have more than 100s of friends, so I dont want to show them on the same page. What would be the best way to show them in pages.
Currently i m doing the fo...
Dear all,
I have a song say about 5.1 mb ,i want to calculate total duration of song before being played on media player the file format is wave file.
...
View:
function success(arg) {
var obj = arg.get_response().get_object();
if (obj.ErrorMessage === '') {
var answer = document.createElement('div');
answer.appendChild(document.createTextNode(obj.Answer));
document.getElementById('answers').appendChild(answer);
...
How to debug javascript using firebug.
...
I need a sort of "live" effect on some checkbox - i need that every checkbox since now will be checked by a jquery function attr("checked", true) when they appear.
Is it possible to do?
...
Hi guys,
I'm having a web game loaded in orkut application via iframe so there are the orkut iframe and mine iframe inside the xml. Everything is ok, but now I need to have a button for inviting some friends and wall posts from some features. I didn't find a way for including the orkut javascript in the game's code so the first thing tha...