wp_is_mobile() native function not working correctly with w3tc
-
I’m using the native function wp_is_mobile() to present diferent content if user is mobile or not
The problem is that when I access my site on my mobile android phone, SOMETIMES (only sometimes) it presents me the content that I have define to appear only on desktop devices.
I say that this is a problem on w3tc because when I clean al caches, my site presents the content respecting this code.
<?php if (!wp_is_mobile()) :?> my code if it's not mobile <?php else: ?> my code if it's mobile <?php endif; ?>
Any help pointing me out the way to solve this is very welcome.
Thanks!
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘wp_is_mobile() native function not working correctly with w3tc’ is closed to new replies.