My goal is to load a specific CSS file only for iPads. I attempted the following approach:
<link href="/css/ipad.css" rel="stylesheet" media="all and (max-device-width: 1024px)" type="text/css">
While this method successfully loads the iPad stylesheet, it also triggers when I adjust my desktop resolution to 1024 by 768 and view the site in Firefox. To address this issue, I modified the code as follows:
<link href="/css/ipad.css" rel="stylesheet" media="all and (max-device-width: 1024px) and (orientation: landscape)" type="text/css">
However, the problem persists. How can I ensure that this stylesheet is loaded exclusively when the page is viewed on an iPad?