My DOM skills are weak and I can't work out why a javascript variable is assigned this object pointer value rather than the string value itself.
Short story is that I am making an AJAX call for some screen data and it returns html and populates a div.innerHTML with the following :
<input id="page_tag_add_input"></input>';
<span...
What is the problem here? (Besides having redundant code). $.getJSON works as expected. However $.postJSON isn't working. I can inspect $.fn via firebug and sure enough postJSON is listed. However if I try to call it, I get a no function defined error.
jQuery.fn.getJSON = function(path, opts){
this.extend(opts, {
url: path,
d...
I'm adding an event observer to one image in order to know when it is loaded, it works fine in firefox and safari, but it doesn't work in Opera.
The code is like this
$("element-id").observe("load", myFunction);
I also tried with Event.observe('load', 'element-id', myFunction) and it also works in FF and Safari, but not in opera.
Is ...
Hey :)
I have a little problem with some jquery and http://www.mikage.to/jquery/jquery%5Fhistory%5Fnoc.html
The function works great, my problem is to highlight an li class, tab menu, when user backspace with the keyboard or just use the back button on their browser to return the last seen page.
html code
li code with the class acti...
Hello everyone,
Sure it's a simple question, but I can't fix it, can somebody help me?
This is the original line
$('.winning-col', this).text($('td.win', this).length);
and this is where I came up with, surely not correct.
$('.winning-col', this).text.css('color', 'pink'($('td.win', this).length));
...
Hi
I want to return some errors to my jquery method. What is happening is I am doing a post(with a type of "json") and if they get errors I want to display the error back to them. I am doing client side validation but some of these are errors that are like server related(ie the database died or something and that update could not happen...
I need to open a text file to read the contents and then insert them into the document.
...
I am developing an app that analyzes the typing pattern of a user. To accomplish this, I need to change the HTML of the webpage that the user is on (e.g. yahoo.com) - for all the text box items in the page, add a few javascript functions to capture the key down and key up events. So, I need to be able to add a new javascript to this exis...
The following favelet in IE is causing something similar to a document.write which is displaying [object]?
I am attempting to dynamically add a frame to get javascript variables from another page to autopopulate a form. I cannot edit the source this must execute from a favorite or bookmark.
javascript:
var newFrame = document.createEl...
hi i have that works finw without Script manager. but if i add script manager that getting an erroe: sys udefined.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Block-ui-pageload.aspx.cs" Inherits="Block_ui_pageload" %>
<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyTo...
Today I stumbled on createDocumentFragment. I was wondering if the DocumementFragment is supported, and how, on the different browsers, expecially IE series.
Anyone knows anything about this subject?
...
How can I (if at all) load a new page when an html's selector changes if javascript is disabled in the browser.
Can it be done?
...
What is a good way for handling parameters in localized strings in javascript?
I am using the same format as in java's MessageFormat class, e.g.:
There are {0} apples in basket ID {1}.
Where {0} will be replaced with the first parameter and {1} with the second.
This is the call I want to use in JS (i.e. I want to implement origStr):
...
I need to get textbox that exits in Formview inserttemplate via javascript.
Both return null:
$get('txtTitle');
document.getElementById("txtTitle");
The problem is that formview is not rendered on form load...
...
I figured out how to create a bookmarklet for Google Analytics that opened to immediately show only today's stats. I wanted to make a Google Chrome application shortcut for this to go along side my other Google Apps shortcuts, but the first problem is that it only creates an application with the current url, which displays today's info ...
i have a simple array and i want to generate string which include all the elements of the array, for example:
The array is set as follow:
array[0] = uri0
array[1] = uri1
array[2] = uri2
And the output string must be
teststring = uri0,uri1,uri2
I've tried to make this following way (using for loop):
var teststring = "";
teststrin...
Hi
I've developed a plugin that makes characters jump and bounce when moused over in any element that contains text.
Here is an example.
It works great in Firefox 3.5, Chrome, Safari 3.1 and IE7 (oddly, but in compatibility mode) but in IE8 it seems the characters disappear as they rise. I've added top padding to the p element, becaus...
i used this line of code but it didn't work
$("a#link").attr("href",$(this).attr('tempref').val());
...
I want to get notified about all the events happening in a webpage.
For each single event I am using something like this:
if(document.addEventListener){
document.addEventListener('click', function(e) { something(e) } , true);
}else{
if(document.attachEvent){
document.attachEvent('onclick', function(e) { something(e) });
...
I am looking for a Javascript project which makes use of canvas to allow the creation of diagrams/flowcharts in the browser.
Are there any active projects like that alive?
...