I'm using Laravel architecture to develop system. i use the way below in blade to achieve RWD.
@if(Agent::isMobile())
//SHOW SOME CODE
@elseif(Agent::isDesktop())
//SHOW SOME CODE
@endif
ps. i use https://github.com/jenssegers/agent to detect
my question is: i want to add a switch button in blade to switch mobile mode to desktop mode. how can i do? i found some information that to change user agent. i change successful by using javascript, but when i reload page, it still detect as mobile.

Comments
Post a Comment