My HTML is something like this
<div id="mydiv" class="common">
<input type="text" id="text1" value="" />
<input type="text" id="text2" value="" />
</div>
I am assigning a function on the onclick event of the textbox like this
$(document).ready(function() {
$(".common input").click(function() {
//////// Wh...
Noob here - I'm working on a simple Javascript calculator, and I'm using lists (li) for buttons. I want the li background-color to change onClick, but then automatically change back half a second later. So basically I want the button click to flash the new color, not toggle it.
Is this possible?
Edit: This is what I have in my header...
Hi there,
Just imagine a formular where there is a checkbox and a textfield. If someone starts typing into the textfield "bla bla bla whatever", the checkbox should tick itself. Is there a event that corresponds to the typing or do I have to use .focus ?
...
In a page I have a link; clicking on it opens a dialog and sets a textbox value for that dialog.
However, once I click on submit in that dialog, the textbox value is null.
Link:
<a href="#" onclick="javascript:expand('https://me.yahoo.com');
jQuery('#openiddialog').dialog('open'); return false;">
<img id="yahoo" class="spacehw" src="/...
I have table that gets dynamically created.
When using jQuery and toggle, everything works. I however get a small visual glitch - it seems the HTML sometimes get selected. How would I disable this on a faulty drag or mouse operation?
Is there a difference in the DOM between text in a cell and 'not text' or buffered space in a td?
Than...
i would like to calculate the width of the li's for each submenu en then put in the ul element.
example
<ul>
<li>level 1</li>
<li>
<ul style="widht:??;"> // total width li's added here 70px
<li>level 2</li> // width of this li 20px
<li>level 2</li>/ width of this li 50px
</ul>
</li>
<li>level 1</li>
<li>level 1
<ul styl...
I use the following in order scrolling to top.
How could i edit it so the top is set by a div tag?
var pageRequestManager = Sys.WebForms.PageRequestManager.getInstance();
pageRequestManager.add_endRequest(function() {
$('html, body').animate({ scrollTop: 0 }, 'slow');
});
...
Hello,
i have two String fields who represent Date in my page and i would to compare this two fields to know if my first date < second date
<tr>
<td align="right">First Date: </td>
<td align="left"> <html:text name="addPublicationForm" styleId="firstDate" property="firstDate" maxlength="10"/></td>
</tr>
<tr>
<td align="right">Second Dat...
I have added ckeditor on my page. the thing is that when i make changes in the value in the ckeditor and post the value to the controller the new posted value is not there (the previous value is coming). the new value comes on posting it second time.the cycle goes on(the changes in the value in the ckeditor comes on the second posting). ...
Hi All,
is there any plugin can create a configuration editor (like about:config in Firefox) using jquery.
I have a xml based configuration file, I want to load it, edit it and then save the changes again into the xml file.
...
OK, so I bought a 46" screen for the office yesterday, and with the imminent risk of being accused for setting up an "elaborate World Cup procrastination scheme", I'd better show my colleagues what it's meant for ;)
Looking at my simple sketch, and at these great projects from which I was inspired, I would like to get some input on the ...
Having problem with this bit of code qith jQuery. it should pick the values from current form and then submit them, but when I try to get them with jQuery they always turn up undefined.
I know the SQL results are fine since they show correctly in HTML table, so it must be my inferior javascript skills.
New with jQuery and I'm at loss :(
...
jQuery selectors select from the document.
How do I select from somewhere else other than root?
Say I want to select some children from an html object.
For this
function dothis(obj)
{
$j("#tabs").removeClass();
$j("#tabs>ul").removeClass();
$j("#tabs>ul>li>a").each(function()
{
var tabNum = $j(this).attr("h...
Hi,
I'm trying to slideToggle a in a table with jQuery and it works in FF, OP, CHrome. Only IE (6,7,8) is giving me problems. It slides down perfectly down and up, but after the slide up animation is finished. The hidden pops up in full height and then closes.
So I guess it must be somwhere inbetween when it switches from a minimal h...
Hi all
I am working on a print form that will enable Admin user Change the lay out of the print form
so i select JQuery Dragable for the job and its working fine but their is one problem when
Enable or Disable the first Element in HTML that is dragable take the Disable Style when Dragable is Disabled the other element keep there orig...
Hi all,
I've created a somewhat silly site that shows you the expected weather forecast for any city in the World. On webkit based browsers, when the weather is sunny a sun with CSS3 animated rotated sunbeams appears. This works fine on Chrome.
An example (sunny, at the moment) page is:
http://willitraintoday.co.uk/iceland/reykjavik/
...
Hi,
I have an AJAX controller action which returns JSON. The returned JSON is handled via jQuery and contains a message displayed in an update div. The JSON also contains a flag which indicates a change in state. If this is true the entire page needs to be reloaded from a different url. This is currently performed in the jQuery using wi...
Hi,
I was wondering how I could use JQuery to select the child of a parent?
I have the following.
$("#navigation a.subpage").click(function () {
$("#navigation ul ul")...
The HTML looks like this.
<li>
<a class="subpage"...</a>
<ul style="hidden">...</ul>
</li>
I need to somehow select the parents of the link. That would ge...
Hello,
I have a list of links eg :
<ul>
<li><a href="http://google.com">Link1</a></li>
<li><a href="http://example.com">Link2</a></li>
<li><a href="http://example.com/sdf">Link3</a></li>
</ul>
When a link is clicked, a iFrame should be generated in the middle of the screen loading the pag...
i have this function where basically add and remove the disabled attribute form a input field:
$(bla).click(function(){
if (something) {
console.log($target.prev("input")) // gives out the right object
$target.toggleClass("open").prev("input").attr("disabled", "disabled");
}else{
$target.toggleClass("open").p...