jquery

JQuery not loading on first page visit

Hi all, Im having an issue loading the JQuery library when I visit my webpage for the first time.. therefore none of its functions work...If i visit another page on my site, or reload it , the script works and continues to from there on... and to recreate the issue, I have to clear my cookies....I have checked my code and it seems fine...

Javascript Highlight Selected Range Button

I'm attempting to create a study tool for a page that allows a user to select any text on the page and click a button. This click then formats the selected text with a yellow background. I can make this work inside of a single tag, but if the range of selection is across multiple tags (for instance, the first LI in an unordered list al...

Simple jQuery .each problem

I have a UL with 9 anchor tags, each with the class 'highlight'. Here is a bit of Javascript with jQuery: var titles = $('a.highlight'); jQuery.each(titles, alert(titles.length)); What I expect this bit of code to do: Alert 9 times, the number 9. What this bit of code actually does: Alerts 1 time the number 9. What am I missing...

Using JQuery on JavaScript variables

$.getJSON('ajax_popup.php', function(data) { var popupDiv = decodeURIComponent(data.data); $('body').append( popupDiv ); }); This piece of code returns <div> element that has other XHTML elements inside. It is returned in JSON format with JQuery. The returned XHTML from data.data is stored into JavaScript variable by first deco...

forms called by ajax

how can i get a form to work properly when it is loaded in the html injected by ajax? im using jquery if its any help... ...

Javascript + jQuery, click handler returning false to stop browser from following link

I'm trying to stop the browser from following certain links, rather I want to unhide some Divs when they are clicked. I'm having trouble just getting the links to not be followed though. Here's what I have: var titles = $('a.highlight'); jquery.each(titles, function(){ this.click(function(){ return false; ...

ASP.Net MVC with Date Picker Postback

I need to setup an ASP.Net MVC view with a Date Picker that will send a postback to the controller when it is changed with its new date. I know there is a Date Picker in JQuery, but how would i get it to send the data to the controller? ...

jQuery Dynamic selector

How can I get the adjacent sibling of a dynamic selector? This is what I have but it is not working. var titles = $('a.highlight'); titles.click(function(){ $(this + " + object.hidden").show("slow"); return false; } ); ...

how do i set a specific domain which can use a ASMX service?

I want to set my default Domain name for my site to be given access only by the webservices. I'm using the webservices in JQuery Ajax ...

jQuery.post and encoding

I have a form in a webpage, where the user can enter any arbitrary html. Once he clicks submit, I am sending the content to the webserver via AJAX using jQuery.post(). But for certain HTML, I am getting this response from the server HTTP/1.0 400 Bad Request Content-Type: text/plain Date: Mon, 26 Oct 2009 05:28:00 GMT BAD REQUEST: Bad...

JQuery Datepicker issue - asp.net

Hi, I have used JQuery within my asp.net page. JQuery is working fine. I could see the calendar and can pickup the date. The problem is that when the page is postbacked the value is lost. Am i missing some code? Does anyone of you have the idea? Below is what i have done - 1) Included the files - <script src="../scripts/da...

jquery json ajax function not successful

I have this part in my jquery ready function: $(this).ajaxSubmit({ url: '../lib/strapper.php', data:p, //where p is an object = {...} dataType:'json', success:function(result){ alert('test'); }, failure:function(){ alert('failed'); } }); and in my str...

Using jQuery to window location to rel value

I'm using the jQuery UI-tabs and rather than activate them onclick I am using :hover to change tabs. I would like for the link to take the user to the URL that is specified in the rel attribute, but I'm coming up empty handed in trying to find a solution. ...

Trigger click on embedded PDF

I have a PDF embedded in a web page using the following code: <object id="pdfviewer" data='test_full.pdf#page=1&toolbar=0&statusbar=0&messages=0&navpanes=0' type='application/pdf' width='500px' height='350px'> The PDF itself is set to open in full screen mode which shows no controls. The user can advance the...

i can't delete a cookie with jquery plugin?

First showing the cookie, use this code from: electrictoolbox.com/javascript-get-all-cookies/ Then i made a form to add some cookie <form class="cokies" method="post"> <input class="query" name="q" type="text" /> <input type="submit" name="save" value="saving"> <a>Delete Cookies</a> </form> $(document).ready(function(){ $('.cokies a'...

Selecting HTML Comments with jQuery

Does any one know how to select html comments with jquery? <html> <head> <title>Check Test</title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"&gt;&lt;/script&gt; <script type="text/javascript"> $(function() { $("body *").each(function() { ...

ajax postback in jquery

i'm having a ajax request on the page. is their any way to find when a ajax is requested on the page. in jquery or javascript to find or initiate a function whn ajax request is called in a page. ...

Jquery - Apply class based on contents of <a>

I have a horizontal navigation menu which I can edit the source of, my only option is to add classes dynamically when it loads through JQUERY. Imagine I have 3 tabs: Home, Profile, Blog Each with a link like so: <a href="home.html">Home</a> Is it possible for JQUERY to look between the <a> </a> tags and find the text (E.g. Home) a...

change div id using jquery

How to change the id of the div using jquery? I have div with id (initially as 'first') and a dropdown (with values 'first', 'second'). On changing the dropdown value, i need to change the id of the div according to dropdown value. ...

jQuery siblings()/next() doesn't work in IE

this jQuery script works on firefox, it give alert. but it doesn't work in IE 7. have any idea what went wrong? markup: <td class="tdnotes"> <a title="" class="notes" id="order-1" href="#"> <!-- an image --> </a> <div style="display: none;" id="wrap-order-1" class="thenotes"> <!-- text area, input elements --> </...