On load, I add a desired behavior on all textareas on a page.
Event.observe(window, 'load', function() {
$$('textarea').each(function(x) {
x.observe('keydown', dosomethinghere)
});
});
This works because the textareas are already in the DOM, but how should I treat textareas that are dynamically added after the page loads (ex: ...
This code is not working, what im doing wrong?
Tnks.
var x;
x=jQuery(document);
x.ready(inicializarEventos);
function inicializarEventos()
{
var x;
x=jQuery(".Caja2");
x.hover(entraMouse,saleMouse);
}
function entraMouse()
{
jQuery(".Caja2").stop().fadeOut();
}
function s...
Hello everyone,
1) I have this function in my .html file. This .html file is hosted on google site, but I can make a connection to www.yahoo.com using the makeRequest function, infact I can make connection to any site that is not hosted on google site. My problem is, the moment i change the URL to a http://mymachine:8080, the makeRequest...
Does anybody know how to append scripts dynamically in Chrome? I copied the following code that works in FF 3.0 and IE7 but not Chrome.
function include_dom(script_filename) {
var html_doc = document.getElementsByTagName('head').item(0);
var js = document.createElement('script');
js.setAttribute('language', '...
I am using TinyMCE 3.2.5 and by default when you click the center align button it uses an inline style < div style="text-align=center" >. I would like tinyMCE to use
< div align="center" > instead of the inline style.
I know setting inline_styles: false in the configuration works. But I would like to use inline styles for everything bu...
Hi everyone,
I am writing a GWT app that involves interacting with an external document in an iframe. As a proof of concept, I am trying to attach a click handler to a button.
The following works in javascript
var iframe = document.getElementById("rawJSIFrame");
var doc = iframe.contentDocument;
var body = doc.body;
var button = doc.g...
I have a set of images that correspond to video thumbnails. The user clicks a thumb which loads the browser. This would be simple enough, but I need to track which of the thumbs was clicked, so that I can automatically cue up the next video in sequence.
My first thought was to do something like this (highly simplified example):
<div ...
Hi all,
I want to resize the dojo grid row by dragging it as we can do with the column.
I want it some thing like Excel row which we can resize(minimize or maximize its height), is there a way to do this in dojo grid?
Thanks
Faz
...
I have a setup function that runs onload to add some behaviours to elements. The setup function passes arguments to the mouseover event but those arguments are being changed during the for loop because they are local references.
function setupAreas( image, map, lots ) {
// obj is a simple wrapper for doc.getElementById
var image...
This is related to my previous question about selecting visible elements. Now, here's the twist: Let's say I want to select the odd children only from the set of visible children of an element. What would be the best way to do this?
Edit: here is an example of my input and expected output.
<!-- A list with some visible and invisible ch...
if im loading data for the markers from a database do i write the output queried from the db into a javascript file or is there a cleaner way of doing it?
thanks
...
I pretty consistently get GMaps API javascript exceptions that look like the following:
Ve.k is null or not an object (FF & IE)
b.k is null or not an object (FF & IE)
a is null (FF)
a.$e is undefined (FF)
Uncaught TypeError: Cannot read property 'k' of undefined (chrome)
Often the exception occurs during an eval of some expression in...
Hi, it is a quick question that I was hoping someone with a bit more Javascript experience than myself could help me nut out. Basically I am writing a simple HTML form that uses a google map, but to reduce the ammount of clutter on the screen I have removed the google interface and replaced it with some simple submit buttons to change th...
Is there a sleep function in javascript?
...
html {
width:100%;
}
How to change the css of above mentioned html dynamically on clicking the button using javascript... ? I mean i want to make the above html css as written below.. But i have to change this dynamically using script....Can we do this?
html {
width:100%;
overflow-y: hidden;
}
...
I have many SWF file those I have included in my web page using the HTML Object tag. Its working fine but, I am not able to maintain the size of my SWF files. I have following code for SWF files.
<object id="example_flashGame" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/c...
how to hide a bullet points? example like this website
http://www.grainge.org/pages/various_rh_projects/alt_dropdowns/showhide_3/showhide3.htm
you can see the example
first Hotspot
second hotspot
if we click 'first' it appears but if not it's not appear. how to do that
...
Is it possible to use Javascript to emulate the Add to Home Screen option in Mobile Safari's bookmark menu?
Something similar to IE's window.external.AddFavorite(location.href, document.title); possibly?
...
I want to prevent my web site from save As functionalily of browser. My site have some javascript file too. Is there any source code to prevent from save as the web site from browser or source code for encryption of site.
Thank you
...
I have a very peculiar problem.
I had written some custom columns for SharePoint.
Recently, I found these custom columns break when I group the list items in SharePoint.
Now the problem is peculiar because, these custom columns work perfectly in FireFox browsers, they break only in IE!
After googling around for browser compatiblity i...