Jump to content
php.lv forumi

Izshkjirtspeeja


Benvenuto

Recommended Posts

ar php taa iisti nevar, jaanjem talkaa javascript, man pasham patiik ar css:

 

<head>

</head>

<body>

<script>

if (screen.width>1024) {document.write("<LINK rel="stylesheet" href="Framework1.css" type="text/css">")}

else {document.write("<LINK rel="stylesheet" href="Framework2.css" type="text/css">")}

</script>

...

</body>

Link to comment
Share on other sites

Bet, tā, lai pielektu arī PHP:

<script>

var set=0;

if (screen.width>1024 && !set){

location.href=location.href+'?screen=big';

location.reload();

set=1;

}

</script>

čekojam, vai $_GET['screen'] ir bigs utt.

 

Kaut kā tīri ar php varēja dabūt, ja ir pareizs browscap.ini, bet tāds man vēl nav gadījies.

Link to comment
Share on other sites

×
×
  • Create New...