Using a dropdown menu, I'm to figure out how to activate SQL query without using a form button. Query triggered automatically on user selection.
The code I have so far uses a button to do the queries. (For now only viewing the "View All" --or view specific product type works. The "order by price" high to low, low to high, will be posted...
Hello, I have got a div with contenteditable that should trigger a < br /> insert on "enter".
Everything works fine in IE but Firefox drives me crazy.
this.e.keydown(function(event) {
if(event.keyCode == 13) {
var execute = editor.insertHTML(\'<br />\')';
eval(execute);
return false;
}
});
Firefox ignores < br /> at t...
I have a webpage form with a checkbox on it. I am trying to set the box to checked clicking an that exists on another part of the webpage using the onclick.
NONE of these seem to work (form and checkbox ID/NAME are all set properly):
<a href="#" onclick="document.getElementById('frmEditBasicBasic').active.checked=TRUE;"> test </a>
...
I'm sure this question has been answered before, but I don't think I'm using the right search phrase.
I think an example will explain better what I'm trying to ask:
var test = {};
test.example = function(parameter_2){
alert(parameter_1+parameter_2);
}
test("parameter_1").example("parameter_2");
Obviously that last line won't work...
Hello all!
We have an application running on a Windows Server and being accessed by IPads from Safari. The web part is written in javascript.
We would like to store user preferences in the server, but are lacking an identifying number that we can retrieve from the ipad device through our web code, so as to store different ipad's settin...
I have a site. Would it help its SEO ranking if I allow B2B business customers to repost the site's blog's RSS feed (I'm thinking of using the partial RSS feed with links back to the site to "read more."), will that boost SEO rankings?
What if I (1) give the business customers (They may not be very tech savvy, and therefore, I'd like to...
Say I have this:
var x = {
a:{a1:"z", a2:"x"},
b:{b1:"y", b2:"w"}
}
Is there a way to iterate over x to get "a" and "b"?
I want the member name, not its content (I don't want to get {a1:"z", a2:"x"}).
Thanks
...
I'm having trouble debugging an issue and looking for more information on the possible sources of error with it.
...
I have some code that sorts table columns by object properties. It occurred to me that in Japanese or Chinese (non-alphabetical languages), the strings that are sent to the sort function would be compared the way an alphabetical language would.
Take for example a list of Japanese surnames:
寿拘
松坂
松井
山田
藤本
In English, these would be S...
I have a div#dropdownCont with onmouseout and onmouseover listeners attached via:
domTarget.attachEvent('onmouseout', function(e){hideDropDown(e);});
domTarget.attachEvent('onmouseover', function(e){showDropDown(e);});
The dropdown works like this -- when mouseover event happens, the div#dropdownCont expands downwards as its childnode...
I have a vehicle and a product object and I need vehicle to call a function within product.... I can't seem to figure it out, what should I do here?
var vehicle = function () {
return {
init: function () {
var that = this;
jQuery('.vehicle-year-profile .options .delete').bind('click', function (e) {
...
I have written the following script below - I am not quite happy with the script as I think it could be written in a more elegant and dynamic way...
I am using ftp.exe to ftp files from my application to another server.
If the folder structure does not exists on the web site. I need to create the folder stucture...
and doing it this w...
I was wondering if there was anyway I could make another browser within my webpage. Basically I want this browser to be an interactive area on my webpage (about half the page).
The main page should be able to detect where every click was made within the mini browser.
Is there some apis that would help me out? Or would my best bet be to...
I render this JSON object:
[{"created_at":"2010-09-21T20:41:28Z","subject":"hello world"}]
Then I use this date parser to parse it (see below), but it only works in Chrome 6.0.4, Firefox 3.6.8, but NOT Safari 5.0.2 --- I get NaN errors. What gives?
Date.prototype.toRelativeTime = function(now_threshold) {
var delta = new Date() - t...
I recently upgraded to Django 1.2.3 and my upload forms are now broken. Whenever I attempt to upload, I receive a "CSRF verification failed. Request aborted." error message.
After reading Django's documentation on this subject, it states that I need to add the {% csrf_token %} template tag within the HTML <form> in my template. Unfortun...
I have an ASP.NET page with an Infragistics webgrid on it. I handle the mouseover, mouseout events over the rows of the grid in a couple methods in Javascript to change the mouse cursor to the pointer and back to the default as they mouse over rows. I also toggle the color of the mouse-over'd row.
When I run the page in debug locally, i...
I'm already tossing around a solution but as I haven't done something like this before I wanted to check what SO thought before implementation.
Basically I need to modify an existing web based application that has approximately 20 users to add push notifications. It is important that the users get the notifications at the same time (PC...
I want to create a website that can be visited by type of browsing device and when the user visits the site on different devices (iPad, iPhone, Netbook, PC) they immediately see the version of the site optimized for them instead of having to go to m.example.com . I know that you can specify html to print etc. Is there a type for device s...
I'm using the following Javascript to restrict a text field on my website to only accept numerical input, and no other letters or characters. The problem is, it REALLY rejects all other key inputs, like ctrl-A to select the text, or even any other browser functions like ctrl-T or ctrl-W while the text box is selected. Does anyone know of...
I'm trying to get some html5 drag-and-drop functionality in a Rails 3 app with Paperclip. So, basically:
One or more files are dragged and dropped onto a DIV
Files are POST'ed to a Rails action (together or one at a time)
Rails action saves each files as a new attachment in Paperclip
Right now the only way I can get this working is b...