-
9 Jan 2012 2:13 AM #1
Unanswered: Cannot navigate through pages using a tap event on images
Unanswered: Cannot navigate through pages using a tap event on images
Hi,
I am developing a demo app using sencha framework for iphone and ipad just for learning purpose. The problem is, I am not able to navigate from one html page to another using href on images in mobile safari, but the same is working for normal desktop browsers. I also tried to use a tap event for images but was not successful. I am posting the code and my main aim is to navigate to the second page when I click on the image..
This code is working properly in desktop browsers but in a mobile browser only text is acting as a hyperlink, I just need to navigate through images. I know I am skipping something basic but would appreciate your help in this.Ext.require([
'Ext.Container', 'Ext.Button'
]);
Ext.application({
name: 'NotesApp',
onReady:function(){
Ext.create('Ext.Panel', {
fullscreen: true,
scroll: 'vertical',
cls:'purplefont',
items: [
{
items:[
{layout:'hbox',cls:'pad6',
items:[
{flex:1},
{html:'<a href="finddoctor.html"><img src="images/doctor_icon.png"></img><p >Find Doctors</p></a>',cls:'image1',flex:1},
{html:'<a href="findhospital.html"><img src="images/hospital.png"></img><p >Find hospitals</p></a>',cls:'image1',flex:1},
{html:'<a href="#"><img src="images/pharmacy_cross.png"></img><p>Find Pharmacies</p></a>',cls:'image1',flex:1},
{flex:1}
]
}
]
}
Thanks in advance..
-
9 Jan 2012 7:51 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 34,121
- Vote Rating
- 453
- Answers
- 3160
Please post into the appropriate forum, I have moved this to the Sencha Touch 2 Q&A forum. Also, please wrap your code in the code tags.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
9 Jan 2012 8:58 PM #3
Sorry.. just joined the forum, will take care of these in future. Can you please help me out with this?
-
11 Jan 2012 12:30 AM #4
Got it.. Used an id tag with the image with a proper event handler for a tap. Now the problem that I am facing is image scaling while opening the same page in iphone. In iPad resolution is good but in iphone images are getting overlapped. Can anyone tell me what to do in this case?


Reply With Quote