Creating Hotkeys...
Aug 21, 2003is there a way to create a hotkey in JavaScript? ie) hit the 'v' key on the keyboard and it calls a function...
View 5 Repliesis there a way to create a hotkey in JavaScript? ie) hit the 'v' key on the keyboard and it calls a function...
View 5 RepliesI have a JavaScript app that uses the '?' key among others. However, in Firefox, this opens up the quick search box, and negates my command.
View 1 Replies View RelatedIm trying to learn how to scroll using arrow keys or hotkeys. Where you're able to use your arrow keys to move side to side and up and down.
Here are the 2 best examples of how it functions:
thinkingforaliving[dot]org/archives/4580
ffffound[dot]com (top right says hotkeys to scroll with)
Can anyone link me to how to script that? Or even if there's a proper term I should know about to search for tutorials..
It there another was to do this
var fso = new ActiveXObject('Scripting.FileSystemObject');
Im trying to run a javascript file automatically, but it complains that I
have to say YES to Active X.
I have a problem getting the following simple example
of "document.write" creating a script on the fly
to work in all html browsers.
It works in I.E., Firefox, and Netscape 7 above.
It doesn't seem to work in Netscape 4. Am I missing
something with it? When I look at page source in
Netscape 4 the script isn't even shown. Code:
I'm trying to create a function in JavaScript using Dreamweaver8 such that when a user hits the ' F1' key when a text box is selected a separate "pop-up" window will open, with text of my choice.
Does anybody have any pointers or even some source code? I use ASP on my server.
how you would piece
together a variable name and then assign it a value. I want to create a
hidden field and assign it a value based on the value of another variable
Right now it looks like:
("document.all.SM_MARK_10" + dateNumber + ".value")
where dateNumber is an already defined integer. What I want is to say
document.all.SM_MARK_1001.value="XX"
document.all.SM_MARK_1002.value="X2"
etc.
based on that value of dateNumber. Any way to do this easily?
How do I create a new tag with jquery? I tried something like this:
link = $('a').attr({
class: 'logoLink',
target: '_blank',
href: 'http://www.someurl.com/'
});
And then appended it to another image, but this added every link that already existed on the page.
rote a bunch of Javascript classes for this framework I'm working on and want to be able to create instances of the class using just it's name string. For example: Given the following class
javascript Code:
Original
- javascript Code
[code]....
I am writing a function that alerts a user that they did not enter a password what change do I need to make to this code to correct my issue it isn't doing anything.
View 2 Replies View RelatedI have the last assignment that she wants us to do and I had to pull up another assignment that she wanted us to build upon( which is one of those coding without anything advance)
<html>
<head>
<title>
[code]....
now she wants us to do max <beta and then name the variables with if a<b and I don't know if I put that in the concatenation or what to name my variables!
i am fairly new to JS for which i am working jQuery but that is for later.right now i am not getting my table printed out when i put input type="text".
here is my code
[Code]...
moreover i m writing this code to later call in a dialog box. using jQuery. but for now why isn't my code being printed with input type. do i have escape "" inside "" like in php? can i make more hierarchy type html in JS, i see when i put the td in next line the code doesn't execute. i guess white spaces have some significance in JS?
I need some help creating a script. Forgive me for posting this in multiple forums, as I first posted this in the php forum, but I know it can be done with a client side javascript as well. So here goes. I need to create a form where I can paste a list of domain names, click submit (or even just on mouseout, etc.), and have the script then return me to a page (or update a select field on the same page) with the domain names formatted within html code hyperlinking to the name.
For example, if I were to paste a list of
domain1.com
domain2.com
domain3.net
domain4.net
domain5.biz
etc.com
then click submit (or move my mouse out, [we're talking javascript here, right...]),
it would return the following results, ready for me to then paste into my webpage:
<a target="whatever" href="http://domain1.com">domain1.com</a><br>
<a target="whatever" href="http://domain2.com">domain2.com</a><br>
<a target="whatever" href="http://domain3.net">domain3.net</a><br>
<a target="whatever" href="http://domain4.net">domain4.net</a><br>
<a target="whatever" href="http://domain5.biz">domain5.biz</a><br>
<a target="whatever" href="http://etc.com">etc.com</a><br>
I'd like to create a simple menu that when I mouse over one of the menus, the sub-menus show up below the main menu. Kind a like pop-down menu, except the sub-menus show up horizontally below the menu.
Menu1 Menu2 Menu3
|
Sub-Menu1 Sub-Menu2 Sub-Menu3
I have searched a number of javascript sites to find such a code with no success. I suppose I could try to adapt a pop-down menu into this, but my javascript's knowledge is quite limited.
I've been thinking of an interesting project for learning javascript better, and decided I would have a go at creating a heatmap to show visitor activity on a site.
I have already written something which works out the percentage share of each link, but now I want to create something similar to that of the crazy egg heat map.
I just need a couple of starting pointers... to work out where a user clicks on a site, regardless of whether it is a link or not, i.e they click on a pic thinking it is a link or something, do I need to use coordinates?
Also, does anyone have any pointers on how to create the infrared style imagemap overlay?
im need to create s simple CMS/WYSIWYG, but im not a pro on js. I found one on a website, but i dont want to resort to stealing codes.
basically, theres a textarea, where you put in text, and a button for bold, italics and underline, etc. if i highlight something on the textarea and hit the bold button, the text automatically gets surrounded by the <b></b> tags, or or whatevers convinient. when i look at the inline js code from the button, it calls a function, but id rather simplify the code, it should be something like onclick=insertstyle("b","textarea_name");
I'm using the following code to create a quick and dirty search tool for a site we're building at work as part of an RFP.My issue is that rather than creating a new window for the results page (which is what it does now), I'd really prefer that a new div be dynamically created on the page where the results would be placed.Maybe that's not possible? At the very least,how to make the results display in the same window rather than opening a new one?
<SCRIPT LANGUAGE="JavaScript">
var item = new Array();
// "Page Name","path","Page Title","Many,Key,Words","Descriptive Comments"
[code]....
I created <a> tag dynamically and attached event to it.
Code:
var link = document.createElement("a");
link.setAttribute('class','devNodeStyle');
link.setAttribute("title",device);
link.setAttribute("href","javascript:void(0);");
link.attachEvent("onclick",openDevDetailWindow);
"attachEvent" is working only in IE. How to make that working in other browsers like Chrome/FF?
I'm making a science fair project, and need to know if someone could make the script below work into being invincible.
[Code]...
I'm trying to create a fairly simple form which contains a label, a
button, and a textbox.
I've done quite a bit of reading and, from what I can figure, the
following should work, but isn't....
var rowCommentBox = document.createElement("TR");
var cellCommentBox = document.createElement("TD");
var frmCommentBox = document.createElement("FORM");
frmCommentBox.setAttribute("METHOD", "POST");
var strAction = ""submitComments.asp?Org="+strOrg+"&date="+activeWeekBegins""
frmCommentBox.setAttribute("ACTION", strAction);
var rowFrmCommentBox = document.createElement("TR");
var cellFrmCommentBoxLabel = document.createElement("TD");
var strFrmCommentLabel = document.createTextNode("comment:");
var cellFrmCommentBoxButton = document.createElement("TD");
var btnFrmCommentBoxButton = document.createElement("INPUT");
btnFrmCommentBoxButton.setAttribute("TYPE", "SUBMIT");
btnFrmCommentBoxButton.setAttribute("VALUE", "UPDATE");
var cellFrmCommentBoxTxtbx = document.createElement("TD");
var txtbxFrmCommentBoxTxtbx = document.createElement("INPUT");
txtbxFrmCommentBoxTxtbx.setAttribute("TYPE", "TEXT");
txtbxFrmCommentBoxTxtbx.setAttribute("cols", "50");
txtbxFrmCommentBoxTxtbx.setAttribute("VALUE", strComments);
cellFrmCommentBoxLabel.appendChild(strFrmCommentLa bel);
rowFrmCommentBox.appendChild(cellFrmCommentBoxLabe l);
cellFrmCommentBoxButton.appendChild(btnFrmCommentB oxButton);
rowFrmCommentBox.appendChild(cellFrmCommentBoxButt on);
cellFrmCommentBoxTxtbx.appendChild(txtbxFrmComment BoxTxtbx);
rowFrmCommentBox.appendChild(cellFrmCommentBoxTxtb x);
frmCommentBox.appendChild(rowFrmCommentBox);
rowCommentBox.appendChild(frmCommentBox);
tbodyOrgToAdd.appendChild(rowCommentBox);
I would like to create a box with the same behavior as the "To" field
in the gmail "Compose Email" page.
That is a simple text box but when you start typing it will suddently
show a list of all the e-mails (for our purpose any string would do) in my address
book that have the given substring in it.
E.g. if I type in "ga" I get all the e-mails where the "ga" substing
shows up.
Then I can select from the list and press enter on the requested
address or I can keep typing if the address is not in the list yet.
I am trying to find a way to load XHTML content in an Iframe.
I use to do this in html by using the following code :
var iframeObject = document.createElement("iframe");
MyDiv.appendChild(iframeObject);
var data =
"<html><head><title>testing</title></head><body>data</body></html>"
iframeObject.contentDocument.open();
iframeObject.contentDocument.writeln(data);
iframeObject.contentDocument.close();
This works fine. I can create my content dynamicly and synchroniously.
No problem.
No I try to switch to XHTML, but have trouble getting th eiframe to
understand that it gets XHTML data. It simply assumes that the data is
"text/html".
I tried to add the contentType with the .open() arguments:
var iframeObject = document.createElement("iframe");
MyDiv.appendChild(iframeObject);
var data = "<!DOCTYPE html PUBLIC "-//W3C//DTD ..etc..
transitional.dtd">"
+ "<html xmlns="http://www.w3.org/1999/xhtml" > etc etc </html>";
iframeObject.contentDocument.open("application/xhtml+xml", true);
iframeObject.contentDocument.writeln(data);
iframeObject.contentDocument.close();
The code runs but the content is not seen as xhtml, so I can't mix html
and xml. Someone gave me the hint to use the following:
iframeObject.src="data:application/xhtml+xml,"+data;
This works, the data gets loaded and is actually seen as xhtml, but..
the loading happens async in stead of sync.
Is there anyone who can help me with :
- does document.open("application/xhtml+xml", true) work at all?
should it work ?
How would I put 2 strings like this into 2 separate arrays like my
examples below?
Div10,Div11|Div2,Div3,Div8,Div4,Div12,Div1,Div5|Di v3,Div5,Div9
France|Germany|Norway
var DivOrder = new
Array("Div10,Div11","Div2,Div3,Div8,Div4,Div12,Div1","Div3,Div5,Div9");
var DivNames = new Array("France", "Germany", "Norway");
Given an expression f = ƈ*x+3' from a user input I would like to do some sort of:
function userFunction(x):
return f(x)
is it possible with Javascript?
I'm making a nice little login box in Javascript but having problems Posting
the value inside a textfield.
In a nutshell:
I have a function:
function getPostData (value)
Which correctly gets the value, but how do I then create a form and submits
inside Javascript?
I am using telerik autocomplete in my application, I want to create the another autocomplete when i click the add button using jquery, can any help me in solving this issue.I need the jquery to create the autocomplet.
View 1 Replies View Related