defining inputs and classes
Assuming this markup: <div class="editor"> <div class="operations"> <input type="button" value="Display" /> </div> </div> What is the difference between these 2 lines? Do the refer to the same button or does the first one refer to the whole .operations div?: $(".operations").click(function () { $("input.operations").click(function () {
Putting scripts inside a query string
Sorry if this is a bit vague but How do I put an existing Script string inside a $("div).html(Script) This is what I have tried but it all goes wrong after the </script>"); and displays all the content for the rest of the script in text else if (myDay == 1 && myhour >= 11 && myhour <= 17) { $('#chatButton').html("<br><script type='text/javascript'>if (typeof sWOTrackPage == 'function')sWOTrackPage();</script>"); } Thanks
Is there a way to capture the text in $('#am-container').append( html );
I would like to capture the text in $('#am-container').append( html ); so that I can directly insert the html text into the html page for debugging. An Alert() does not provide for copying/selecting. Suggestions welcomed... Todd
Remove hotspot outline with jquery?
I have an outline that appears around my poly hotspot, but outline:none isn't removing the outline. Because this runs on an intranet, we don't have to worry about accessibility. Here's a simplified version of the page code. As you can see, I even tried to fade out the image with the hotspot before loading the hidden div on top. It just fades out the image but keeps the hotspot outline. It made me laugh the first time I saw that happen. <html><head><title>ribbon</title><meta http-equiv="Content-Type"
Correct syntax for jQuery inside an 'if' statement?
Hi folks, I'm new to javascript, jQuery and the forum - so this may well be a stupid question... The following script allows a control with ID = 'next' to move through a list of sibling elements (class = 'ListItems') by controlling which ListItem is allocated ID = 'vis'. The script works until the visible ListItem is the last element. So, I introduced line 4, which attempts to prepare the first ListItem to be the next to display, when the current visible item is the last in the list. But the syntax
Javascript even css not work after ajax load page
Sometimes some page's javascript even css will not work if I use ajax load page, anyway to prevent that?
The CSS is not applying on the device.
I am new to this and would like to know about the steps required to use jQueryMobile in the Android application. I have downloaded jQueryMobile and included min.css and min.js When I run the application on emulator with API level 15 it is showing the web page well formatted.But when I run it on actual device with API level 10 it does show page without CSS
showpage event doesn"t work on phonegap
Hi, I'm using showpage event, and it works fine in my web browser, but when i load the html page into android using phonegap, the trigger doesn't work. $('#page6').live('pageshow',function(event){ alert('page6'); }); anyone have an idea why? Thank you, Guy
Vertical slideshow
Hi all, Im a jquery newbie. Im using jquery plugins most of the time when needed in the websites that i am developing. I currently have a problem with the one i am working with. It's a slideshow with vertical tab. I looked at some plugins but won't fit the supposed requirement of what I am doing. This is how the template goes. The grayed part is the selected thumbnail and on the other bigger part with white background is where images are loaded once the thumbnail on the left are chosen. Then it should
pushStack workflow in jquery
pushStack word flow and example
while scrolling flexi grid data is disordering in IE8
I am using MVC 3 , .Net 4.0, Razor Technology . while Flexi grid Scrolling data is disordering in IE 8 but working fine in Firefox any help..
jQuery's tolerance on the dirtiness of html files
I wonder how dirty of an html file jQuery can tolerant and still produce correct result in selecting, traversing, etc? Does it require the html file having a perfect well-structured DOM?
.click only after alert?
I have multiple same iD's am try to get a 'rel' after click HTML: <div class="konf_img_container_wrapper"> <div class="konf_img_container"> <div class="konf_img_thumb_xs"> <div> <img src="useruploads_thumb/thumb_temp_54_505f0f8866d55.jpg" rel="10"> <span id="remove-image" class="remove-image"> <span class="ui-icon ui-icon-trash"></span> </span> </div> </div> <div class="konf_img_thumb_xs"> <div> <img src="useruploads_thumb/thumb_temp_54_505f0f9bf23b8.jpg" rel="11">
jQuery validation dataFilter returns custom error message from servlet
Can somebody please help, I use simple java servlet and jquery validation remote and dataFilter to show a custom error message (returned by the servlet) for "email" field. However, even when validation is successful the error still shows up on the page. jsp: <!DOCTYPE html> <html> <head> <script type="text/javascript" src="js/jquery-latest.js"></script> <script type="text/javascript" src="js/jquery.validate.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("#myform").validate({
Find and highlight text within specific elements.
I would like to do a search through a specific column of a table. When a letter matches a search string it will be highlighted. For example the following table xxx xxx xxx abc xxx xxx xxx bcd xxx xxx xxx xyz I want to do a search for b in the last column. When found the background of that specific letter changes. xxx xxx xxx abc xxx xxx xxx bcd xxx xxx xxx xyz Is this even possible?
make select slider open multiple php scripts
I want to make one id trigger multiple php files. I`m using the slider to switch my light on and off, wich works great. But i can`t find a way to switch of all my lights at once. HTML <label for="slider"><font size="4px">Stopcontact</font></label><br> <select name="slider" id="stopcontact" data-role="slider"> <option value="schakelen.php?kanaal=a14&actie=uit&optie=0">OFF</option> <option value="schakelen.php?kanaal=a14&actie=aan&optie=0">ON</option> </select> </li> JAVASCRIPT <script> $(document).ready(function($)
jFlow not working in Safari ?
Hi, I'm working on this website, www.maxlakner.com , and it works in Chrome but not in Safari and I can't figure out why. Any help would be very appreciated, thanks very much!
Cloning last three rows and incrementing multidimensional input names?
Having a hard time figuring this one out... I am attempting to clone the last three rows of a table while also incrementing the names of the inputs, which are arrays. (I've put the code on jsfiddle http://jsfiddle.net/5ntbg/1/ To be clear, once the user clicks the "newissue" button, the following should happen: (1) The last three rows of the button's parent table (i.e., table.subtitle-form) are cloned and appended to the table.subtitle-form (2) The names of the inputs should be incremented appropriately:
Calculate div's slider console
Hello, I'm trying to make my own vertical slider instead of using browsers default one. So, I have .header which is fixed at top, and .footer which is fixed at bottom. Between those, it's my div.main which has overflow and possible scrolling. My question is, can I get only visible area of .main with height() or innerHeight, or whatever, or, it's only solution to use: $(window).innerHeight() - $('.header').innerHeight() - $('.footer').innerHeight I'm trying avoid these calculations and only get visible
problem ajax done call
Hi I have this call: $.ajax({ url: '../php/functions/area_id_to_table_name.php', type: 'post', async: false, dataType: 'json', data: {areaOfWorkId: userAreaOfWorkArray} }).done(function(object){ alert(object); });the code after this code is executed, and when I am bagging this in the browser I can see the it skips line number 9. here is the php side code:
multi-page template with swipe
Greetings, It is possible, by the multi-page template, that I can change the pages with horizontal swipe of the display from my mobile phone? Regards and thank you Michael
Script not working in chrome , firefox etc
`Here is a block of java script code for image slide show. it woks fine in ie but does not work in any other browser. plz help me. // The list of images to display in the slideshow //creating a array of the image object var image = new Array("Images/Gallery/Default/20001.jpg","Images/Gallery/Default/20001.jpg", "Images/Gallery/Default/20002.jpg","Images/Gallery/Default/20003.jpg", "Images/Gallery/Default/20004.jpg" ) //variable that will increment
Jquery and jsp
Hallo i am new in Jquery and allso in JSP i have build a function in jquery $(document).ready(function() { var work; $('#subject').keyup(function(e) { work = $('#subject').val(); if(e.which == 13) work +=" <br/> "; }); }); My question is , How can i use the variable "work" in JSP for exemple if i want to setAttribute that the content of the attribute will takken from the variable "work" is it possible? and ides?
Form validation
Hi all, im new to jquery however im in the process of reading Jquery from Novice to Ninja and im learning fairly quickly... however ive got a form on a webpage which tells the user if they havent entered the info required. The thing is the error messages appear in the wrong place and when they appear seem to change my page height which i dont want. I used the insertAfter function and appendTo to see if it would shift it to where i wanted but its still not happening lol I was thinking about
help in overcoming a small problem in the code that I am trying to write
Hello, I am new to jquery and I'm trying to overcome a small problem in the code that I am trying to write. I'm trying to write a code that identifies pressing a button and accordingly hides a div or expose a div. The problem arises when the page first loads, In this situation it takes two clicks on the button for the desired action to occur - instead of one click. after the two clicks its working great, the problem only occur when the page first loads. I'd be happy if someone could help me diagnose
Upload - show info and Space on server?
I have seen this before but can't find the site it was on to show you how long it takes to upload your file to our site. Plus Just curious if there is any code for showing how much space a client has on the server? Is this code we need to make or can we modify some to our application. Thanks
getting started with jQ Mobile.... links not working.. what am I missing?
the links in nav here just won't work... http://mayacove.com/jqm/page1.html very strange behavior.. (url loads in location bar, but page doesn't load, it only load if I hit "return" in location bar in the browser.. (sometimes the new page I'm looking to get to appears at the bottom of the page (page2 @ bottom of page 1, etc..) I used pretty much the code here http://jquerymobile.com/test/docs/toolbars/docs-navbar.html for nav and links... (I haven't applied class ui-btn-active for the selected links,
Caching jQ/jQM (+ PhoneGap)
Hey everyone, I'm trying to work with jQM and PhoneGap to write an app. Using a single-page layout is better to not have to load the whole app into the DOM right away, but leaves me with a great loss of flexibility as I have to define my header over and over again in each file. An even greater problem, though, is having to load jQuery, jQuery Mobile *and* the CSS file again everytime I open a page. My question is if someone knows if a PhoneGap built app will cache those files or really reload them
Calling Files
Hello everyone, this is my first post here :) I've got a jQuery code, that works perfectly in http://www.example.com/dir, but the same code doesn't work at http://www.example.com/other/dir Whats wrong? :s
CSS - how to float an image right AND center vertically
This is really a pure CSS question, and I'm going to state it in pure CSS terms. The reason I'm asking about it here is because it's actually to solve a problem with jQuery Mobile listviews - or, actually, my hand-rolled replacement for jQuery Mobile Listviews. ('ll be creating some sort of tutorial on using this once I am done, and will announce it here. Maybe the solution could ultimately be incorporated into the JQM listview, if there is a good cross-browser solution. It seems rather simple on
JQuery Datepicker - OnBlur
I see there is no Blur event for the datepicker (I am not using the text box and only the UI which displays month and year in the dropdown and dates in text). I am able to fire blur event on the dropdowns individually. What i wanted is to have blur event on the whole control. I am not able to get it fired on the text. Any help would be appreciated.
Cycle plugin question
Hi all, I have a wordpress theme that uses the cycle plugin. The cycle items are consisted of an image and some text from a wordpress post. to check it out click here. My question: I would like the text to truncate earlier in the sentence. Is this a jquery issue or part of the theme css? Thanks and sorry for the noob question... Yaron
Ajax post to an online resource from an app-cached html
Hi guys, The situation is: From a cached HTML try to access a web service online, if you can't reach it (probably because of no connection) load the last data from local storage. The problem is that jQuery ajax is giving me an error, even if the web service is online. If I remove the HTML from the application cache the code works. I debugged a little and it seems that the 'status' that jquery is getting from the call is 0 instead of 200 - 300. How can I solve that? Since the web service is an online
Use jQuery to place clicked button files into target #CONTAINER.
I need the jquery codes to perform the actions for this simple webpage. I use css file to place measurements and colors etc SIMPLE WEBPAGE: I need to know where to place the codes: In the <head> etc </head> or in the web page in the <body> area. <div id = “#header”> details in css file</div> ex: width:200px; height:300px; etc in css file. <div id =”#container”>Details etc in css file - Inside this (#container BOX) I want to see my other html/php file content when button1 /2 /3 etc is clicked</div>
Menu (Animated) how to move position
I want a Jqurery menu can any one tell me the code. I want to make an animated menu placed on right, using jQuery how it will work: if i click on a menu (example: ABOUT US) the menu/ the ABOUT US text will moving to HOME and HOME is moving to CONTACT US so basicly the menu is rotated to left and the selected menu is placed on the center with bigger font. It should looks like this I have done till now... Find the attachment
Detecting change of radio/checkbox
I'm rewriting a plugin of mine and I want to try to take care of an issue we had in the past. Here is the jsfiddle of what I'm talking about http://jsfiddle.net/Mattio2187/HruGP/ When you check the checkbox by clicking on it, the change event is triggered. It's being logged in the console. However, if you use the button to the left of it, 'change' is not triggered. With the plugin, I want to be able to detect this change if the user is checking the checkbox or radio button dynamically with code
Focus when enter keypress
heya !!! i need one easy help i trying to move focus to next field when enter keypress , but not working , this is my jqueryCode and HTML this is my HTML <table border="0" width="29%"> <tr> <td align="right"> Conta D</td> <td> <input type="text" name="contad" id="contad"></td> </tr> <tr> <td align="right"> Conta C</td> <td> <input type="text" name="contac" id="contac"></td> </tr> <tr> <td align="right"> DOC</td> <td> <input
change enter behavior in tabby plugin
Hi, I am new to js and jquery. Usually I try to learn things by fullfilling a certain task and read the docs/manuals as much as possible to do so. Currently, I try to get a textarea element to behave a little more like a desktop text editor. It should be able to write a tab in the textarea when pressing tab and when pressing enter it should be able to intend the cursor in the new line if the current line is intendend. I found the the plugin "tabby" which works fine with TAB and SHIFT+TAB. For the
input field bypassing by <enter> w/o form submission
Dear jQuery's guru, I faced a problem!I want to bypass from one input field to other one by <enter> (<return>) key pressing instead of default behaviour (<tab> key pressing). But there was default form action on <enter> keydown event was performed. Remember that <enter> keydown event on form means default "Form submit" action. How to prevent default action, form submission, in time of <enter> keydown event processing? How to modify following code? I use hotkeys jQuery plugin for key binding to input
help, asp button error loading page jquery mobile
I developed a web app for sending mail, and when I click on submit, get the error: "error loading page" or "error cargando pagina" what you need for help me? this is the link http://www.caribemotor.com.co/movil/contacto.aspx thank you i used jquery.mobile-1.1.1.js jquery-1.7.1.min.js too try $(document).bind("mobileinit", function(){ $.extend($.mobile, { ajaxFormsEnabled: false }); }); but it doesn`t work
Next Page