Launching popup after page load
Hello. I am using popup features for JQM. Launching the popout via a button click is straightforward but how can I get the popup to launch after page load? JQM docs say you can initialise the popout via: $( "#myPopupDiv" ).popup( "open" ) I tried this by using the code below but can't get it to work. It launched on page load but would not close. I am a newbie with jquery so any help would be much appreciated. Thanks. $(document).bind("mobileinit", function(){ $( "#myPopupDiv" ).popup( "open" ) });
error on json parsing on ajax callback
I am making an ajax call which return the following json {"0":"37","id":"37","1":"1","hand_tool_categoy":"1","2":"10 Pcs Allen Key Set","name":"10 Pcs Allen Key Set","3":"handtools182.jpg","image":"handtools182.jpg","4":"ht","type":"ht","5":"{\"f_1\":{\"val\":\"RST- 6A101C\",\"name\":\"art_no\"},\"f_2\":{\"val\":\"\",\"name\":\"feature\"},\"f_3\":{\"val\":\"1.5, 2, 2.5, 3, 3.5, 4, 5, 6, 8 & 10 mm\r\n1\/16, 5\/64, 3\/34, 1\/18, 5\/32, 3\/16, 7\/32, 1\/4, 5\/16, 3\/8 inches\",\"name\":\"size\"},\"f_4\":{\"val\":\"100
Load url into existing jquery mobile page
Hi, I am looking to load my twitter page into an existing jquery mobile page containing just a header with Title and Home link. I want the https://mobile.twitter.com/ceist1 to basically have a Title and home link for user to get back to home page instead of being directed out of the mobile web app. I have researched and tried $.mobile.loadPage("url"); and also url = 'https://mobile.twitter.com/ceist1' $('#selector').load(url); but no joy. I am a newbie to jquery mobile development and would appreciate
AJAX problem with html
I am having a weird problem. I have a php script that is called by an ajax function that is not placing the html returned the way the data is. Here we go. <?php // getMemberVideos.php // Get schedule from the database include "main.php"; // This is for the id vars only $db=mysql_connect($hostname, $idname, $idpass) or die(mysql_errno($db).": ".mysql_error($db)); mysql_select_db($sdbname); // Get the Schedule Table $sql = sprintf("SELECT category FROM schedule WHERE type = 'Video' ORDER BY category
JQuery Mobile Google Map Not Working...Blank?
Hey guys! I have been working with this for over a week, and I'm STILL stuck....cannot get a simple map to load in my jquery mobile app (output with PhoneGap). I have a 5 tab app built with JQuery mobile and converted to an .apk by PhoneGap, all content works fine...static stuff, RSS, JSON data.....the last tab is a map/location pin, and it simply comes up blank. I've tried dozens of iterations of code, and looked at tons of examples online. Still nothing. Here are the vital parts I have coded...all
Problem about themes of Jquery mobile
Hi! I've a problem about jquery mobile: i'm trying to change the color of theme to the "data-icon", applying a customized theme. I have got a 2 customized themes. Firstly, the colour of the button is green. when I click to button, its changes to red. The button, change colour to my personalized colour. But when mouse is moving over it, the theme changes automatically, to the first option. Green again. I would like to know, where is the mistake.. function Dontreserve2hours(data, i, pista){ if(data==1){
getting exception,when i'm trying to add only spaces values to select box dynamically.
hi All, i'm using below code to add values to select box. <%@page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> <script src="js/jquery.js"></script> <script type="text/javascript" src="js/jquery.appendToList.js"></script> <script type="text/javascript" src="js/editableControlList.doucument.ready.js">
Change image src using input type hidden value
I am trying to replace the src in my img with the value in my hidden field and it does nothing. I am displaying products and have to change the src value to match the current product displayed. Here is the javascript I am using in the html header: var img = new Image(); $(img).load( function () { $('#prdimg').attr('src', img.src); }); img.src = $('#imgpath').val(); Here are the div elements I am using in html: <div id='divDetail' > <input id="imgpath" name="imgpath" type="hidden"
A very basic question about a code..
Hello everyone, I'm new in jQuery and to this forum... Hope you can help me around :) I understand the following code, I just don't understand why it is actually executed if it is set to a variable... Isn't it supposed to work only if I omit the "var co = "? Thanks, Kobi. <script> (function() { var co = $('span.co').each(function () { var $this = $(this); $('<blackquote></blackquote>', { class: 'co', text: $this.text() }).prependTo($this.closest('p')); }); })(); </script>
jQuery UI Draggable Clone Focus
Hi all. I posted this on StackOverflow, but I haven't had much success yet, so I figured I'd post here for more eyes. I'm trying to build a draggable/droppable folder-file view with jQuery UI, but I'm running into a problem with, what I believe is attributed to the helper. Here is my code: The HTML <body> <div id="topContainer"> <span>Parent Directory 1</span> </div> <span id="topFolder" class="folder"> <div class="drop"> </div> </span>
Help about .eq + .animate... thanks
I have problem in my code http://jsfiddle.net/rjay3087/Vx28h/ the problem is the .eq is not working... im making a slider... in that sample i dunno how to upload image in jsfiddle... thanks for the help...
Dynamically changing dropdown list
I've a problem in developing dropdown list in which If we select any option,the portlet should change dynamically.Can I have the solution for this using jquery??
Using Jquery with DOJO Toolkit, netbeans and JSP
Hello, I have been using DOJO Toolkit with JSP on the server running GlassFish Server. Now I want to use JQuery Mobile. My questions are: 1) Can JQuery mobile be incorporated with JSPs (as far as i know, DOJO toolkit also uses it... please Confirm) 2) I have used CSS to enable pages to be automatically configured according to target (Screen or Printer) and i have designed pages that print differently from displayed using CSS. Now i want to design the page so it adjust itself according to screen
ASP.NET MVC and jQuery Mobile URL Problem
Hi everybody! I developed an web application for a client with using MVC 4.0 and jQuery Mobile 1.3. This is my first app with jQuery Mobile. It is using a Form Authentication Login. So about my problem, my app works great on desktop browsers but when i try on ipad, after i login on site, something adds a code to url. On desktop it does not do this. Example : http://www.someappdomain.com/(F(GiZhZx8W0PUypXcpIOOIqp393ReiamAi3Nq7Y2DLgI184LgBXkOE4KNSqwyFIsYnOOgKyPpVCzod1cJQ7z-cJb40Gyyq8WvZ0KfrnQbrTRYWLhq6p-1VBGlvvPtjXMe2VmrxeBUd6lpeVYV9jtsIkGh3bxM3TaDS4YGuhKXx1rw1))/Reservation/Calendar
when i move one of four draggables, and right click on it -to make another DIV appear- ALL the rest elements move down
part of code here: //********************************************************************************** $('#mymenu').hide(); $('#mymenu, #mytop, #myleft, #myright, #mybottom').resizable(); $('#mymenu, #mytop, #myleft, #myright, #mybottom').draggable(); //********************************************************************************** $('#mytop').mousedown(function(event) { whichElement = "#mytop"; if(event.which == 3) { $('#mymenu').animate({'left': + event.pageX + 'px'}, 1); $('#mymenu').animate({'top':
Disable the #&ui-state=dialog
Hi there ! It's simple, i don't found how i can disable the url creation (Who adding #&ui-state=dialog at the end of the url) when i open a popup. Some tips is very appreciate ;)
How to modify parameters in $.get jquery with if statement
Hi I have the following code: $j.get('url.php', { "q": 'searchajax', "search_textbox" : search_term, "searchpage" : search_countpgload_tracker }, function (data) { if (data.indexOf('sorryxyznopostsfound') >= 0) { }else{ $j('.search_div').append(data); //Append the result to div class search_records. } }); I want to include an extra parameter if a condition matches: $j.get('url.php', { "q": 'searchajax', "search_textbox" : search_term, "searchpage" : search_countpgload_tracker if(a=='hello'){
jQuery mobile - problem with call popup
Hi, How call popup with jQuery code ? ... This code doesn't work : $("#editDialog").popup(); $("#editDialog").popup('open'); runConfirmDialog(); function runConfirmDialog() { $.mobile.changePage( "#editDialog", {role: "popup"} ); }); My popup is: <div data-role="popup" id="editDialog" data-overlay-theme="a" data-theme="c" style="max-width:400px;" class="ui-corner-all"> <div data-role="header" data-theme="a" class="ui-corner-top"> <h1></h1> </div> <div data-role="content" data-theme="d" class="ui-corner-bottom
Where I can get a good looking jQuery mobile template with all the code and css files?
I've tried coding web pages from scratch with jQuery Mobile and I'd like to see if there's a way to can get a good looking, full, functional jQuery mobile template/pages with all the code and css files, and then just tweak-it/modify-it myself to fit my needs, rather then continue from scratch. Or find someone who can provide this type of help. Thanks
JQueryMobile - Refresh Page in Multi-page
I'm developin an App with Jquery Mobile + html5 + PhoneGap...i'm using a multi-page template...all my app's pages are in the same .html...somethings like this: <!--********* HOME *************--> <div data-role="page" id="home"> <div data-role="content"> ..... </div> <div data-role="footer" data-position="fixed" id="footer"> <a href="#menu" data-role="button" dataicon="home" data-transition="fade" id="credits"> </a> </div> </div> <!--********* HOME *************--> <!--********* MENU *************-->
Javascript into jQuery Widget.
Hi to all. I am new to this and i really would like a help of some expert developer that for you might be a pretty easy task but for me it is really hard to achieve. I have a javascripts and i need it turned into a widget. I really don't know what im doing as i cannot turn into a widget. The code is below: /* CUSTOM FORM ELEMENTS Created by Ryan Fait www.ryanfait.com The only things you may need to change in this file are the following variables: checkboxHeight, radioHeight and selectWidth (lines
fancybox gallery with image rollover
I am building an image gallery with jquery fancybox to show before and after photo-retouching. I would like to add an image rollover effect to the large image in the fancybox overlay using the script below. When I apply the class="rollover" to the <a> tag the rollover script breaks. The script works fine when I apply the class"rollover" to the <img> tag. However this places a rollover effect on the gallery thumbnail. Can someone point me how to achieve this rollover effect on the large image
Problem in AutoSuggest placeholder text change
When page first time loads in mozilla or firefox it working fine for change placeholder text but when we refresh the page with F5 keyboard our placeholder text is not working its behaves like text in placeholder.however i am changing placeholder with onchange of select box id based.but the same thing working fine in chrome. html i have used for autosuggest box is below: <FORM NAME="searchForm" ONSUBMIT="return CheckDataSearch(document.searchForm);" METHOD="post" STYLE="margin:0px;" action=""> <div
Remove element after fading
Hello, On a plugin I have the following: var defaults = { hide: function ($element, $tooltip) { $tooltip.fadeOut(4000); } }; $(this).each(function (e) { $this.mouseleave(function (e) { tooltip.timer = setTimeout(function () { options.hide($this, $("." + options.class).stop(true, true), function () { $("." + options.class).remove(); // THE ELEMENT IS NOT BEING REMOVED }); }, 0); }), // Mouse leave }) On mouse leave I am trying to remove the
Help with creating a search box which finds text on a page.
I am not too familiar with jQuery although I'm quite good with HTML & CSS. I'm am working on building a text field which would store whatever is type into it and then use the .find to turn this text red. Here would be the code to find text and make it red. What I'm trying to do is add a text field which would change what it's looking for. In the code below it's looking for the span tags. I want to instead of looking for span take the text out of the text field and insert it where the span is. I would
Can you make cycle images scale
Hi, I am using the cycle plug-in and it works just fine - thank you! But I'd like the displayed images to scale proportionally as the size of the browser window changes. Is this possible? All other CSS settings are in percentages so the rest of the display area scales OK. I can change the size of the displayed images OK via CSS but can't figure out if the images can be made to scale. Any advice will be appreciated. Best regards from Australia.
Call a javascript method on all events occurence
Hi I am new to Jquery Mobile. I would like to know is there a way to call a javascript method on all the event clicks of the events available on mobile. Reason : I need to call a javascript method which will set a variable to 0 which would suggest that the application is not in idle for it to time out. so if there is a way to count on all the event and call the javascript mentid that would be great. clearly : there exist a function already( parent.postMessage("alive message","*"); 0 ) which
delay after typing when using remote autocomplete
Hi, I am using the JQM remote autocomplete as demonstrated here: http://jquerymobile.com/demos/1.3.0-beta.1/docs/demos/listviews/listview-filter-autocomplete.html (I know that link is to a beta demo, but it actually works in stable 1.3.0 as well - I just couldn't find a demo in the docs) Two things that are possible when using the jquery-ui autocomplete are: Load the data from a json array downloaded at page load Wait x mS after last keystroke before firing, to avoid multiple unnecessary queries
Filedownload using jquery
hi all, i have below code in my c# layer to start the download. I want to re-enable my UI once the download starts. but since i have already changed the header, i am not able to fire any javascript code. Response.Clear() 'Add Response header Response.AddHeader("content-disposition", String.Format("attachment;filename={0}.csv", "RawDetailReport")) Response.Charset = "" Response.ContentType = "application/vnd.xls" 'Append Data dtrReader.NextResult() etc.. is there a solution for this in jquery.
get JSON file
Can someone help me end explain me why the following script doesn't work: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>sans titre</title> <meta http-equiv="content-type" content="text/html;charset=utf-8" /> <meta name="generator" content="Geany 1.22" /> <script src="http://code.jquery.com/jquery-1.9.1.min.js"></script> </head> <body>
Possible to make this component JQuery friendly
Hello, I'm working on a JavaScript component http://redquerybuilder.appspot.com/ that tries to allow normal users to create and edit SQL queries. I know enough JavaScript and JQuery to be dangerous so I've no clue if it would make sense to try and make it JQuery friendly never mind how. I've read the documentation and understand the mechanics of writing a plugin but I think I'm missing the "zen" of a good plugin. Anybody thing it is sensible or worthwhile? Any tips? Cheers Sam
BlockUI doesn't work in IE - Please help..
Hi, I'm using the BlockUI plugin to prevent user action on a page when a hyperlink/button is clicked on a page. The page is created using frame. It works on Firefox (only on the targeted frame, center), but not IE or Chrome. In IE the shade/gray block shows up at the bottom of the page, after all the page content. Also the default "Please wait.." message displays after the gray box. Here's my code, tried with both a hyperlink and button. same result, doesn't work: <tr> <td > <s:a
JQuery UI tabs: how to start showing effect while hidding
I have a fade effect on hide and show tab in jQueryUI tabs. It works good but when the one tab is hidden then next tab is showing. I would like to start showing effect while hidding effect. How to do it? The image on slider2 should start showing when the slider1 is hidding. They should do it in one time. http://jsfiddle.net/Qw892/
How to define long methods
I have this fiddle http://jsfiddle.net/kQ8aS/ This is the jquery code $(document).ready(function (){ $('tr:first-child').next().addClass("current"); $("#next").click(function(){ $("table").find('.current').removeClass("current"); }); }); In my code,i am giving the second child a pink highlight and pushing the highlight to the next element when next is clicked. I am doing that by removing the current class from the previous element and adding a current class to the next class. How do i express that
Cycle Plug-In Question: using Prev
Hi, I'm using cycle for a PPT-style screenshot click-thru. Works great...one way. Forward. Some people want to go backward though and that's proving difficult to do with imagemaps. It seems to start the screens going backward, and the click-to-advance-forward functionality seems to be disabled once I start to go backward. Here is the code snippet. Bottom line is I want to advance the image forward by clicking anywhere, except on the image map (left area of the screen), which I want them to
Programatically changing theme in a Jquery Mobile component
Why theme 'e' is not reflecting in the output? <!DOCTYPE html> <html> <head> <link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.1/jquery.mobile-1.3.1.min.css" /> <script src="http://code.jquery.com/jquery-1.9.1.min.js"></script> <script src="http://code.jquery.com/mobile/1.3.1/jquery.mobile-1.3.1.min.js"></script> <title>title</title> <script> $(document).bind('pageinit', function() { $('input').attr('data-theme', 'e'); }); </script> </head> <body> <input type="text" /> </body> </html>
IE Conditional Directive towards jQuery 2.0
We know that jQuery 2.0 has stopped supporting IE versions less than 9 (vide http://blog.jquery.com/2013/04/18/jquery-2-0-released/) I would like to know if there is a conditional directive which we can embed to include jQuery 1 or 2 based on the browser version. This should not disturb other browsers right?
JQM ListView and Popups
Hi I have a listview in my jqm page which simply displays a list of items coming in from my database. I am using knockout template to render the list view. All this works fine. However when the user "taps" an item in the listview I want a "popup" to display with some option of what they want to do. This is simply a popup containing another listview with some menu options. The popup does indeed show, but then immediately disappears again. It almost like the event click is "hanging" around and "closing"
jQuery Validate plugin with metadata broken after upgrade to jQuery 2.0.0
I successfully used jQuery Validate plugin with metadata (this one at http://bassistance.de/jquery-plugins/jquery-plugin-validation/ ). versions: - validate 1.9 - metadata * Revision: $Id: jquery.metadata.js 4187 2007-12-16 17:15:27Z joern.zaefferer - jquery 1.7.2 I now upgraded jQuery to 2.0.0, validate to 1.11.1, can't find metadata anymore (404 here: https://github.com/jquery/jquery-metadata ) Part of my form: <input id="email_big" name="email" type="text" class="span4 {validate:{required:true,
ASP.NET Grid MVC
I am looking at a grid for MVC page in ASP.NET. jqGrid etc have the limitation that the page seems to take more time for rendering because of separate AJAX request. Is there other suitable and good grids for ASP.NET MVC?
Next Page