GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
My site consists of 1 image. The image is centered using text-align: center; on the parent div.
I am using this code, to resize the image according to the browser size:
The problem is that when im using text-align: center on the parent div, the coordinates are off a bit to the left after resizing.
Is there a way to solve this?
Can you set up a jsfiddle example? I can't think of any reason text-align would affect the coordinate map, I can't reproduce it with a simple case.
Thanks for the quick reply
Here you go:
Looks like resize is not resizing the wrapper, definitely a bug. I should be able to fix this today or tomorrow.
Im not sure what is causing the problem, but Inspecting the element shows that the canvas has the correct size, but is not moved to the center.
Sounds great, thanks!
Bugfixes: Issue #58 (wrapper div not resizing); #59: IE6-8 opacity; m…
…ore test migration
Try the latest build, it should be fixed now.
I switched the reference to the latest build. I still can't get it to work. Could you please take a look at:
Thanks ! :)
OK - well - there WAS a problem with resize, but that's not what is wrong in your example. Your image map does not match the image in the first place. The image is 800 x 613 pixels. Two of the areas don't even fall within that boundary. Even if you get rid of "resize" and the text-align formatting, it's still not right.
My bad. I was not aware that imageshack resized the original picture. Works like a charm. Thanks a lot!