Putting a fixed header in a jquery autoresponse dropdown
In our Ruby on Rails app, we invoke JQuery autocomplete to perform a search whose results are displayed in a dropdown. We'd like to have the first item of the dropdown function as a fixed header, and items 2-N be part of a scrollable list/div, etc. Is this possible? Any hints or examples on how to do this?
Slideshow script ported script from Prototype... need assistance
I found this neat simple slideshow... it's just 1 JS file, and it barely scrolls. Really lightweight.. but I found it used Prototype, so I ported it to jQuery perfectly, and it works great, but now I want to extend it, to have those little bubble indicators, where it shows which slide you're currently on, and when you click on one, it goes to that slide. I've got it all working fine, except the ability to move to a different slide when you click a bubble... I'm not sure what the ""goto_slide" function
getting the ID from snapped item
Hi, I would like to know if there is a way to get the the ID from the snapped div. like a chess board, A-1 to H-8 When I move some piece on it, I would like to get the ID where that piece is now. Regards
Stop a Deferred callback queue in progress?
This dilemma may only exist because I'm an amateur and haven't thought of a better way. I love love love the new Deferred object, but I still can't use $.when() most of the time. The problem is that there are two kinds of errors: HTTP errors where an AJAX request fails, and application errors where the server-side code has a problem (like an empty form field). It requires logic like this pseudo-code: if (http_error) { handle the error } else { if (application_error) { handle the error
Please, help me with this problem with jQuery, event and textarea
I'm using Google Translate API function initialize() { var content = document.getElementById('text-input'); google.language.translate(document.getElementById('text-input').innerHTML, 'es', 'en', function(result) { if (!result.error) { var translated = document.getElementById("text-output"); if (result.translation) { translated.innerHTML = result.translation; } document.getElementById("text-output").innerHTML = translated.innerHTML;
XML + CSS + event_handlers is it possible?
I've used jQuery to attach event handlers like mouseover to HTML elements such as span and div. I am now thinking of using XML and CSS for presentation instead of HTML but I can't see a way to attach event handlers. Is it possible at all. Is it possible using jQuery?
Application Remote
Good Day, I would like to build an application which could be 'remotely controlled', so to speak, using jQuery. Example, let's say I have a system setup to where a user on my website is reading a blog posting, and from my own computer, I change a setting on my site. How can I, using jquery, make my app 'listen' for those changes and act accordingly? Right now I have a script checking every 5 seconds, setTimeout("function();", 5000);, to complete the task. Is this the right way to do it, or is there
Persistent Footer Nav Bar
Two questions about the persistent footer navigation bar... Is it possible to disable the functionality where it is possible to toggle the visibility of the persistent footer nav bar by tapping on the screen? They are used as mandatory navigation buttons, and I don't want to risk the user accidentally hiding the nav bar and not knowing what to do. On the Android, if the keyboard is displayed, the persistent footer nav bar is re-positioned directly above the keyboard. On the iPhone, this does not
ThemeRoller Not Working
For the past 2 weeks Theme Roller has been acting odd. For a while I could get it to load old themes or from the gallery only in Chrome, now it won't work in Chrome or Firefox. The base page works, but not changing any values and updating. We are trying to generate some updated images and CSS. Any chance of getting the source for Theme rolloer itself so we could just run it on our own server? Thanks. -Chuck
Jquery Mobile - Scroll View Page - on UL-LI
Hey guys .. need some brain assistance. Im trying to do a iphone web app, and i really like the "Scroll View Page" effect, and i would like to transfer onto a UL list ... I tried to rip it directly with the css and js files it seems to be using - but i just cant seem to get it to work. The path to the files should be ok ... Does anyone know if there is a zip file containing this effect or something like that, so i can dload and start trying stuff with the effect .. any how, link to the desired
adding an image to a draggable / sortable area
I've got a script that allows me to drag and sort images, and I can drag them to a trash can if I want them deleted. When I drag and sort the images, the images order is updated in the database, and when I drop them in the trash can, the images are deleted from the database, and the image file itself is deleted from the images directory. I've also got an ajax uploader, which exists on a seperate page, but I'd like to be able to combine the two. Right now if I upload an image, it displays the image
problem with .width()
Hi, i have make a simple code http://jsfiddle.net/pZdrg/ if you click on the first text it was ok, but if you click on the second text, you can see a space on the right side, but i dont know why :/ (and on IE 8 the Width / Height will give wrong value)
1.5.1+ broke my old $.get() json calls
Hi, functions like: function showData(id) { $.get("/url/getdata", {id : id}, function(data) { $("#dialogData").html(data); $("#dialogData").dialog({width: 500, modal: true, zIndex:22000}); }, "json"); } no longer work with the addition of 1.5. Looking at firebug, the correct data is returned, but the function breaks after entering the callback. Everything simply stops. How can I fix this? I read about the changes to Ajax call in 1.5, but I have over a thousand such calls through my project -> I cannot
How to assign arbitrary data to a dialog?
I am making a simple dialog with a multi-select input in it. The dialog will have a Cancel and Apply button (apply will cause a grid to be filtered based on the values in the multi-select). When the user pops up the dialog, they may change the values in the multi-select and Cancel. This will preserve the values and they won't accurately reflect what the grid is currently filtered by. I want to restore the values that were selected in the SELECT if they hit Cancel. I'm thinking the way to do that
Hi, new to jQuery, not to JS
Having a tough time integrating the 2. Trying to create 2 loops, the inner one I had working as below, until I tried to add the outer loop which iterates through the tables. Appreciate any pointers. <script type="text/javascript"> // <![CDATA[ var i=0; $("document").ready(function() { $("div").fadeOut(1000); if(i<5) { $("table:eq(i) div").each(function(index) { $(this).delay(1000*index).fadeIn(1000); }); i++; } }); // ]]> </script>
about id selectors
hi where can i find an example of how jQuery selects objects when using an id selector? i'm asking because i've been using a cross browser snippet to select objects and i was wondering if it's the right move to move from the snippet to jQuery. the snippet checks to see for availabe methods and depending on the one that works, it knows which browser the user is using and selects the object using that method. i also know jQuery is cross browser, so it's kinda implied, just wanna make sure.
how can i get right jQuery image swap code?
hello every one, i am trying to get each image loaded into div while mouse over but it does not work. jQuery is new for me what is wrong with jQery code i have no idea could you help please. here is the code. <title>Untitled Document</title> <style type="text/css"> #gallery li { display: inline; margin-right: 3px; } #gallery #main-img { background: url(2.jpg) no-repeat 0 0; padding: 26px; } </style> <script language="javascript" > $(document).ready(function() { // Image swap on hover $("#gallery
Problem with Success Function always returns false
<script language="Javascript"> var flag=0; function verifyUser(username) { $.ajax({ type: "POST", url: "check_username.php", data: "q="+ username , cache : "false" , success: function(msg) {
override of drop down menu and accordion (display problem)
Hi all I set a drop down menu using jquery naviDropDown 1.0 and use accordion of jquery-ui-1.8.11 too. I have a problem because the drop down menu is diplayed behing the accordion block. Does anyone know what the problem could be ? I attach a screenshot of what happens and head and mennu and accordion code. Head statements : script type="text/javascript" src="js/jquery-1.5.1.min.js"><link type="text/css" href="jquery/css/custom-theme/jquery-ui-1.8.11.custom.css" rel="stylesheet" /></script> <script
jquery append with fixedfooter in stacks
Ok, so I am green as can be here so I hope to find the help or direction for what I need. I am building a new site in a stacks page. I want a fixed footer across the bottom, that the main content butts up against, and does not scroll over or behind it. I was told that jquery append might help with that. Here is the CSS for my fixed footer; #fixedfooter { position: fixed; left:0px; bottom:0px; height:150px; width:100%; background-image:url('http://testserver1.justrightwebdesign.com/warehouse/Slice-1.jpg');
IE getScript problem
Hey! I'm having a really annoying problem, the sample code below is working fine with Firefox and Chrome but IE doesn't seem to run it: $('#button1').click(function() { $("head").append($('<link type="text/css" rel="stylesheet" href="page1.css">')); $.getScript('page1script1.js'); $.getScript('page1script2.js'); ... }); $('#button2').click(function() { $.getScript('page2script1.js'); ... }); $('#Buttons li a').click(function()
Get parent height and assign to selector
I'm trying to find a way to go through each instance of.div with class="promo" in order to get the parents height and assign it so both are the same. I tried the following but could not get it to work. I'm a bit confused on how to go thru each and pass the height value. There are 4 div's with the promo class and each parent is a different height depending on the content. I want to build this so that the promo div will automatically adjust and have the same height as its parent. $('.promo').each(function(){
Effect queue and stop not working correctly
Hello, I have this line: $('#target').stop(true,true).show().delay(3000).fadeOut(1000); This should work as following: 1. initial state of target is hidden. 2. target is "activated" and sequence is run, the target appears. 3. After 3 seconds target shall start to fade out. 4. target can be "activated" again at any time, and the sequence from 2. should restart itself. It works if I let the sequence run its course every time, but if I repeatedly rerun the sequence before it's done executing something
remove <b> tag from a table with a class
Hi guys, I now know how to write remove statment if its to remove one piece of html such as a <hr/> However in this case I'm trying to write a bit of javascript to remove a <b>TEXT</b> with whatever text inside. And in this case it's only for a line of text that apears in a <td> which has a class: This is the html: <td class="column_main"><b>NEW IN</b> </td>
"Load" Method doesn't work in chrome and opera? plz help me.
Hello there, I have 2 page. one of them,is gallery.html and another one, is index.html . i want to load the content of the gallery page into <div id="content-gallery"></div> in index.html. I use the fallowing code : $( 'a#gallery' ).click( function() { $( '#content-gallery' ).load( 'gallery.html' ); }); but it works only in IE8,FF, and safari. It doesn't work in chrome and opera (latest version). In opera and chrome, when i click on <a id="gallery">show gallery</a> it show only a bank page. I
jQuery validate on modal form not working in IE
I am using jQuery validate on a modal form. It works fine in FF, but not in IE 7/8. I am not getting any error, the form just submits without firing the validation. I have tried what solutions I could find on the forums but to no avail. Any idea would be appreciated. Here is my JS code: jQuery.validator.addMethod("phoneUS", function(phone_number, element) { //custom phoneUS phone_number = phone_number.replace(/\s+/g, ""); return this.optional(element) || phone_number.length > 9 &&
href alternative?
Is there a decent alternative to the href element? I need this because the href removes the fullscreen of an app and re-opens it in browser even after the user bookmarked the webapp. simply replacing <a href="myLink.html">mylink</a> with <a ontouchstart="window.location='myLink.html' ">mylink</a> doesn't work because of the hashtag navigation.
Creating $("<select>", { attribute object }) isn't recognizing the attribute object
$(document).ready(function() { var mselector = $("<select></select>", { 'alt': 'ROLLOVER TEXT', 'multiple': 'multiple', 'click': function() { alert('in click'); return false; } }); mselector.appendTo('body'); }); The SELECTor shows up in the document but it's not MULTIPLE, no ALT text, no CLICK event handler. What am I missing?
Can't update text of collapsible
I'm trying to update the content of an h3 tag inside a collapsible and when I do it doesn't draw the JQM decorations. You can see it here. Am I missing something?
Will there be really fixed "fixed" headers (without fading) in the final release?
Hi, Here's a question: Will there be fixed headers (or footers for that matter) which will be really fixed, and not fading in and out when you scroll as it is now? I ask because from all the iPhone apps I've ever tried - I've never seen any of them use the type of fadey headers that jquerymobile produces per default. It seems to me that the more "standard" header (which just stays on top, and your content scrolls freely underneath) would be easier to implement, even. I know that you have some new
ui.tabs.js I want entire page to show with a certain tab open
Situation: I have a list of topics on my index page that have anchors that go to a different web site page that utilizes tabs using ui.tabs.js. The anchors work just fine, that tab opens up, that subject is shown, etc. What I would like to have happen is that I can see the top of the web page with the header in addition to the specific tab and subject opened up. As it is, the user can't get to the navigation to other pages on the site without scrolling - it could be a little confusing. They
Able to disable checkboxes on condition, but odd problem
I asked part of this question on stackoverflow but didn't get any answers I understood (link). I was hoping that maybe someone here could point me in the right direction. I have very minimal experience with jQuery as I usually just scavenge what I can find in Google searches. This time however, I need something much more specific. I found some jQuery code as a result of a Google search that allowed me to disable specific classes of checkboxes based on user input of a single select box. I works great
How to call internal functions of a plugin?
Hi there! Firstoff: I know I ask about using a plugin, and I wasn't so sure where to put my question in, decided though the general jQuery-Forum would be better as my problem is more connected to jQuery than the plugin itself. First off, I'm using this plugin and modified it myself a bit, adding new functions: http://www.quasipartikel.at/multiselect/ You'll find the underlying .js for the component here: http://www.quasipartikel.at/multiselect/js/ui.multiselect.js Now, scroll to the end of the file,
Pros and cons of internal linked pages
Is there any good reason why internal pages are more mobile optimized than their multiple pages conterpart ? Any thought ?
Calling a Script when button clicked
I would like to call a script defined within script tags in the HEAD section of the jsp. <head> <link rel="stylesheet" type="text/css" href="jquerymobile/jquery.mobile-1.0a1.min.css" /> <script type="text/javascript" src="jquerymobile/jquery-1.4.3.min.js"></script> <script type="text/javascript" src="jquerymobile/jquery.mobile-1.0a1.min.js"></script> <script> $("#button").click( function() { alert('button clicked'); } ); </script>
How to stream audio using jquerymobile
Ok so here's the deal. I'm trying to develop a simple application to stream audio for a radio station. I'm using phonegap together with the jquerymobile framework to create applications for the iPhone and Android. Here's my html body code: <div data-role="page"> <div id="radioContent"> <div data-role="content"> <a data-role="button" onclick="RadioListenLive()"> <div id="radiotext">Listen Live</div> </a> </div> </div> </div> and here's my .js code:
How to pre-select dates within a date range ?
Hello all, I have following problem. I have 2 input fields, a from date and a to date. If I select as start date for example the 5. June, than I can not select an earlier date in the to date field. Thats ok. But how can I set the dates if they come from the database ? I load a page and in the from date and to date is already filled, because dates are in the database. Now when I select for example the start date I can also select dates after the to date and also I can select earlier to dates than
Ugly header buttons in some Andoid phones
I have some problem with the home- and backbutton in the header of this mobile web http://mobil.flisbyab.se the rounding of the buttons get pixels around them and in some android phones the the arrow and house icons are missplaced Is this known issues in androids? I just used the standard css but with my own color theme /jesper
jQuery validate plugin - Incorrectly picking up partial class names needed for Omniture error/click tracking
Ran across a likely unusual circumstance where the validate plugin went and picked out an unexpected partial part of a class name not meant for it and therefore applied more specific 'date' type validation as well as the intended 'required' class behaviour: <select class="select required omniture omniBlank(CE:To date missing) omniError(CE:To date incorrect )" name="cardExpiryMonth" id="expiryMonth"> <option value="">mm</option> <option value="01">01</option> ... <option value="12">12</option>
listview behaves differently from a3.0 to a4.1
My application had no problems with the listview when it was using version a3.0. I upgraded to a4.1, and the listview has the following problems: 1) No right side arrow is displayed 2) One must click the button text to trigger the event. Before, I could click on the entire panel 3) The hyperlink is underline This is the markup: <ul data-role="listview" class="ui-listview" data-inset="false" id="listResults"> <li class='ui-li-has-thumb ui-btn ui-btn-icon-right ui-li ui-btn-up-c' data-theme='d'>
Next Page