I want a part of my HTML page to be visiable to users with enabeld JavaScript only after clicking on to some button, while users with no JS support will seeit always.
So I mean we have a normal page with header and body but with no footer unteel some button is clicked. (while wievers that use no JS modes will see footer always.)
...
Hi There
I am attempting to add google analytics tracking to an Adobe Air app created with HTML and javascript.
I have tried adding the ga.js file and using it like I would in a webpage:
<script type="text/javascript" src="lib/js/ga.js"></script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-********-1");
...
I'm in the midst of implementing drag/drop functionality on a table.
How it works: User left-clicks on a row; the row gets dimmed and a span is added to the DOM. The span acts as a place-holder for the row and follows the cursor as long as the user holds down the left mouse-button.
The headache: When holding down the left mouse-button ...
I have an array like this:
Array
(
[0] => Array
(
[id] => 9826
[tag] => "php"
)
[1] => Array
(
[id] => 9680
[tag] => "perl"
)
)
I want to pass this to a javascript variable that looks like this:
var availableTags = [
"ActionScript",
"AppleScript",
"...
Douglas Crockford said a long time ago:
Classical objects are hard.
....
Shallow hierarchies are efficient and
expressive.
I came to this conclusion separately after years of JS development, and now I'm struggling to convince my colleagues. Arguments don't help, because apparently "classes and dozens of methods are easi...
Hi, i need to be able to able to detect when any character is entered into a textbox in Javascript, and clear another corresponding textbox. I have used the onfocus method for this but when tabbing between textboxes to get to submit, it removes the data and I don't want it to.
What methods are there I can use to trigger a JS event when ...
Is there some way for me do something like the following in Javascript? ( Specifacly I want to do this from Javascript running in an Iphone OS UIWebView)
create a function called RedirectAndExecuteFunctionOnDomReady(url, function)
Redirect to the HTML of the provided url
When the new HTML DOM is ready, execute the provided function (w...
hi
in my web page i am using google map script its working at first time of page loading within update panel but its not working when i click any server control like button(partial post back) so how can i fix this issue. and this script
and this div
for ...
We have a few places where we include inline <script> blocks which run code, wrapped by $(document).ready(). Several of these blocks use methods dependent on other external scripts. During normal page execution this technique works fine, but when the user navigates away from the page before it's completely loaded, the $(document).ready()...
How do I get a reference to the clicked link to delete the correct row?
<tr>
<td>c1r1</td>
<td>c2r1</td>
<td><a href="javascript:delete_row();">delete</a></td>
</tr>
<tr>
<td>c1r2</td>
<td>c2r2</td>
<td><a href="javascript:delete_row();">delete</a></td>
</tr>
function delete_row() {
this.parent().parent().remove();
}
I know I ca...
Hi,
I'm developing a web application where user require to print a particular form with a single click. Based on my findings I understand that we need to create a printable version of the form and then send it to the printer.
But still I could not find out a way to send such printable version of the form directly to printer without di...
This question has been posted on Stack before, but none so specific as to what I'm trying to understand.
The simplest way to check if a URL is corrrect to send a http Head request. But how do you use that to specify the URL ?
I found this in a previous post :
function UrlExists(url) {
var http = new XMLHttpRequest();
http.open('HE...
A jsfiddle of this code can be found here. Pretty basic code. I just want an autocomplete list for the list of sites in the Stack Exchange network with their favicon. The source function works fine. I can type in sta and see the matches. If I hover over them or select one, but the focus and select functions report that ui.item is un...
I have a web application that receives a simple text file, but I need this file to be downloaded to a specific path. Meaning, when the application receives a text file, it will always be downloaded to a specific folder (for example, to C:\MyFolder). If it isn't possible, then I need to copy the file from where user has chosen to my fold...
Example:
$(X).bind('click', function() { alert( 'Two' ); });
$(X).bind('click', function() { alert( 'Three' ); });
$(X).bind('click', function() { alert( 'Four' ); });
$(X).bind('click', function() { alert( 'Five' ); });
**$(X).bindUp('click', function() { alert( 'One' ); });**
When the user click X the output should be:
alert( 'One...
I want to represent any objective-c object in JSON format at RUNTIME, so that a javascript script can use it to access any field/variables/properties through 'dot' notation.
For example,
Objective-c class for the object could be:
@interface myNativeObject
PrimtivieType *pVar;
CustomClassType *cVar;
@end
Where CustomClassTyp...
I have 1 ModalPopupExtender inside a UserControl. Everything works great until I start adding the same usercontrol to the page. I am getting this error message in the javascript console::
Message: Sys.InvalidOperationException: Two components with the same id 'MPE1' can't be added to the application.
I understand the error, it obvious...
Hi.
I'm trying to make a simple pop-up <div> that's designed to show mouse coordinates while a user is dragging a mouse pointer. This pop-up appears at the bottom on the right to the mouse pointer. The underlaying div has its own very important mouse event handlers (e.g. .mousemove()). The pop-up div is quite far away from the mouse poi...
In say, mobile Safari, can I get the device's phone number? Presumably this would prompt the user if its allowed like it does with location.
...
I can't seem to find the answer to this question anywhere so I ask here.
I already use successfully fancybox like this:
$("#editor").fancybox({
'width' : 1000,
'height' : 600,
'autoDimensions' : false,
'autoScale' : false,
'ajax' : {
type : "POST",
...