iPhone tel link not working - Sencha Framework - ios

I am adding a call button to a mobile site
<div class = "button page1"
<div class = "phone-button">
<a href = "tel:8885555555">
<span class = "button">
<span class = "phone-img"></span>
<span class = "button-text">Call</span>
</span>
</a>
</div>
</div>
Other than some minor css differences, the call button div's are the same throughout the site. The button works fine on one page, but for all other instances, when the call button is clicked the number pops up for just a second and then disappears bringing up the html in the 'cancel/call' pop-up instead of the phone number. The button works properly on other phones, so does anyone know why it's not working in mobile safari?
UPDATE: the site uses Sencha Touch framework, and I found some old forum posts about a bug there (http://www.sencha.com/forum/showthread.php?153341-tel-link-does-not-work-on-iOS-with-ST-2.x!), but I can't find anything recent.

Solution: there is a bug in Sencha's framework, so I ended up deleting Sencha's phone-number routing function, and the above code worked fine.

Related

Twitter share with back button using Ruby on Rails

I'm not much experienced in Rails. I'm trying to implement Twitter sharing in my project.
<li class="twitter">
<a onclick="window.open('https://twitter.com/share?text=<%= tweet_text %>&url=','sharer','toolbar=0,status=0,width=548,height=325');" class="popup" href="javascript: void(0)"></a>
</li>
and this will open up a tweet page in a new window in case of browsers. But in case of iPad or iPhone this thing loads in the same tab and the user will be stuck at that page if he or she thinks not to tweet when it loads.
So what I want is that I need a tweet page that comes with a back button or cancel button or something similar to that which can solve this.
I know this post has been here for one year but I am answering it anyway. I believe you are looking for this
<a onclick="window.open('http://twitter.com/share?text=<%= #post.title %> by #yourname- &url=<%= url_for([#post,{only_path: false}])%>','_blank','width=800,height=500,top=200,left=300');void(0);" >
<i class="fa fa-twitter"></i>

twitter bootstrap and ajax modal

i am using twitter bootstrap in my asp.net project and what i have is a menu bar at the top. some of the menu items are supposed to open a modal with external HTML content. i tried putting an iFrame in the div which is to be become the modal. this does not work well in that it i cannot get the modal window to auto size to the content of the external HTML page.
i am curious to know if there any recommendations on how to correctly use the modal window with external content or any other jQuery plugins which work correctly with twitter bootstrap.
thanks in advance.
In case anyone else comes here from Google... I found http://blog.assimov.net/blog/2012/03/09/ajax-content-in-twitter-bootstrap-modal/ helpful.
Relevant code (copied from the blog, not trying to claim credit):
<a class="btn" href="/path/to/your/page.html" data-toggle="modal" data-target="#myModal">Launch Modal</a>
<div class="modal fade" id="myModal"></div>
$("a[data-toggle=modal]").click(function() {
var target, url;
target = $(this).attr('data-target');
url = $(this).attr('href');
return $(target).load(url);
});
https://github.com/jschr/bootstrap-modal
You can load in content via ajax. I use this personally. Also feel free to check out www.bootsnipp.com Great resources, including this one can be found there.

jQuery Mobile interactive link with title and description MVC

I am trying to have an interactive list element with a title and description.
I have an action link and a p tag.
<li>#Html.ActionLink((string)Model.Date.ToShortDateString(), "Details", new { id = Model.id})
<p style="padding-left: 15px;">#Model.RecordType</p>
</li>
Is it possible to also make the description 'clickable'? The title is in the correct place, but if the user were to touch the description on accident, it would not trigger the action link.
This li is enclosed in a <ul data-role="listview">
The problem was when I was testing it in a browser. When testing on a mobile device, this problem does not exist.

double display of jquery mobile submit buttons

I need help to rectify the following issue on some of my jQuery submit buttons. A single submit button displays two buttons with one on top of the other.
(source: nyumbanipap.com)
Any help will be appreciated.
html:
<input type="submit" name="confirmpayment" value="Confirm Payment" data-theme="a" />
It is a normal submit button on a form.
EDIT
I have noticed that this happens when returning from a non-ajax page. e.g. I am using PayPal and when I am redirected back from Paypal, this when the buttons are double displayed.
Any help will appreciated.
I just had the same problem. Turned out that I included the jquery mobile js file twice. Maybe that helps someone.
I was having the same issue within a rails app with jQuery mobile (in which I'm not always using AJAX either). Adding data-role="none" to the submit tag on the form worked for me.
<input type="submit" value="Next Question" class="ui-btn ui-state-disabled btn" data-role="none">
Go to bottom to read about that:
http://demos.jquerymobile.com/1.0/docs/forms/docs-forms.html
I know this is old but do not use the tags.
it should look like this
< p >< a href="#whatever you are naming your form or submit area" DATA-ROLE="button">Submit< /a>< /p>

Adding scroll bars to a listview using JqueryMobile

Trying to add scrollbars to a listview within a dialog in JQueryMobile with no joy.
I'm using the following code:
<div class="content-primary">
<ul id="lvPages" data-role="listview" data-filter="true" data-inset="true" data-scroll="true"></ul>
</div>
Which works perfect on desktop browsers yet when I test this on an iPad the scrollbars don't appear.
Is there something obvious I'm missing?
Sorry, should actually add:
I'm adding the items via Javascript and am calling a " $("#lvPages").listview('refresh');" upon the end of these additions.
According to this forum article, you have to include the jquery.mobile.scrollview.js script (and its associated CSS file) for the data-scroll attribute to be recognized and acted upon.

Resources