What is the correct practice for php computer version and mobile version?

the method I am using now is either very correct for
, or using css to determine the accuracy. If it is higher than 1000, it is the traditional version
, lower than 999 is the mobile version
, and then use display:none to turn it on

.
<div class="desktop">style</div>

<div class="device">style</div>

but the css of the content can also be changed due to settings.
the point is that if you directly use the mouse to pull the window left and right, you can know how the mobile version and the computer version
is missing from all versions of the content.
some can use css to determine the mobile version and the computer version,
but some versions are too traditional, and there is too much difference between the computer version and the mobile version. I think there is a better way to solve
by using css.

You can use two sets of templates when the

page is too complex. The back end determines that the ua, will load the template of the mobile terminal if it is mobile, otherwise the template of the PC side will be loaded. As for quickly viewing the page of a certain end, you can add a get parameter to force the backend to load the template of a certain end


, which is not complicated and can be adaptive

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b35f34-2bfcf.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b35f34-2bfcf.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?