Width of div using css('width')
Trying to get width, for simgwd (line #5), but keep getting NaN. I believe something has changed w/ jquery 1.8. Can someone explain how I'm supposed to write this. $('[id^="order"]').each(function() { var simginitdisp = $(this).filter('[class^="searcher_stack-its_img"]').css('width'); var simgwd = parseFloat(simginitdisp); console.log('Search Img Width: ' + simgwd); if (simgwd > 0) { console.log('Search Img Present'); var contwd = $(this).next('[class^="searcher_stack-its_stacks"]').outerWidth(true);
Link within a clickable div.
Hi guys, I have a clickable div. Within this div is some text. I made a link at the and "- read more -" which shows extra text and hides the previous text. When this link, which is inside the div, is clicked I dont want the div to respond to the click. I used "event.stopPropagation();" for that. So far so good. However after you clicked on the link and the extra text is shown I dont want the div to react to clicks anymore. Since this would trigger the original text to be shown. I hope you understand
Can't get jQuery working with JSF2.1
I can't seem to figure out how to get jQuery to work with JSF2.1. Any solution I find seems to send me head first into another roadblock that I honestly don't even know which problem I'm trying to fix anymore. I've tried to get around issues involving JSF prepending, XHTML CDATA, using external javascript files, and some other failed attempts I can't even remember. If anyone could provide me with a basic example of a JSF2.1 page with, say, a button that executes .mousedown(), I would greatly appreciate
Toggle jQuery function onload code behind asp.net
I have inherited a project that uses jQuery and I am really not familiar enough with it to figure out how to change this to do what I want it to do. I am currently coding in ASP.NET (VB) and I have a working fully functional jquery function to toggle a slider and change a class. The class more or less just switches the image on the button from "Show Text" to "Hide Text" and then expands the div to show the text inside of it. All of that is good and well and works fine. Now, during the page load
Problem with use of .parents()
I've the following situation <table> <tbody> <tr> <td> <table> <tbody> <tr> <td><a class=little></a></td> </tr> <tr> <td><a class=little></a></td> </tr> </tbody> </table> </td> <td> <table> <tbody> <tr> <td><a class=little></a></td> </tr>
append div + var increase
Hi everyone I am having some trouble figuring out why my script isn't working. What I want it to do is add <div id="img*VARNUMBER*"</div> to my html, when I hit the bottom of the page. I don't know what is wrong at the moment, so hopefully one of you would care to clarify :) Thank you in advance. my code looks like this: <html xmlns="http://www.w3.org/1999/xhtml" > <head> <title>Detect if User Scrolled - DevCurry.com</title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.3/jquery.min.js">
FlexSlider
Hi I'm new to Jquery and I would like to ask for some help. I have begun using this slider (http://www.woothemes.com/flexslider) on my wordpress site. I would like to know if some kind soul could tell me how to set up the slider to only apper from the right side of the screen. Better explained - First I want to slide in a Backgroung Image from right to left and only when the entire Bg in visible do I wan't the slider to slide in from right to left. I appreciate all the help I get. Thanks in advance.
dialog won't display theme css images
http://pearlwood.com/dialog/dialogTest.html a working dialog without any images or modal overlay image I have been working on this for a long time. I have been told the css referencing is wrong and that I need to to step back one directory level before looking for the images like this 'background: url("../images/ui-bg_h' but this fails as do may other attempts at referencing the images folder. I think there is something else going on but I can't find it. Please Help
Retrieving JSON objects from another page - Questions
I want to retrieve a JSON object from another page using either the ".getJSON()" method or the ".ajax()" method with a "dataType:json" parameter to retrieve the JSON object. When the request to retrieve the JSON object is executed how will it know where to find the JSON object? I've not seen an example that shows exactly how the JSON object needs to be stored or placed on the original page which will be generating it. Does it just look for the first or all JSON objects that it finds on the target
adding scripts and css
scenario: an app with five pages: does each page require the javascript and css declarations in the head section? or declared only once in the head section of the index page?
question about sortable('serialize')
when i do var order = $('#' + strElement).sortable('serialize'); i get dragPanel[]=122&dragPanel[]=123 the result i would like is a string = "122,123" any ideas?
Adding sort functionality to image drag and drop
This post is an edited version of my original one. I've got an image drag and drop piece that displays a thumbnail gallery (div of #thumbnails). Then the user can drag and drop them into a viewer (div of #viewer) area where they will auto-expand. I just modified (maybe butchered is a better word) the jQuery UI simple photo manager code. That was just fine until the new requirement of being able to sort/rearrange the images in the viewer area came about. I am having difficulty envisioning how
Problem with the scrollbar and animation
Hello friends!!! I'm new in this fantastic world, so I don't have knowledge about this language, but I'm learning about it in a TAFE institute. I'm doing a page with teachers from another course. They have knowledge about jQuery language, but they are too busy with another course and their affairs. The case, is that we have problems with the scroll's bar and the animations' visualization. It's like vibrations in the animations when you move the mouse on the scroll bar. You can see this problem in
Problem with Control in Repeater (asp.net ) control and jQuery
I have a link shown in Repeater control... on click of it i want to get data of that single row and add that details to another div using jQuery... any help
.html() & setTimeOut
Hi, This is the scenario I want to create, Right now I want to do a timer effect. So I calling Timeout function if the condition is true. obj will minus it values and use .html(obj) to display. However, right now the timer wont update by itself. Am I using .html() correctly? I try empty first before using html but wont works $(document).ready(function() { setTimeout(function(){ Ajax(); },1000); function ActiveTimer(obj) { obj--; $('#item1').html(obj); }
Chrome and problem with Jquery script
I have a script that runs just fine in IE but will not work in Chrome, i am a jquery novice and forgive my messy code but i am at a stage where it works ;-) Just need to know why it doesn't work in Chrome??????? <!-- jquery script for calculations --> <script> jQuery(document).ready(function(){ $('.salesqty').blur(function () { var sum = 0; $('.salesqty').each(function() { sum += Number($(this).val()); }); $("#totalqty").html(sum); $('.salesval').blur(function () { var sumv
PHP form not submitting with or without Ajax
My form doesn't seem to submit. Here are some things I've tried: 1. data-ajax="false" in the form tag 2. jQuery 1.2 beta 3. removing all data-role="page" instances 4. dropping in a different form that worked in another project 5. dropping this form into another working project What am I doing wrong? The form is located here: http://www.timbartel.com/cursillo.php#sendpalanca Page PHP/HTML: <!DOCTYPE html> <html> <head> <title>The Cursillo</title> <meta name="viewport" content="width=device-width,
$.getJSON() Usage
I'm trying to use the ".getJSON()" method for the first time and so far I'm not getting anything out of it. I know the callback function for it is supposed to be called when the call succeeds, but can I also code an error callback function for it, or instead of doing that should I just use the more general ajax method and then code callback functions for both success and error, and make the dataType JSON? Thanks for the help.
getJSON() Problem
Do I need any new plugins in order to use the ".getJSON()" method in Firefox? Currently I'm trying to pull back JSON data from a target and the following statement: ${esc.d}.getJSON(targetUrl,function(jsonData,status,xhr) { alert("JSON-DATA=("+jsonData+") !..."); } ); is apparently not working because I do not get an alert when I run it.
How hide/display text
Hi guys, I'm a bit stuck with displaying and hiding text. I created a div which when clicked on expands and moves. Now I want the text that I put in this div to only be shown when the div was clicked upon and thus expanded. I thought I could do this by setting the text like this; <div id="box"> <text style="display: none">Here comes the text..</text> </div> <script> $("#box").click(function(){ $("#box").animate({ width: "500px", height: "300px", borderWidth: "10px", top:
How to send data through headers to restfull web serives
how to send the data using header , i followed the below code but it is not working and not getting error in console also type:'POST', datatype:'json', url:rootURL+"HashValue", data:jsonData, beforeSend: function(jqXHR) { jqXHR.setRequestHeader("test", "test auth=" + token); }, success:function(data,textStatus,jqXHR){
Can't get pageinit to work (despite reading doc + forums)
I know a lot of people have asked similar questions, but there must be something I haven't grasped yet... I took the helloworld.html example provided in the tutorial and added a response to the pageInit event. Here are some of the calls I tried, all in vain: <script> $(document).live("pageInit", function(event) {alert ("inside pageinit");}); </script> or <script> $(document).bind("pageInit", function(event) {alert ("inside pageinit");}); </script> or <script> $(document).on("pageInit", function(event)
Hide and show various divs
I've got the following code. How to create a certain click function which shows just the div according to the link I've clicked on, the others should be hidden. I've already tried to get the rel attr, saved it into a variable, that didnt work. var rel = $(this).attr(rel); $(rel).show(); $(rel).next().hide(); <a href="#" rel="one">One</a> <a href="#" rel="two">Two</a> <a href="#" rel="thress">Three</a> <div id="one></div> <div id="two">/div> <div id="thress</div>
$.post and load target page
I currently use .append to create a form with hidden fields dynamically, and submit it. however i would like to use $.post instead like $.post("http://www.google.com", { name: "John", time: "2pm" } ); but i need to load page the data was sent to just like a normal .submit but i am not sure how to do this? if anyone could help it would be much appreciated. Script I currently use $('#PaymentBox').append('<form name="PayMent" id="PayMent" action="' + url + '" method="GET"><input type="hidden" name="Aount"
having trouble with multiple jquery on a single page
Hi, i´m really new with this, and i have found on the internet different features created using jquery, but when i try to implement them on a single page they stop working, I suppose there´s a problem with the version of the jquery.min.js, but i don´t know how to fix it, could someone please help me with this?
Form Validation - Focusing/Updating/Sending
Hi Guys, I am new to jQuery and I am utilising it to try and improve a small business website I am making. I am currently validating a webform which is going great. I have surprised myself how quick it was. I am writing the code in a ('body').append function. Which is working in general however when the users leaves a field using the mouse pointer or tabs (to a checkbox) it does not validate. Tabbing from a text box to a text box does validate :P This has completely confused me haha Summarise Question
How jQuery works as a Client-Side language?
Hi, I new to Javascript and certainly new to jQuery. I having trouble understand the concept of jQuery as a Javascript framework. I know that the jQuery framework is a list of precompiled Javascript object function and it has it's own object function "jQuery" or the alias short-sign "$" to access jQuery "library" or methods and in order to use jQuery, we need to download the libraries, is it right? So how does it interpret in Client-Side? I know that Javascript had already implemented in the browser
Remove script from memory
default.html <div id="content"></div> <script language="javascript" type="text/javascript" charset="utf-8"> $(document).ready(function() { $("#content").load("include1.html"); }); </script> include1.html include 1<br /> <span onclick="alertMsg()">click to alert</span><br /> <span onclick="loading()">load new page</span> <script> function alertMsg() { alert("ok"); } function loading() { $("#content").empty(); $("#content").load("include2.html"); } </script> include2.html include 2<br /> <span onclick="alertMsg()">test
Confused by custom downloads and layout of jQuery files.
I should start by saying Im not a front-end developer but Ive been forced to dive into JS and/or jQuery code to tweak the UI for our web app. Looking in our js folder it seems to me there is a mess of disorganized folders and JS files including jQuery and jQueryUI stuff. There seem to be several versions of these files which just add to the confusion. Also it looks like we have several custom versions of these files and no way of knowing which features were picked for the custom downloads. So, in
Create a simple shopping cart in jQuery for .NET
Any suggestion where should one start for making a shopping cart in jQuery...
Very basic question on .css() as a setter
Hello everyone, I'm a complete beginner. I hope to be clear in what I am going to ask. I need to modify an existing mixed html+PHP page containing a login form. What I want to achieve is to signal a bad login attempt through a message in a <span id="error">sometext</span> element. I think that it should be hidden when the page loads so I've put $(function() { $("#error").css('display','none'); }); into the body of the page before the <span> element is encountered. Than, on
JQuery newbie - Trying to use two plugins together - Hiding and Unhiding multiple divs
Hi everyone This has been tying me in knots for days now and I assume the answer will be fairly straightforward! I have a website which has many bird photographs and updated it recently to use the Gallerific JQuery plugin. This works very nicely alongside the existing php & MySQL setup. I really want to implement a photo rating script to enhance the site and started trying to implement the JRating Star script. With the nature of the gallery plugin, an array of thumbnails is displayed and clicking
Selector with context?
jQuery n00b here... I was going over some code, and was wondering if someone could explain part of it: $.getJSON('/functions.php', { get_param: 'value' }, function(data) { $.each(data, function(index, element) { $('body').append($('<div>', { text: element.name })); }); }); My question is with regard to: $('<div>', { text: element.name }) My understanding from the docs is that is a selector with a context. How exactly does this work/what is it doing?
Show jSon data in unordered list
i get json data as below {"d":["Rice","Hyderabadi"]} i want to show it in ul li * Rice * Hyderabadi any help
Jesús Beltrán
Desde que descubrí lo fácil e intuitivo que es manejar jQuery en sus diferentes plataformas la vida me a cambiado completamente, esto a revolucionar el mundo web. Les comparto mi sitio www.puntografito.com actualmente estoy trabajando en el, tanto en la interfaz de escritorio como el la móvil. Saludos PD: Gracias jQuery por existir
Hobbiest newbie, how does this guy do it?
So I am just learning jQuery. I know a little programming (java and python) due to my job, but I am very new to HTML CSS3 and jQuery. I visited this site: Soulwire.co.uk and I want to be able to create a site like that. I love all the interactive elements and how things slide and animate. Can I do this with jQuery or do I have to learn some sort of other javascript library? Another question: When you click on one the menu times on the top of the page (Experiments,Stream,Nodes) it takes you to
Referencing Div's Loaded From One External Page To Load Them With More Data From A Second External Page
I have a table on a page into which I'm loading a list of TR's with links and with div's from a table on another page. The links all have names and unique identifiers associated with them and within each of them is a div which also has a unique identifier (the id attribute) associated with it. Now this list loads and displays fine on my original page. When I click a link on the list another JQuery request to another page is issued passing the name to the target page as parameters. It's supposed to
superfish conflict with dreamweaver tabbed panels in IE
I'm having a weird issue where if I mouseover the superfish menu and immediately after mouseover a tab in a dreamweaver tabbed panel the content within the tabbed panel disappears. But only in IE. I thought it might be an issue with the relative positioning and tried fooling around with z-index on both the .sf-menu ul and sf-menu li. It fixed the issue but now the submenu doesn't overlay everything on the page. I've tried making a z-index as high as 1000 but it still doesn't work. Any suggestions?
Fire Fox not Displaying pagers correctly
Need help with a css hack for firefox browers.15.0.1 version This is the screen shot that works in all browers accept firefox. This screen shot is from firefox as you can see the last Button is partly coved with the header called Our Packages This is the css that place's the header called Out Packages under the row of buttons #packagesheader { position: absolute; top: 163px; margin-top: 60px; /* 60px or 6em works in all browers but not firefox the header for Our packages does
Yet another "Show More" question...
I've successfully configured a DIV to display upon clicking a hotspot. It's awesome!!! Inside my pop-up DIV, I would like a paraphraph to display more text when "more details" is clicked. Additionally, I'd like "More Details" change to "Hide Details." Clicking "hide details" would hide the text. I've gotten Toggle to work in a clean page, but I can't get it to work inside my code below (highlighted in yellow). Thoughts? Micky CODE **********************************************************************
Next Page