How not to slice the links displayed in <p> element using jquery?
Hello all! I have a jquery code used to show more or less link for the comments displayed from my database. I noticed that this jquery code can't display the link properly that is queried from the database and some can display well. Some instances that the link won't display properly are as follows: 1.If you are entering long comments with several paragraphs and there's link in it 2. Mostly, if the link is located at the middle of the first paragraph, the link is not displayed properly. 3. If you
How to replace all href="http://www.Example_links.com" in html with generic "#" using jQuery?
I have a sample html file of a project which has the links of a certain company. example: <a href="http://www.Example_links.com"> How can i replace all the links at the same time with a generic "#" using jQuery? Please help . I tried using the Find & Replace All Option in DreamWeaver but since all the links are different and there are a lot of links, i was wondering if its possible to do the same using jQuery/ plain Java Script. Please help me with this .
iFrame inside another iframe using Jquery
Hi for all, In Scenario 1 I have an iframe that is created inside a div and it works well var tabs = $("#tabs").tabs(); var divTemplate = '<div id="' + id + '"></div>' var ifrTemplate = '<iframe id="ifr-' + uuid + '" src="' + Url + '"></iframe>' $(divTemplate).html(ifrTemplate).appendTo(tabs); In scenario 2 I have an iframe that is created inside another iframe. And all this inside a div, and it also works well. var tabs = $("#tabs").tabs(); var divTemplate = '<div id="' + id + '"></div>' var bodyTemplate
Selctor no more working
Hi, I just upgraded from version 1.6 to 1.10 ; there are things that are not working any more. Exemple : .myclass input:checked => not working .myclass input[type=checkbox]:checked => working ! but why ? Another issue: I have a div whose ID is "myid". In some case (it shouldn't but it happens) this div may be repeated twice. Applying $("#mydiv").remove() removes only one instance at the same time. I have to repeat the .remove() to remove all div ! Is there an explanation to these cases ?
Question: Filtering with Checkboxes
Good Afternoon, I am wanting to create my own "product filter system". Basically I want to be able to click on products to go to the products.php page, this will show all my products on my website. On the left some checkboxes like "Show by Brand" with a list of brands. If you check the box for 1 of the brands, it will edit the list of products to only show products for that brand. Then another one that shows "capacity". Say I clicked "Apple" for brand, then "32GB" for the capacity. This will then
Is it a bug?
When I enter 'ok',and then click the button, the alertdialog does not appear. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>无标题文档</title> <script src="jqueryV1.10.2.js"></script> <script> $(function(){ if($('#info').val() == 'ok') { $('#test').click(function(){ alert("You have tested successfully!");
questions in using sort()
When I sort the percentage column,there won't display the right results. Is the sort() method not applide to sorting numeric variables? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Sort</title> <style type="text/css"> tr{ font-family:Arial, Helvetica, sans-serif; font-size:15px; border:1px solid
Unable to get drop down value
Hi all, I am new to this implementing this in my asp.net website have master page and content pages .On master page have included the latest library <script type="text/javascript" src="jquery-1.10.2.min.js"></script> on content page this <script language="javascript" type="text/javascript"> $(function() { $("#ddlFreq").click(function() { alert("sd"); }); }); </script> <asp:DropDownList ID="ddlFreq" runat="server">
The complete function after an animate is launched more than once!
Hi... I want to launch a function after that an animation is complete. The problem actually is that this function is launched a lot of time without a reason! This is the code $('#fullWhite').animate({opacity: "1"}, {duration: 500, complete: function() { alert('cazzo')
jquery form disable and enable with another form
hii please help me ............ i have a login form, if i press the forgot password login form is disable replace with forgot form .. how can i do thisss........
Dynamic order rows in a table by id
Hi guys! I have a requirement to order rows in a table using Java Script (JQuery) My table is look like: <table> <tr id="3"> <td>C</td> <td><table><tr><td>Row C</td></tr></table></td> </tr> <tr id="1"> <td>A</td> <td><table><tr><td>Row A</td></tr></table></td> </tr> <tr id="2"> <td>B</td> <td><table><tr><td>Row B</td></tr></table></td> </tr> </table> And the final result is to be: A Row
jQuery method show
How to set 'display: block' by method jQuery(selector).show() without jQuery(selector).css()? Now this method setting 'display: inline'
Scrolling using keyboard does not work in autocomplete JQgrid
I am not able to scroll the Autocomplete list of items using keyboard down/up arrow. In my JQgrid i have a textbox with autocomlete functionality. When the auto suggestion list appears, I am able to scroll through the list of items using mouse. But the scrolling doesn't happen when I use Keyboard. Please Help. My CSS portion for auto complete is .ui-autocomplete { position: absolute; max-height: 200px !important; overflow-y:auto !important; overflow-x: hidden; padding-right:
[jQuery] Resolving Namespace conflicts
Hello, I'm planning to distribute my website's services to my clients using javascript, much like google map or ShareThis service. Basically my clients will include my external javascript file in their html header. I'd like to write my javascript code based on jQuery, but worrying about all those namespace conflicts. I have no control over what javascript library my clients' websites use, they may use prototype, mootools, they may even already use jQuery. What are the possible solutions to avoid
[jQuery] Move of namespace
It is possible to completely move a particular plugin namespace into other one? e.g. if (typeof Company == "undefined") { var Company = {}; } Company.form = {}; Company.form.validator = jQuery.validator; // Assume already loaded // Now I want to modify some of its internal value Company.form.validator.messages.required= "My Required"; // However, it is different from alert( $.validator.messages.required ); // Show the original value, seems only a copy of validator is assigned to Company.form.validator,
mousemove strange behavior in IE
Hi, URL: http://www.ximnet.com.my/jquery/mousemove.htm I try to do something like Google.com. When page is loaded, the div will fadein when user move the mouse. $('#html').mousemove(function() { $('#menu').fadeIn(5000); return false; }); It is working in Firefox, but in IE, it will fadein even if user do not move the mouse. Anyone know what is wrong? Thanks,
[jQuery] Tooltip with Lightbox
Hi! I've been using the jquery.tooltip with Lightbox, but the Tooltip 'steals' the title attribute value and the Lightbox can't show it! What can I do to solve this? Any suggestion? Have anyone had the same problem?
[jQuery] Specifying user agent with ajax
Hi, how do I go about specifying the user agent when I'm using ajax in jQuery? I've tried $.get("test.html", { data: 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv: 1.8.1.3) Gecko/20070309 Firefox/2.0.0.3' }, function(data){ $('#testDiv').append(data); } ); and $.get("test.html", { User-Agent: 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv: 1.8.1.3) Gecko/20070309 Firefox/2.0.0.3' }, function(data){ $('#testDiv').append(data); } ); but I don't think either of those are working.
SlideToggle on multiple divs to maintain state during postbacks
I have jscript to toggle divs to slide up and down. I would like to maintain the state of these divs (open or closed) during postbacks. I read on other posts I can use cookies and hidden fields, but I don't know how to use it when using multiple divs with my jscript. How can I maintain the state of the divs so that it stays open/collapsed during postbacks. How will I pass parameters to the jscript? Jscript: <script type="text/javascript">
$(document).ready(function () {
$(".toggle").slideUp(0);
Getting multiple images to fade in and out randomly.
Hi, I have a concept I want to develop but haven't been able to find a jQuery plugin that will do what i need. I am hoping if someone knows of a script or even to share if this is possible. What I want is to have about 10 small images to be displayed horizontally and have each of these images fade in and out at random times and being replaced by other images. I have a flash example that i would like to replicate that would give you an example of what i want to achieve. If you look at the bottom of
Jquery PDF Viewer Plugin with protection
Hi, Im Looking plugin for pdf viewer for my site, the issue here, most of the plugin like https://docs.google.com/gview are still allow the user to select the text. What I want is something like amazone book viewer, where user cant select the inside or download the pdf. Anyone knows? Thanks
White frames between div auto-refresh (only Chrome e IE)
After reading several interesting posts on this site, the auto refresh of a div containing an image, it works correctly. Why between a refresh and another I get an empty div? (in chrome e IE, for a short moment). In firefox next image is loaded instead of the current without empty div. The next image is already present in the cache since I do a preloading of the next image Thanks My code: <head> <script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"> </script> <script type="text/javascript">
Wrap every 3 divs in a new div
How can I wrap every 3 divs in a new div? So If I have; div1 div2 div3 div4 div5 div6 I need this to become; <div> div1 div2 div3 </div> <div> div4 div5 div6 </div> I also need this to wrap the last div(s), even if their are less than 3 so this; div1 div2 div3 div4 div5 div6 div7 Would become; <div> div1 div2 div3 </div> <div> div4 div5 div6 </div> <div> div7 </div>
[jQuery] How dynamically create iframe and add/remove data from it
Hi folks, hoping for some knowledgeable assistance with this problem. What I'm doing is dynamically creating an iframe in the DOM, then trying to write some data into it. That's the part I'm stuck at. I *am* able to create the iframe, no problem. I have a div with the id #container built into the page in which the iframe is added: $ (document.createElement('iframe')).attr('id','commentiframe').appendTo('#container'); At this point, I don't know how to write data into the iframe that has been created.
jQuery "selector" property deprecated?
Hello all, I understand that this property has been deprecated in 1.7. and still is? It's still widely used, very powerful and generic. I'm contemplating, whether to use it in my plugin... (at the moment, I don't depend on it) Obviously, if jQuery is serious about dropping it soon, there's no point in that, right? Or is there going to be a substitute / recommended workaround? Thanks in advance and kind regards
document.ready throwing Object Expected error
I have an ASP.Net Webform. On the webform I included a js file which contained a document ready function call. The file is located in the cpvfsScripts folder of my project directly under the root. The jquery min library jquery-1.9.1.min.js is located there as well. I wrote this application in October. It was working fine then. I made a couple of changes to allow me to use a library that used the "$" according to the guidance given at http://docs.jquery.com/Using_jQuery_with_Other_Libraries .
Click inside iframe open event in parent (same domains)
I have 2 files index.html and index2.html Index.html code: <!DOCTYPE html> <html> <head> <script src="http://code.jquery.com/jquery-1.4.4.js"></script> </head> <body> <iframe id="frame" src="index2.html">Your browser does not support iframes.</iframe> <div id="details" style="display:none;">Sliding details</div> <script type="text/javascript"> function showevent(){ $('#details').slideToggle('slow', function() { // Animation complete. }); } </script> </body> </html> index2.html <!DOCTYPE html>
getJSON returning empty array [] from properly formatted nested JSON object
Hi jQuery forum, I've been wracking my head on a weird bug for an embarrassingly long amount of time. Google's been of no help so I hope somebody can lend a hand. I have a PHP script that returns a properly formatted JSON object (I've validated it using JSONLint) that looks like the following: { "ID":"23", "LastName":"Moe", "FirstName":"Ronnie", "Orders":[{"OrderNumber":"1","ItemNumber":"1"}, {"OrderNumber":"1","ItemNumber":"2"}]} Pretty simple. But when I use getJSON to grab
[jQuery] namespace
How do I create a namespace within jQuery ? (function($) { var myNS = {}; })(jQuery); (function($) { $.fn.myNS.foo_1 = function(){ }; })(jQuery); (function($) { $.fn.myNS.foo_2 = function(){ }; })(jQuery); $("#id1, id2").myNS.foo_1(); $(".cls1, .cls2").myNS.foo_2();
Help with responsive-slider - random order
Hey, Recently downloaded the following slider which uses jquery: http://w3widgets.com/responsive-slider/ Really like the slider and want to use it on site however would like to make it have a random order function. I have tried to contact the developer with no response and would greatly appreciate any help with achieving this functionality. Thank you in advance Sam
wait until all images are loaded
Hi, i need some help here, I need my code to execute something AFTER all images are loaded, but I dont know how :(
[jQuery] Plugin: Mousehold
I've written a simple plugin that keeps firing the specified function while the mouse button is held down (i.e. a repeat action). Here it is: http://leftlogic.com/jquery/mousehold.js Here's a bit more detail on how it works - along with an example: http://remysharp.com/2006/12/15/jquery-mousehold-event/ Any feedback or bugs please let me know. Cheers, Remy Sharp. -- View this message in context: http://www.nabble.com/Plugin%3A-Mousehold-tf2828870.html#a7897334 Sent from the JQuery mailing list archive
[jQuery] Checkbox "checked" event
How do I detect if a checkbox is checked by a user? change or click would be wrong. Thanks
Retain checkbox state with refresh of page
I'm a newbie to jQuery, and I have what I thought would be a simple setup: 1) Have a list of checkboxes that show/hide content within a div tag 2) Have those checkboxes keep their checked/unchecked state with a page refresh in all browser versions I was able to accomplish #1 without a problem with the help of this jsfiddle: http://jsfiddle.net/nick_craver/VUeB7/ This code accomplishes #2 in Firefox, but the state disappears in both IE and Chrome whenever the page is refreshed. Does anyone know of
Inserting into MySQL without webpage refreshing
Hello, I am trying to post data to MySQL without having the webpage refreshing (the URL will not change when sending data to MySQL). I think I can do this using jQuery or AJAX. I believe this is the proper way to do this but it does not seem to work. I can get data inserted into MySQL if I use an action="insert_db.php" as part of the form but that will redirect to that webpage, that is, it goes to insert_db.php. I do not want it to redirect to any other webpage when it is inserting data into the
Hide mailto from Google with Ajax
Hi there, I used to 'protect' my email addresses from being indexed by Google in the following manner: $.post( '/mailto.php', { password: 'mypass' }, function(data) { $( 'span.email' ).html(data); }) mailto.php would return <a href="mailto:me@example.com">me@example.com</a> This used to work fine until a while ago: Google is now able to (partially) read Ajax loaded content. Could anyone advice me on what new method i should use for protecting my e-mail links? Thanks in advance! Regards, Knal
Loading html from external file into div
I'm fairly new to jquery so apologies if this is a very simple question with a very simple answer, but I just can't figure out the solution. I have an overlay div, and when I close the overlay I want to remove the html inside it and then re-load it from the specified file. I have already worked out how to empty the div, but what I now want to do is re-populate it with the content from a separate file on my web server. Here is my sample code: onClose: function() { $("#video-popups").empty();
animate (moving) while fadingIn
Hi there, I wonder if its possible to animate an Object while at the same time fading it in. At this moment I am able to do it after each other but not at the same time. Hope you can help me.
[jQuery] [autocomplete] - IE 6 Scroll bar problem.
I have been looking at JQuery autocomplete and just when I thought it would meet my needs, I found a bug on IE 6. This is the problem. 1. Enter something in the text box that provides suggestions 2. Let the suggestion list appear with scroll bars. 3. Use the scroll bar to scroll down or up (this step is very important) 4. Now click on anywhere outside the suggestion list. Ideally the suggestion list should disappear but I see that the suggestion list just sits there unless you select something from
jquery dashboard gauge
Hello does anyone know of any jQuery dashboard plug-ins or widgets. I don't want to use Google's because gauges in the visualization api don't work in mobile safari as of yet. Any suggestions. I have seen bindows, but I would like something only in jQuery. Thanks, Brian
Next Page