picture displaying wrong orientation |
picture displaying wrong orientation |
Joe M |
Jul 8 2017, 01:00 PM
Post
#1
|
Group: Members Posts: 4 Joined: 18-September 15 Member No.: 23,548 |
Very simple notepad hand written web page:
http://www.missilecommand.org/Space_Duel2/Space_Duel_2.html I have it set up where is someone clicks on any picture, it brings up a higher resolution pic. Problem is the 6th picture (entitled "Marquee back".). If you click on the picture, it displays it in a vertical orientation. I've posted hundreds of pictures with this html code before and I've never encountered this before. When I open the picture on my PC (via Windows Explorer), it opens it as it should as horizontal. What is going on here? How do I correct this? The dimensions in Windows Explorer show it as 2272 x 1704, indicating it is a horizontal picture. The html code is rotating it. Can't figure it out. Thanks in advance. Joe (joemagiera at ameritech dot net joemagiera@ameritech.net |
Christian J |
Jul 8 2017, 03:26 PM
Post
#2
|
. Group: WDG Moderators Posts: 9,653 Joined: 10-August 06 Member No.: 7 |
When I open the picture on my PC (via Windows Explorer), it opens it as it should as horizontal. In which device does it open vertically, a smartphone? QUOTE What is going on here? How do I correct this? Nothing on the page is causing this, so I suspect your smartphone is rotating the image to make fit the screen better. |
pandy |
Jul 9 2017, 06:58 PM
Post
#3
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,730 Joined: 9-August 06 Member No.: 6 |
I see it too, on my desktop. K-Mel, Firefox, Chrome. If I copy the image and paste it into an image editor it displays correctly in IrfanView, but not in my more advanced editor. Same if I save the image. OK in Irfan, but wrong in everything else.
I guess there's something wrong with the embedded orientation information in the image file. Why Irfan gets it right I don't know. Suggestion: open the image in another editor than the one you used earlier, turn it right if needed and save it again. |
Joe M |
Jul 9 2017, 07:40 PM
Post
#4
|
Group: Members Posts: 4 Joined: 18-September 15 Member No.: 23,548 |
>>When I open the picture on my PC (via Windows Explorer), it opens it as it should as horizontal.
>In which device does it open vertically, a smartphone? It's just my desktop PC (Windows XP). The same machine where is shows correctly in Windows Explorer. Is there anyway to force this to horizontal using the Height and Width parameters on the "A HREF"? This post has been edited by Joe M: Jul 9 2017, 07:42 PM |
Christian J |
Jul 9 2017, 08:14 PM
Post
#5
|
. Group: WDG Moderators Posts: 9,653 Joined: 10-August 06 Member No.: 7 |
It's just my desktop PC (Windows XP). The same machine where is shows correctly in Windows Explorer. In that case it might be something wrong with the image file, like pandy wrote. QUOTE Is there anyway to force this to horizontal using the Height and Width parameters on the "A HREF"? Not with HTML. There are some tricks with CSS, but if the image file itself is broken I don't know what the result would be. |
pandy |
Jul 10 2017, 02:58 AM
Post
#6
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,730 Joined: 9-August 06 Member No.: 6 |
CSS sounds risky. The image-orientation property can rotate the image, but it uses the image orientation information in the image file as a starting point - what else is there? So if there is a browser that gets it right (although it's probably wrong...) to start with it will show the image with the wrong orientation after the CSS treatment. It's always better to fix the problem than to try to mend it. In this case use an image file without errors.
Did you look in a desktop browser that got it right, Christian? If so which? |
Christian J |
Jul 10 2017, 06:37 AM
Post
#7
|
. Group: WDG Moderators Posts: 9,653 Joined: 10-August 06 Member No.: 7 |
Opera12, IE11 and Edge get it right. Vivaldi and Firefox rotate.
|
Joe M |
Jul 10 2017, 05:08 PM
Post
#8
|
Group: Members Posts: 4 Joined: 18-September 15 Member No.: 23,548 |
I appreciate the help and replies. I'm glad to hear it doesn't appear to be an html coding problem.
It's not that big a deal. The image itself being wrong does give some explanation. I'll just live with it as is I guess. Thanks again. |
pandy |
Jul 10 2017, 05:35 PM
Post
#9
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,730 Joined: 9-August 06 Member No.: 6 |
Why? Just re-save it with another program.
BTW, just discovered that my other editor (Picture Window Pro) shows the image with the intended orientation if I copy it form the web and paste it in. But not when I save the image to my hard drive and open it the normal way. Which leads me to wonder... Yes, Irfan also shows the not intended orientation when I open the saved image. So it's the Windows clipboard that somehow makes it right. Go figure. |
Joe M |
Jul 10 2017, 07:19 PM
Post
#10
|
Group: Members Posts: 4 Joined: 18-September 15 Member No.: 23,548 |
|
Lo-Fi Version | Time is now: 18th April 2024 - 09:19 PM |