Greeting,
I have this input field
<input name="question"/> I want to call IsEmpty function when submit clicking submit button.
I tried the code below but did not work.
any advice?!
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=unicode"/>
<meta content="CoffeeCup HTML Editor (ww...
I want open window.open as modal popup.
var features = 'resizable= yes; status= no; scroll= no; help= no; center= yes;
width=460;height=140;menubar=no;directories=no;location=no;modal=yes';
window.open(href, 'name', features, false);
I can use Window.ShowModelDialog(), but in my child window I am calling parent javascript metho...
Hiya All,
Strange issue i am having while working on this in the bottom right hand corner is a history section with a scrollable section that moved right or left. On load it picks a random number and moves to it.
Problem is that on load (without moving) it loads in the wrong position, and on moving with the api it moves to the wrong of...
<ul>
<li><a class="selected">A</a></li>
<li><a>B</a></li>
<li><a>C</a></li>
</ul>
How can I remove the attribute selected from all <li>'s when one of the element is clicked and set the one being clicked to selected?
I'm learning jquery.
Updated the code
...
Using the following code, I get a INDEX_SIZE_ERR: DOM Exception 1 error on the thisRange.setStart line. The code is meant to go through a whole page, find instances of the searchString, and then add a link in front of that search string. For example, if it finds 5 instances of the string, right now it will add the link in front of the fi...
I have code that generates SVG that was developed for IE and the Adobe SVG Viewer. The Adobe SVG Viewer has a custom function called browserEval (see http://www.xml.com/lpt/a/994) that is being used to cause the browser to eval a window.open() call. This doesn't work in Chrome's native SVG renderer (and I haven't tried Firefox).
How c...
I'm struggling to decipher a way to remove several specific href elements which contain no IDs and are children of individual parents with no IDs.
The best I can manage is identifying the four offending, out of 8 or 9 href tags (and the number may vary), by a specific word within the URL itself. For this, I do the following:
<script l...
I'm looking for a tool that will allow me to display visualizations of social networks dynamically online. There are a lot of great visualization examples out there already:
http://www.readwriteweb.com/archives/the_best_tools_for_visualization.php
http://socialmediatrader.com/10-amazing-visualizations-of-social-networks/
I know lots ...
In magento I know how to include js files in the page layout file. How though, do i include specific javascript files only on certain pages with my custom module.
For example i am writing a custom module that will work with the product view and list pages. I therfore want to have some sort of layout update that i can use with my module...
I need to detect the height of a web page displayed on a BlackBerry and I've tried the following.
height, window.innerHeight, and screen.availHeight
My BB 9700 simulator returns values of 304, 327, and 360 respectively. The closest "correct" value is 360 since that's the actual height of the displayed page.
However, the site has a ve...
Hi there !
I have something like this HTML structure :
<form name="myvalue" id="hello">
<input type="text" name="name" />
</form>
I'd like to retrieve the form's name attribute in Javascript, with a cross browser solution.
Obviously,
document.getElementById("hello").name
won't work because it will return the corres...
Input:
<content>
<dom id=1>a</dom>
<dom id=2>b</dom>
<dom id=3>c</dom>
<dom id=4>d</dom>
</content>
Output:
<content>
<dom id=4>d</dom>
<dom id=3>c</dom>
<dom id=2>b</dom>
<dom id=1>a</dom>
</content>
I'm looking for a function (if exists) like this:
$('content').inverse();
...
Question
How do you overwrite the refresh key with a custom javascript function? I use Prototype library, by the way.
Why
I have a video with user comments on the side. There is a button to only refresh the comments via a JS function updateComments(). During some user testing, some idiots refused to use that button to update the comme...
I'm still learning regex (obviously) and i can't figure it out, and i want to do it the right way rather than doing it the long way. How can I:
Find all <p> or </p> and replace with a \n except the first <p> and last </p> in which case replace with nothing, just remove, and for <br>, <br /> and <br/> replace with \n also.
With Regex OR...
$('#XynBp0').find('input').each(function(){
if ($(this).attr('value') == 'Cancel'){
$(this).trigger('click');
}
});
doesn't work in IE7
...
I am using jQuery UI tabs, but I am having an issue.
My javascript code:
$(function() {
$("#tabs").tabs();
});
My HTML:
<div class="demo">
<div id="tabs">
<ul>
<li><a href="#tabs-1">Eat</a></li>
</ul>
<div id="tabs-1">
tab 1
</div>
<div id="tabs-2">
tab 2
</div>
<div id="tabs-3">
...
I have been trying to close the window on button click but am unable to do so.
I have added javascript window.close()
added on the code behind page on button click event all in vain. Language c# or vb.net
...
Hi all,
I am trying to delay the loading of images using plain JS. my method to do this is by giving empty src field for the image and inserting the image url into a temp attribute called "lang" as used in the example below. ie >
<img lang="logo.gif"> instead <img src="logo.gif">. When pressing a button the js below is initiated to inser...
Hi,
I am working on an iframe based Facebook applicaton. I am able to use FB.Canvas.setAutoResize(); to let the iframe "stretch" the page so there's no scroll bar for the iframe. The page may be 2-3 page-length in height. I can scroll down the page using the windows scroll bar. The issue is when I am at the bottom of the page and I c...
Hey guys,
I am trying out node.js, the following is the example web server from the documentation with an added counter and it prints the counter to the console when ever a client/browser requests the page.
The problem is, its being called twice when requested by the browser.
This is what I would expect would happen:
browser : Hello...