jQuery - Internet Explorer 8 - Error
Hey all, im stuck on a problem using jQuery on IE8. I get an Error on Line 74 Character 424 (jquery.1.4.2.min) "The Object does not support this method". (FF is working as expected without error!) My JavaScript is: //This is working $('#content').append('<h1>Content added by jQuery - JavaScript!</h1>'); //This not //When page loads... $(".tab_content").hide(); //Hide all content $("ul.tabs li:first").addClass("active").show(); //Activate first tab $(".tab_content:first").show(); //Show first
Animating the div's height with animate() fails
I've got a problem with animate() that isn't animating the height attribute properly ... no idea why. I've got a picture gallery with text description below the pictures. I reduced the div hight of the container that's containing the gallery (#Gallerie) to hide the text area and showing only the pictues. Theres a button (Resize_Gallery) to resize the div containter to full size and shrink it again. But the animation doesen't work like it should. Instad of a smooth vertical movement it partialy moves
Returning an embed movie object
I have an object-embed combination for a flash swf file. I have added javascript controls for the movie. I am successfully using the following in a function to access the movie and send the javascript commands: if (window.document[movieName]) { return window.document[movieName]; } if (navigator.appName.indexOf("Microsoft Internet")==-1) { if (document.embeds && document.embeds[movieName]) return document.embeds[movieName]; } else // if (navigator.appName.indexOf("Microsoft
Problem of setting offset in IE/Chrome
I am using jQuery 1.4.2 and I get a strange result when setting offset in IE/Chrome. I have a jQuery Object "obj" which position style is absolute, Originally, obj.offset() will return { top: 224, left: 31 } Then I run obj.offset( { top: 353, left: 122 } ); In Firefox, it works perfectly, obj.offset() return { top: 353, left: 122 }. However, in IE/Chrome, obj.offset() will return { top: 224, left: 31 } But then, if I run obj.offset( { top: 353, left: 122 } ); one more time, IE/Chrome will give correct
Images are not displayed on jqgrid
Hi All, I created jqgrid with array data and it is working fine but images are not displaying on grid. Added below code jqGrid. imgpath: "themes/showcase/images", Can you please let me know I need change the path in other files. Thanks & Regards, Rajasekhar
Looking for popup/modal/iframe solution
I'm developing a simple shift schedule making program. I have a grid of divs each representing a potential shift. For speed and simplicity, I'd like a simple form to appear after the user clicks on a div. Once the user submits the form I'd like the tooltip/form dialog to disappear and the original page (grid) refresh.
AutoComplete using several fields?
I'm looking for an AutoComplete that can make suggestions(dropdown) from several fields like business name, street address, city, State, and phone number. Another words enter phone number get business name and the rest of the fields I mentioned. I see where jQuery's AutoComplete will do one word, but can it be configured the way I need?
Issue with Show/Hide on hover (or mouseover/mouseout)
Hi, I have an issue with a show/hide effect on a menu (list based) triggered with a hover event. Here is the part of the HTML : <div class="somm"> <ul> <li><a href="#tech">2. Aspects techniques</a> <ul> <li><a href="#gmapi">2.3. L'API JavaScript Google Maps</a> <ul> <li><a href="#gmapipres">Présentation et « initialisation »</a></li> <li class="parent"><a href="#gmapiprem">Premiers
jQuery animate problem
Hello there, I'm using the jQuery animate() function to expand a div to a certain size. Please first check this link to see the problem. http://bit.ly/d451YB You see 2 divs, the meaning of the divs, is when you click on them they will expand to another size. The problem is, that the div on the right, expands to the right, and not to the left. The first div is correct. I saw that you can use the CSS selectors (bottom, top, left, right) to set that direction, but when i use these, the div is placed
ajax post success question
Hello, My problem is that I want to run an external function outside the post. This is what I have currently. $.ajax({ type: "POST", url: "<?php echo site_url('bid_builder/save_add_cost') ?>", data: dataString, success: function() { setGrandTotal(); } });On success of the post I want to run the setGrandTotal(); function which will do some calculating for me. Can this be done? Thanks for any help on this.
Need help with jQuery
Hello, First of all, I'm new to jQuery. I have made up a small code with js which shows and hides description box, but it doesnt work in IE. So i decided to write it in jQuery to make everything work. When I startet to go into jQuery, I realized that it would take too much time. Can someone help me write it in jQuery? JS: function show(obj,msg){ messageBox=document.getElementById('messageBox'); contents=document.getElementById('contents'); messageBox.style.top=obj.offsetTop+"px";
Why jquery post() doesn't work with base tag?
Hey, ive got a post() function on my code, and also base href tag, its giving me error access denided... why? <base href="..." /> בניית אתר אינטרנט
children() order?
Hi, In what order should the elements in children() be returned? I assumed it would be the top-down order in which they appear in the source (or added to the DOM). Then children() would just do a breadth first search and return the elements in that order. I'm finding, however, that Firefox and Chrome actually return in different orders. Firefox seems to follow the order as described. Chrome seems to do it in reverse. Is there any guarantee on the ordering at least at the browser level? What
Loading a Random <a> Class
I'm truly sorry if this is the wrong location to post this question, as I wasn't able to find a plugin that does what I'm hoping to do. Please take a look at the little diagram to (hopefully) help understand my question. I am building a site that is utilizing a lightbox-type plugin to display a gallery of images when the user clicks image A, B, C, etc. However, what I would also like to do is set up the main content area (area '1' above) to load a random image from the row below (A, B, C, etc.) each
before() works in everything but Chrome
Part of my site inserts points selected from a Google Map after the user clicks the submit button. It will loop through an array of points clicked and add each one as a hidden form value then submit the form. This works great in IE, FF, and Opera, but doesn't work in Chrome. Here's the bit of code that's running: $('#reviewRoute').click(function(){ for (var i = 0; i < nextMarker; i++) { $('#hiddenValues').before('<input type="hidden" value="' + markerArray[i].getLatLng() +'" name="coordinate' + i
Chat Problem/Question
Hi, I wanna code a chat. My only problem is how a user know if someone sends him a message. i mean: user a is surfing on the website an user b is sending him a message. how can i code sth that says to user a that he get a message? thanks a lot!
jQuery, JSON, Progress Bar and PHP...
Dear all, I am trying to do the following: I have a PHP page with a determined number of loops, however the number of loops is huge. I need to create a progress page with jQuery, AJAX and JSON. Unfortunately, the code that I wrote re-starts the page as it visits it every 1.5 seconds. How will the PHP page update the JSON object on the fly, in order the getJSON part to run appropriately? The code is: var i = setInterval(function() { $.getJSON("call.php?catId=14417537", function(data) { if (data ==
Using $(".div-with-class")[my-variable]
Hi, I've got a gallery and want to blend in / out the elements specified by a link parsing the element-position to a function. function showImageByPosition(position) { $(".div-with-class")[position].show(); } As long as "position" is written hard coded as a number, it works. As soon as I want to use the parsed variable, it stucks. Has anyone an idea? Cheers, Mario
Please explain How to use "this".
I do not know how to use "this" as listed below. if($("+dd",this).css("display")=="none"){ (***) } Could I have a simple explanation for learner? Thanks.
Animating css3 transforms
Hello! is it possible to animate eg. -moz-transform: rotate(90deg) ? I tried something like: $('div').animate({ '-moz-transform': 'rotate(90deg)', '-webkit-transform': 'rotate(90deg)', '-o-transform': 'rotate(90deg)' }), but it didn't work. $('div').css( ... ) of course works.
How to shuffle list items in an array on refresh
Hi everyone, I want to create an array of list items that will shuffle randomly when a user refreshes the page. I also only want to display 3 items at at time, but when the browser refreshes it will show 3 random ones each time. I've seen shuffle plugins, but they work if someone clicks on a button to shuffle the items, which I don't want to do. I want it to shuffle randomly on reload of the page. Can anyone help me with what I'm trying to do? I'm not that great at using jQuery, but I'm learning.
Select OnChange Question
Ok, I have a select input in a form, and each option in the drop down needs to have a different set of form fields displayed. How would I set up the coding for this? I am pretty new to jQuery...so any help is much appreciated...
Problem with ajax call in version 1.4. Error callback not called
I recently migrated from jquery 1.3 to version 1.4. I am using Ajax to get the results from a php backend file. When the networkconnection is not available (no internet-connection) i normally got a error callback. As of version 1.4 I however get a success callback (with emty data). This causes my application to function abnormally :( Does anyone know why this is currently the case? I noticed that some JSON handling is more strict, but i don't see any reason for this behaviour. Can anyone shed some
Jquery toggle code only works in IE , but not Chrome/FF
Hi guys, i have some jquery code that shows and hides some content. but it only works in IE but not FF or chrome. Can anyone please help me with that? <div class="critical"> <div class="rec"> <div class="header"> <a><img alt="open this item" src="/images/rec.png" /></a> <h3>Know your break-even point </h3> <a><span class="more">more... </span></a> </div> <div class="content" style="display: none;"> <div class="reportIntro"> <p>You need to understand how
Adding an attribute to an HTML tag
Hello! I'm trying to find a way to add an attribute inside an anchor. I want to do this is because that attribute is required by a script I have running on the page, but it is not valid. Just so it makes more sense the code looks pretty much like this: <a id="previous" control="-6" href="#"></a>and I would like to add control="-6" inside <a> via jQuery, only I don't know how.
How to get document & body of a newly created iframe
Hi, I'm stuck on this and can't find a solution on the web which works in all browsers equally. There must be a standard way of getting the body of an iframe, and adding content to it, using jQuery. Can someone advise please what the "best practice" way is? That works in all browsers?
Showing/Hiding array elements
If you want to see what I'm talking about at any point, go to http://DanHakimi.com/works.php and hit the "web" button in the top-rightish area. Or, you know, check the source code, because you can't see any of that stuff right now. So, I'm working on a portfolio for myself. And I want to make it for myself, because, well, I don't want to be lame. But I do need some help in figuring out what's wrong... My portfolio has three parts: stuff I've designed on the web, stuff I've written, and other stuff.
Access computed value of a CSS property?
Is there a way using jQuery (or a plugin) to fetch the computed value of a css property? Specifically, I'm interested in getting the computer value (ideally in pixels, but any unit will do) of an element that hasn't had its line-height explicitly set with a CSS declaration. Thus, calling $(element).css('line-height') in jQuery returns the string "normal" which is of little value (at least to me in this context). Can I get a numeric value that the browser has elected to use for "normal" somehow?
wrapAll() around HTML that contains script tags executes referenced JavaScript twice
Test case: http://jsbin.com/ujico3 I can't see how this could possibly be the intended behavior. I was able to fix this for myself by filtering out script tags [using .not('script')] before calling .wrapAll(...), but it took me about a week to hunt down the root cause of why some of my JavaScript was executed twice.
Rubic Cube and Jquery
Hi, my name is Johannes and I just started to work on Jquery. I'm interessted in programming a rubic cube in Jquery to display pictures or other content. Now, the topic of the discussion is, what do you think could be interessting, maybe other projects working on the same topic, useful Plugins whatever comes into your mind. Let me start first: I think i should use the JQuery Cube Plugin( http://keith-wood.name/imageCube.html ) for each part of the rubic cube to get it flipped correctly. But I think
Help required with Datepicker
Dear jQuery friends, I'm absolutely without any programmening experience but I urgently need at calendar/reservation function on my website. The website is a joomla CMS based site but I can manage to make custom moduls by simply inserting code into the module. What I need is a simple "page" or code with the following functionality: 1) A "From" input with the small calendar icon on the side Rule required: It shall not be possible to select any date prior to current date. 2) A"To" input with
Ajax url base
Hi I keep all my ajax files in one folder on the server. Previously I was using my own ajax function in which a "WEB_AJAX_PATH" is defined pointing to the ajax root folder. So a typical ajax call was something like. getAjax("file.php"); and the getAjax function will call the url WEB_AJAX_PATH + "file.php" Now in JQuery I am not able to find any setting for this. one way to do this is to add WEB_AJAX_PATH in all ajax calls itself (which seems a bad idea) or write a function which will add WEB_AJAX_PATH
length >= 6 does not work but length >= 5 or lower does?!?
I am trying to do a check on two password fields. As you can see below, I am doing an if satement on keyup to verify the fields are the same, and if so append a green checkmark. Problem I am running into is on the if statement line #6 below, where I have : $j(pw1).val().length >= 6 &&When set to 6, and I put a six digit password into the confirm password input box, and shift tab back to the initial password input box, the image disappears. Upon tabbing out of password back into confirm password
Click events not allowing 2 function to work together, what am I doing wrong?
Hi, I'm relatively new to JQuery and am having troubles trying to get two functions to work together. I have a pagination function and a modal dialog function. Each one is triggered by different anchor tags. My troubles happen whenever one function is triggered, the other function can not be triggered anymore. If I trigger the modal dialog, the pagination function can't be triggered, and when the pagination is triggered first, the modal dialog no longer triggers. I've tried to use .die() and .unbind()
Need help with scrolling to a certain div
Hi, I have html like this: <style type="text/css"> #TourDetailItineraries { height: 500px; width: 400px; overflow: auto; border:1px solid #333; } <div id="TourDetailItineraries"> <div class="ItineraryAlt" id="TourDetailItinerary1"> </div> <div class="Itinerary" id="TourDetailItinerary2"> </div> <div class="ItineraryAlt" id="TourDetailItinerary3"> </div> <div class="Itinerary" id="TourDetailItinerary4"> </div>
Relocate click action to bind('hashchange') function
How do I replicate this click action within a bind('hashchange') function ? $("#menu > li > a").click(function() { $("#menu > li > a.expanded") .not(this) .toggleClass("expanded") .toggleClass("collapsed") .find("+ ul") .slideToggle("medium"); $(this) .toggleClass("expanded") .toggleClass("collapsed") .find("+ ul") .slideToggle("medium"); }); Trying to relocate it within this code, so that when clicking back | forward within a browser, the menu changes accordingly to highlight the current page. $(window).bind('hashchange',
How to move a zoomed image inside a div?
I have used draggable, and yes, the image can be moved by the user inside the div. when using the containtment:'parent' the image can not get out of the parent div,BUT I need some more functionality than that: In my app the image can be zoomed out / in When zooming out the image can grow more than the parent container then I need: 1. the image can keep growing with out affecting the dimensions of the container 2. the draggable function should still be usable so the user can see the rest of the image
Multiple Show/Hide Layers
hi there been banging my head over this for a couple of days, some help much appreciated. i'm trying to create a solution for multiple popup layers that extend over the fantastic layout UI plugin, so the absolutely positioned popup divs ideally need to sit outside the document flow and as a direct child of the BODY tag so they don't conflict with the jquery generated layout. all the "cluetip", "qtip" plugins just dont work for me so i've gone back to basics with andy langton's show hide. ------------------------------------------------------------------------------------------------------
JQuery and activex error on IE
Hi guys, i recently use jquery with a simple html page. In that page is not embended tags or something like that, i dont have swf files, is pure html. with jquery or not, when i use write.document an activex popup appear. many sites use javascript and this issue doesn't appear. cand help me someone to bypass this issue. Sorry but i fill i go crazy. PLEASE HELP ME.
document.ready extremely delayed by banner ads
Hi, this should be a basic issue, so I was wondering why I ran into it and couldn't find a solution so far: My page uses different ad tags to display banner ads. I have no influence on the tags, they may very well deliver all sorts of nasty document.writes within document.writes and so on. So far, I was initializing all jquery functionality via an init() function just before the body, like so: ... <script type="text/javascript">init();</script> </body>. This worked very fine. No issues, and jquery
Next Page