If I do this
var domElement = $("#id");
and the returned element is a div tag,
How can I then do something like
domElement.$('div a:nth-child(3)').after(somehtml);
This is an example where I want to add some HTML after the third link under that "domElement" div.
The above doesn't seem to work. I have numerous examples where I ha...
Hi,
I have a textarea in the form, and I need to see what I type there in the separate div like on this site, when you post qestion or answer.
In the textarea I got text from new line when pressing enter, but in the div text stays in the same line. How can I go to new line there?
I'm using this:
<script type="text/javascript">
...
Is ajaxComplete able to handle any ajax requests invoked in page, for example asp.net ajax or is it only for ajax requests originating using jQuery. I tried to handle Telerik's RadGrid like this without success
$('#RadGrid1').ajaxComplete(function() {
});
...
How to create the effect like trulia when you hover on the avatar?
http://www.trulia.com/voices/Home_Buying/Why_are_there_only_homes_listed_under_quot_Recen-164127
...
I am trying to create a dynamic table that is being built based on the value of a search text box. The Table will have probably 6 columns of 20(max) rows.
My problem is I can't figure out how to return the data from the web-service to the JS function in a way that will allow me to extract the data that I need.
Here is the web-serv...
I'm trying to use jqModal on page 1 to load the content of page 2 using ajax. It works fine, until i include jquery inside page 2: at that point, the javascript of page 1 breaks.
So, to be clear, it is adding:
<script type="text/javascript" src="/_js/jquery-1.3.2.min.js"></script>
inside page2's head tags that breaks it all.
Any id...
I have a very simple Python file:
f = open('C:\\Temp\\test.txt', 'w')
f.write('Succeeded')
f.close()
which I wish to execute from a JavaScript file, like so:
jQuery.ajax({
type: "POST",
url: "/cgi-bin/python1.py",
success: function (msg) {
alert("Data Saved: " + msg);
}
});
However, all that happens is that I get...
is it possible to find all nodes that don't have a specified child node?
for example:
(xml)
<item>
<name>item 1</name>
<admin>true</admin>
</item>
<item>
<name>item 2</name>
<admin>true</admin>
</item>
<item>
<name>item 3</name>
<parent>item 1</parent>
<url></url>
<admin>false</admin>
</item>
I want...
Hi everyone,
I am following this link to build a Client side repeater.
According to the above link to retrive the value from a Json key-value pair we can use result[i].property,for example
for (var post in msg)
{
var x= msg[post].Date;
alert(x);
}
Here x returns the date from Json string. When I am trying to use the same...
I have this code working fine with FF and opera but not with safari and chrome.
j(this).parent().parent().find(".box").load('test.html');
where (this) is for example the "a" in the following example html
<div>
<p><a href="#">clicky</a> to do ajax<p>
<div class="box">loadhere</div>
</div>
if i do parent only once I'm at the p ...
I have a form that is displayed in a popup. After loading, the background is grayed out, but the user can still scroll the background content up and down.
How do I prevent the background from scrolling?
Example here
the 'email this quote' link to the right of the pdf screenshot.
Thanks!
Joe
...
This site http://www.webstandards.org/ shows "Skip to content" or 3rd tab but this tab doesn't show in IE6, I already use jquery so i need jquery solution to show this tab in IE 6 also same like it works in IE 7 and firefox.
I want to use same thing in my client site.
...
So I've seen three ways to add html/DOM elements to a page. I'm curious what the pros and cons are for each of them.
1 - Traditional JavaScript
I beleive the strait JS way to do it is by constructing each element, setting attributes, and then appending them.
Example:
var myRow = document.createElement("tr");
myRow.class = "myClass...
In http://www.merchantos.com/makebeta/tools/spyjax/ there is a script that reads browser history. Its not the javascript history object. It checks the color of links that changes if the link was visited or not.
Is there a script like this but in jquery?
...
I need to detect not only the browser type but version as well using jquery.
mostly I need to find out if it is ie 8 or not.
thank you
I am not sure if i am doing it correctly
if I do :
if (jQuery.browser.version >= 8.0) {
dosomething}
I am not sure it will work for version 8.123.45.6 or will it?
...
Hi Everyone,
I am binding a click event to an image using Jquery Live binding. The first time I click on the image the simplemodal popup launches and draggable works fine. After that, the simplemodal popup still launches and the draggable item will not drag. Any ideas?
Code of Live Click Event:
$("table tr td img:not(.Help)").live(...
The question says it all. Which one is better and when to use what, I never use jQuery live() as I am using liveQuery plugin for a couple of years, I am used to it and still continue using it. But I want to know the subtle differences between the two and when to use each of it?
...
Suggestions other that dumping IE6 that is... I can't control that :)
Quick synopsis of what I am trying to do: I have a form with select elements. When the user selects a specific option in the select (id type2 in the code below), I display a div structure that contains a new select. I want the new div structure and its children to be ...
Hello all,
I have the below which disables all hyperlinks but after an event I want to enable them back all again, how can I do this?
$("a").click(function() { return false; });
I don't think its as simple as just setting it to true. ;)
Thanks all
...
I am trying to create a simple way to insert golf scores into a database. I want to use jquery to make it nice and user friendly. I don't have to worry about anyone not having js enabled as I will be the only using it.
I have created a test page you can go to look at what i have so far here,
www.barriemenshockey.com/testing/index.php...