Bug Tracker

Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#13037 closed bug (notabug)

On ipad safari event.pageX is undefined

Reported by: Leon Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.8.3
Keywords: Cc:
Blocked by: Blocking:



startX = event.pageX;


startX is undefined

Change History (7)

comment:1 Changed 10 years ago by Leon

On ipad safari with jQuery1.6.4, it works well

comment:2 Changed 10 years ago by Leon


startX = event.pageX; startY = event.pageY;


attributes as clientX, offsetX are also undefined

comment:3 Changed 10 years ago by Leon

I tried a test on click function, as follow:


startX = event.pageX; startY = event.pageY;


It just works!

comment:4 Changed 10 years ago by scottgonzalez

Resolution: notabug
Status: newclosed

Touch Events don't have those properties; they're hidden behind an array of touches. Please ask for help on the forums or StackOverflow.

comment:5 Changed 10 years ago by Leon

Thanks, Scott. But when I used version 1.6.4, touch events just had x/y properties, and all things go well. My project just crashed when I updated jQuery to v1.8.3(so I had to roll back to the old version). Can you check if x/y properties is hidden by jQuery?

comment:6 Changed 10 years ago by dmethvin

Sounds like you need to use event.originalEvent.pageX, since jQuery doesn't know anything about touch events it doesn't try to normalize them.

comment:7 Changed 10 years ago by Leon

Well, thanks for your help!

Note: See TracTickets for help on using tickets.