/    Sign up×
Community /Pin to ProfileBookmark

anchor tag not working in safari (ios) for Iphone/iTouch/iPad

This is a strange one.

All the anchor tags on my website work in IE, Chrome, FF, and even Safari on Windows.

And none of them work on safari IOS on my iTouch or iPad.

When I click on the any link or the items in the menu bar on iTouch, it will go change the background color as specified by the :hover in the css, but nothing happens. It’s not just on the text anchors, but also the anchors on pictures and the logo also.

Again, all the anchors are working on other browsers (including Safari Windows).

The broken anchors are at [url]www.flashpackertours.com[/url]

I’m hoping someone can point me in the right direction on how to debug this.

Thanks in advance for your assistance!

to post a comment
HTML

5 Comments(s)

Copy linkTweet thisAlerts:
@handcraftedwebApr 13.2012 — That is bizarre. I tested it and you're right, the links just don't work my iPad (iPad 1, ios 5.0.1). Note if you hold finger down on link, the menu pops up and you select "Open" it does work.

The page doesn't validate in the w3c validator nor this html5 validator, so I'd get it to validate and then see how it works. But it is bizarre, never seen that.
Copy linkTweet thisAlerts:
@TechDMexauthorApr 21.2012 — The validation on my home page failed because of the facebook like code isn't html5 compatible ?

However, I created a duplicate page at www.flashpackertours.com/home2.html with the facebook code off the page and it validates fine.

But, the links are still all not working on iPad. I've got some feed back from other iPad users who can't figure out why some websites are broken, and I think it's related to the same problem I'm having.

It may be related to a new "feature" where you hold your finger over a link and it comes up with a mobile-safari popup box which asks you what you want to do with the link.

However, you can't click the link. It looks like all the links are broken.

Again - works on all the major browsers, just not mobile safari.

Very weird.

Hope someone can help!
Copy linkTweet thisAlerts:
@TechDMexauthorApr 21.2012 — Found it!

I turned off javascript, and the links started working again. It's a java script I installed that tracks mouse movement for popup boxes. I would think since ios has no mouse, the java script would be kind of ignored, but instead, ios renders all anchor links useless. Don't know why, but I can disable the script for ios.

Hope this helps others in the future!
Copy linkTweet thisAlerts:
@handcraftedwebApr 21.2012 — Glad you found it. Is the offending JavaScript a popular library or something you wrote yourself?

Found it!

I turned off javascript, and the links started working again. It's a java script I installed that tracks mouse movement for popup boxes. I would think since ios has no mouse, the java script would be kind of ignored, but instead, ios renders all anchor links useless. Don't know why, but I can disable the script for ios.

Hope this helps others in the future![/QUOTE]
Copy linkTweet thisAlerts:
@TechDMexauthorApr 21.2012 — It was some nice js code from (below) for popup boxes. It allows popup boxes on hover or on click. Nice code and works well, just breaks ios safari links. I'll add some code to exclude the code for those browsers.

--------------------------------------------------------------------------
Code for link-hover text boxes
By Nicolas Honing
Usage: <a onmouseover="popup('popup content', width)">a link</a>
(width is optional - default is in CSS: #pup {width: x;},
escape " in content with &quot;)
Tutorial and support at http://nicolashoening.de?twocents&nr=8
--------------------------------------------------------------------------
×

Success!

Help @TechDMex spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.2,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,
)...