Is there a way in wordpress that I can create custom page templates for a mobile version, I mean something like when it detects that is a mobile to load mobile_header.php or is there a better way, I can’t do this only from css I also need to use some custom page templates.
Thanks!
What you could do is create a new theme which is a mobile template specifically. You can then put this code into your functions.php file and it will use the mobile template instead.
You’d have to work out if it is a mobile phone useragent or not though.