Here are four photos taken with my Samsung S4 mini cell phone. Note the orientation of the photo as you see it here on SMC and how the phone was oriented when the photo was taken. All these photos when viewed on the phone have the lighthouse upright.
20171011_155426.jpg Taken with the phone upright
20171011_155419.jpg Taken with the phone with the left side up
20171011_155414.jpg Taken with the phone upside down
20171011_155409.jpg Taken with the phone with the right side up
You can save yourself problems by always holding your cell phone so the top is up or by opening your photos in a photo editing program and changing the orientation before uploading them.