Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

157
Views
¿Cómo puedo agregar este javascript en mi php?

Microsoft dice que podemos usar el siguiente javascript para detectar Windows 11 (en el lado del cliente):

 navigator.userAgentData.getHighEntropyValues( ["architecture", "model", "platform", "platformVersion", "uaFullVersion"]) .then(ua => { console.log(ua) });

La respuesta debería ser como: versión de platformVersion: "14.0.0" .

Necesito usar esto como una variable en mi PHP para detectar si un usuario está usando Windows 11:

 if(is_browser_request()){ $user_agent = $_SERVER['HTTP_USER_AGENT']; $systemid = $_SERVER['HTTP_SEC_CH_UA_PLATFORM']; $version = Unknown how to define if (stripos($user_agent, "iPhone")!==false) { $brand = 'iPhone'; } else if ($version == "14.0.0") { $brand = 'Win11'; } else if ($version == "10.0.0") { $brand = 'Win10';

¿Esto tiene sentido? ¿Cómo puedo agregar el javascript en mi php y definir la versión de $?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!