jquery

Maxlength in textarea using jQuery

Using the script off http://viralpatel.net/blogs/2008/12/set-maxlength-of-textarea-input-using-jquery-javascript.html I am trying to limit the input of a textarea to 1000 characters. Prototype is also included in the page. It works fine in chrome, but in firefox the following error is given and the input is not limited: $("textarea[ma...

How to create a Jquery slideLeft delete for list item?

Hi I am trying to create a page loading my image, content, and the delete option. The image url and content are output from database. What I want to need is that on clicking of the delete the image, it would render animation to slide left showing the the image has been removed. My code so far ... Jquery Script: $(function() { $("#sorta...

jquery icons in jquery tabs problem

when i put jquery icon on my website it looks fine, but when i put icon inside jquery tab, icon image is moved few pixels left has anybody solved that problem already? thnx! ...

apply jquery effect to parent li but not to child li element

My html markup is as below: <ul class="top-nav"> <li id="page-1"><a href="/">HOME</a> <ul class="page-1 current"> <li><a title="" href="#">FEATURES</a></li> <li><a title="" href="#">ABOUT US</a></li> <li><a title="" href="#">CONTACT</a></li> </ul> </li> <li id="...

getJSON: why does the 1 example work, but the other not?

I have 2 examples of a function that retrieves json-data and gives an alert. In this example, everything goes fine: http://jsbin.com/uwupa3/edit $(document).ready(function(){ var timeService = "http://api.flickr.com/services/feeds/photos_public.gne?tags=cat&amp;tagmode=any&amp;format=json&amp;jsoncallback=?"; $.getJSON(timeService...

Is there jQuery like selectors for Java XML parsing?

When I want to find elements from XML in with jQuery, i can just use CSS selectors. Is there any similar selector system for XML parsing in Java? ...

Problem with using lightbox and jquery-ui accordion in Drupal 6.15

Dear All, I have having problem putting jQuery-ui Accordion and Lightbox on the same page. I am using Drupal 6.15 Jquery 1.3.2 Jquery-ui 1.7.2 Lightbox2 drupal module The thing is... my lightbox works fine if I exclude the following line:- drupal_add_js('sites/all/js/jquery-1.3.2.js'); but if I exclude the above line, my accordion ...

Reversing words in a string

Hello, does anybody know how can I sort words in string using javascript, jquery. For example I have this: var words = "1 3 2" Now I want to reverse it to this: var words = "2 3 1" Thanks ...

Using jQuery to check if some radio buttons are checked and apply CSS block style.

Hi, I'm trying to check if one of the following radio buttons is selected and am beginning to think that there must be a better way of achieving the same result using a different jQuery approach. E.g: if($("input[id='incRating_yes']:checked").val()) $('.question4').css('display','block'); if($("input[id='incRating_fro']:checked").val(...

jquery scroll content with stop function

Hi, I have a div with a height of 200px (viewport). Inside this div there is a ul>li list with many links. Now I have 2 arrows to push/scroll this content up and down. I'm using this kind of code (will be changed into bind- events): $("#jq-manufactors_bot").click(function() { $("#manufactors .toggle").animate({marginTop: "-=100"},...

jQuery pass url variable into load function

Hi, I'm trying to use load to reload a portion of the current page (long story why) but am having an issue with the variable syntax. Here is the snippet of code: var pathname = window.location.pathname; $('#menu').load("/cms.php #menu"); I woudl like to replace /cms.php with the variable, but am having issues with the corrent syntax...

How to reset all checkboxes using jquery or javascript?

How can i reset all checkboxes in a document using jquery or javascript? ...

JQuery UI Slider for time

Hi I need to implement a slider for 24 hour time range . I like to use jquery ui slider for this . I have written below code <script type="text/javascript"> $(function() { $(".slider-range").slider({ range: true, min: 0, max: 23.59, step: 0.15 }); }); </script> I like the range is like 01:00----...

Using jQuery to select items that have style "visibility:visible" or "visibility:hidden" NOT "display: none"

How do you select only visible elements using jQuery? jQuery selectors :visible and :hidden only respects display:none as really hidden? NOT visibility:hidden or visibility:visible. I understand they are not technically hidden because they still take their space. I just want to know their state so I can check checkboxes that are visibl...

How can I replace a table with a new one using jQuery ?

Whats the best way to replace a <table> with a new one using jQuery? I'm using ajax on the page to get the new data. ...

How do I display a message only if a certain amount of time has elapsed jquery - prevent form submission

I've got a checkout page which has some ajax calls that update hidden fields when the user changes delivery country for instance. Most of the time, this works fine, the page has time to update hidden fields before the user clicks submit. Some of the time though, due to slow connection or whatever the ajax doesn't return the hidden field...

ajax success not triggered in firefox

Hello all. I have a strange problem that I cant' solve after hours of googling. The way my web application is built is not very optimal, but I can't do anything about this right now. I have made a User Control in C#. This usercontrol is hosted by a aspx-page that are inside an iframe and this page is inside a frame again. (Not optimal)...

Cannot access data from jquery ajax request, returns empty array

Hi, I have a form that is called via the fancybox plugin http://fancybox.net/blog - login example Here is the code I have: Form: <form method="post" action="" id="events_form"> <p class="clearfix"><label for="Name">Name:</label> <input type="text" name="Name" id="Name" /></p> <p class="clearfix"><label for="Company">Company:</l...

jquery parameters

I have a little problem, here, I'm reading data from a database, adding it to a table to be displayed on a webpage. The table in which this data is added lies inside a panel. To view this table, I would then use this javascript to expand the panel: <script type="text/javascript"> $(document).ready(function(){ $(".flip").click(functio...

variable scope in jquery

I'm trying to access the value of a variable that is set inside a .click function outside of the function but I'll get the error, can anyone please tell me what I'm doing wrong? var id; var currentPosition; var slideWidth = 368; var slides; var numberOfSlides; $('#accordion_catering h3').click(function() { id = $(this).attr('id'); ...