jquery

calling a VB.net function from javascript

Hello all, I need to find a way to call a vb.net function in my aspx page from javascript. I have a Jquery function that makes the .drop class .droppable, and whenever I drop a .draggable onto a drop target, my Jquery code successfully fires a java alert statement. All in pure javascript. What I need to do is some heavy math! I do unde...

Is binding events in jQuery very expensive, or very inexpensive?

I just wrote a $().bind('event') function and then got concerned that this kind of a call might be very expensive if jQuery has to run through each element in the DOM to bind this event. Or maybe, it's just about as efficient as an event could be. The jQuery docs I've read aren't making this clear. Any opinions? ...

Using jQuery XPath selectors

I'm using a simple DOM parser function to catch XPath information of all nodes of a document For example, the HTML is: <div> <div>Everyday People</div> <div>My name is ACE</div> <div>Hello world</div> </div> Parsing the DOM to store the XPath info in the array arr: <script type="text/javascript" src="js/jquery/js/jquery-1.3.2....

jQuery: add clone to container

Hello. Is there other ways to add a cloned element to an container than: $(".product").draggable({ helper: 'clone' }); $("#container").append(ui.draggable.clone()); append just puts the element after the last element in #container. I want to decide where the position should be. ...

jquery save element positions (serialize?)

Hello. How do I save elements positions in a div? Do i use serialize and if yes how do I do it? I have this div: <div id="produtlist"> <img id="productid_10" src="images/pic10.jpg" class="sortableproduct" alt="" title="" /> <img id="productid_11" src="images/image1.jpg" class="sortableproduct" alt="" title="" /> <img id="...

need to access the checked checkbox

I need to get the value that has been assigned to the checkbox that is checked , and I've used for loop to show the checkboxes , now i need to access the values of the checkboxes that are checked only , Can anybody help me out with this ? foreach($inbox as $inbox_info) { <input type="checkbox" id="checkUnread" name="checkUnread" v...

Jquery Tabs

how can i make jquery tabs with image please give me code and related files ...

Sortable similar with youtube homepage

Hi guys! I'm trying to achieve an effect similar with youtube home page (you must be logged in so I posted a small movie to explain this): we have a basic sortable (vertical only) but on each sortable item we have a "move up" and a "move down" button. Those buttons do... exactly what it says: move each item with a neat animation move or...

need to get each checked checkboxes value which is in loop

<script> $(document).ready(function(){ function countChecked() { var n = $("input:checked").length; $("div").text(n + (n <= 1 ? " is" : " are") + " checked!"); } countChecked(); $(":checkbox").click(countChecked); }); </script> <style> div { color:red; } </style> </head> <body> <form> <inpu...

Is it possible to load a specific div from a variable?

Does anyone know if it's possible to load a specific div from a variable like $item = '#help_mobiel_prive'; $('#infopopup_content').load('help.html'+ $item, function() { only that one doesn't work ...

JQuery add class on current item

I have this method that changes an larger image source on click. I need to add a 'current' class on the selected. I have no problem adding this class,but I need it to remove the class on the other, previous, selected item. This is the code I'm using at the moment: $(document).ready(function() { $("ul.timgs li a").click(function(e...

removing all li elements inside a ul except first and last elements in Jquery

I have the ul. Now I have to remove all the li elements inside it except first and last li. How can I do it through JQuery. Tried remove method but could not find a way. ...

Hide children first and then reduce width of parent

I have the layout as follows: <div id="outerwrap"> <div id="innerwrap"> <div id="centerc">...</div> <div id="rightc" style="font-weight:bold"> </div> <div style="background-color:White;height:10px;top:284px;left:0px"></div> <div id="leftc">..</div> ...

how to select just the top element text?

i have this html: <span class="price"> $61.00   <span class="detailFreeShipping">With Free Shipping</span> </span> How to write a jquery selector which give me the price text only "$61.00"? i want to make it generic as i can because may be in some cases there is no inner span, just the parent one. ...

Running a rails RJS template from a jquery get request

I am using Rails and jquery with RJS templates to perform various AJAX requests. For most of my Ajax stuff I attach a submit handler to the form in my application.js as follows: $('#tagging_flickr_photos').submitWithAjax(); $('#tag_submit').click(function() { $('#flickr-photos-status').show(); }); This calls the form action whic...

Prevent browser timeout when using treeTable jquery plugin

I am using Ludo van den Boom's treeTable jquery plugin to represent a table as a expandable tree. Once my data set becomes large both Firefox and IE timeout on executing the call to the plugin in my $(document).ready. The plugin's public method is: $.fn.treeTable = function(opts) { options = $.extend({}, $.fn.treeTable.defaults, ...

jQuery - Define a div as a grid

Is there anyway to give a div the "grid" option in jQuery? I don't want to draw a grid on the div itself. The idea is for smaller layers to snap into the bigger div, in a grid like manner. ...

JQuery - animate moving DOM element to new parent?

I have an image tag inside of a table cell, that I'd love to move to another table cell, and have that movement animated. The code looks something like this... <td id="cell1"><img src="arrow.png" alt="Arrow"/></td> <td id="cell2"></td> I'd like to move "arrow.png" to "cell2", and have some kind of transition effect, preferably with J...

Window.Opener and referencing by ID issue because of .NET control

I have a .aspx page that has a link on it, then when clicked opens a new window using window.open. I need to send a integer back and put that number into a textbox (which is a .NET control). When I call window.opener on the popuped up window, I have to reference the ID of the textbox. The issue is, the ID changes from time to time if y...

Fast clicks on nav menu causing fadeIn of multiple divs

I'm having an issue with a script (my first try at jQuery) I wrote to fade in divs using a nav menu. If a user clicks different buttons on the nav menu quickly, it loads both divs over top of each other. Here is the code: $(document).ready(function(){ $("#about-button").css({ opacity: 0.3 }); $("#contact-butto...