jquery-mobile

conditional javascript code not executing

有些话、适合烂在心里 提交于 2020-01-07 04:47:09
问题 Does anyone know why this code might not work? touchmove and touchend do not execute only touchstart because that's a seperate event and function :) $('input').live("touchstart", function (e) {$(this).addClass('click')}); $('input').live("touchmove,touchend", function (e) { if (e.type == 'touchmove'){ $('.temp').removeClass('temp'); $('.click').removeClass('click'); } else{var inputvalue = $(this).val() $('input[value="' + inputvalue + '"] + label').css({ '-webkit-transition': 'opacity 0.3s

How to get “old-style” rounded 3d buttons in newer jQuery Mobile 1.4+

我们两清 提交于 2020-01-07 03:18:07
问题 Well, basicly i'm trying to make this button <a href="#" class="ui-btn ui-icon-check ui-btn-icon-right ui-btn-corner-all ui-shadow"> button </a> Look like this: http://jsfiddle.net/waYg8/2/ But I'm missing a few classes, especially the glare-cut-out looking style. Any ideas? UPDATE: Trying to add own class, but looks 2d ugly... http://jsfiddle.net/2qt9w/ .btn_round { -moz-box-shadow: 0px 1px 0 rgba(255,255,255,0.3); -webkit-box-shadow: 0px 1px 0 rgba(255,255,255,0.3); box-shadow: 0px 1px 0

Why do I have to refresh each page to get the jQuery to work properly on each of them?

强颜欢笑 提交于 2020-01-07 02:32:25
问题 I'm using jQuery Mobile and I'm trying to move a simple list item around from one page to another. Here's one snippet of code I'm using: $('#YesNoMaybePage, #summaryPage').live('pageinit', function() { $('.green, .blue, .red').click(function(){ var $move = $('.purchase').prependTo("#summaryPage .theListItem"); }); }); Now this works great, when I refresh #summaryPage , click back to #YesNoMaybePage and execute the event. It however does not work if i refresh the #YesNoMaybePage and than

Animation in angular js slide animation of div?

老子叫甜甜 提交于 2020-01-06 19:53:30
问题 Can you please tell me how we slide div when user click tab .I make demo in jQuery Mobile (fiddle http://jsfiddle.net/ezanker/o9foej5L/1/ ) in which I have three tab and using the tab it show transition can you please tell me how we can do same in angular ? I am trying to achieve this but I am not able to do that how I ail achieve this in angular? Plunker http://plnkr.co/edit/ornYCV15uV8lPNL1ujPL?p=preview $(function(){ $("#owl-demo").owlCarousel({ navigation : false, // Show next and prev

Jquery Mobile - including fragments for a multipage template?

北城余情 提交于 2020-01-06 15:52:10
问题 We're doing a Codeigniter/jQM web application and have been debating the multipage template vs. single-page/file. Most of the cons of the multi-page template (meaning multiple data-role=page divs in a single file) cited relate to the single file getting unwieldy from a maintenance (and possible load time) perspective. The cons of the single-page approach seem to mostly focus on potential latency between pages. Given the vagaries of the internet, the latter approach seems more risky. It is my

How to display rss feed results in a jquery list

北慕城南 提交于 2020-01-06 15:31:05
问题 I would like to display my blog post results as a jQuery mobile lists. For now all the titles, date, author and snippets are appearing line by line and also I would like to be able to click on each posts and view the contents directly as a mobile format. This is my code: $(document).ready((function(){ url = 'http://hopexxx.com/category/daily-devotion/feed/'; $.ajax({ type: "GET", url: document.location.protocol + '//ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=1000&callback=?&q=' +

jquery mobile static footer without toggle

血红的双手。 提交于 2020-01-06 14:21:07
问题 I have a page with a fixed footer <div data-role="page" id="next_collection" data-theme="d"> <div data-role="header" data-theme="elw"> Title </div> <div data-role="content" style="min-height: 246px;"> Some content </div> <div data-role="footer" data-id="footer_nav" data-position="fixed"> <a href="#business_hours"><img src="images/icon.png" /></a> </div> </div> This works on Android and iPod, but on iPhone 4s it toggles (hide/show) the footer if you touch the screen. I tried to fix it like in

jquery mobile phonegap fillText max width property not working

江枫思渺然 提交于 2020-01-06 13:57:14
问题 i am working on an app that types text on to the image..so i dont want the text to go out of the image. here is my code: style #container{ overflow: hidden; z-index: 0; } #myCanvas{ z-index: 1000; border: 2px solid red; width: 100%; } html code <div id="container"> <canvas id="myCanvas"></canvas> </div> script $(document).ready(function(){ var context2= $("#myCanvas")[0].getContext('2d'); $("#myCanvas,#container").height((3*window.innerWidth)/4); context2.fillStyle = "#0000ff"; context2

how to remove white space when image loading?

有些话、适合烂在心里 提交于 2020-01-06 12:54:08
问题 My phone-gap app getting output I have 4 images sliding automatically it fixed any Device height and width my problem is while sliding images, I am getting white screen before image loading my code is :- <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.2/jquery.mobile-1.4.2.min.css"> <script src="http://code.jquery.com/jquery-1.10.2.min.js"></script> <script src="http://code.jquery

Javascript working only on page refresh in jQuery mobile

好久不见. 提交于 2020-01-06 11:51:12
问题 I am currently working with jquery mobile with JSP along with Struts. The problem is the javascript function gets called only after the page is refreshed once. The script is placed within the data-role 'page'. But the problem still persists. Currently am using jQuery 1.0 stable version. Here is my code .. <body> <div data-role="page" id="webtosms"> <script language="javascript"> function phonenumlen(){ //Mobile no validation var numlen = mobileno.value.length; //alert(numlen); if(numlen==0){