Hi there,
in >GP Hooks >wp_footer I load some JS to animate my site. On mobile devices, I don’t want that JS files to be loaded, because they destroy the layout a little bit.
How can i prevent the JS files from being loaded on a mobile device?
In the case of css files I know that I can write the following:
<link rel="stylesheet" media="(min-width: 672px)" href="abc.css" />
Is there such a thing for JS files too? For the expression <script … ></script>
Probably it works with PHP or a media query in JS – but I don’t know PHP and JS. Can I say with HTML that JS files should only be loaded on large screens? I didn’t find anything on the Internet.
Roland