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

191
Views
Javascript Browser Language Redirect - What is wrong?

I really thought this would be a simple task to do. But my JavaScript code makes the browser loop the page indefinitely and I really don't know why. I've tried other solutions from stack overflow, but all of them gave the same result. Here is the code:

SOLVED! THANKS ALL!!!

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I think now it's okay (code at the methark.com/br page):

<script>
        var language = window.navigator.language || navigator.userLanguage;
        var languageFistTwo = language.substr(0,1);
        if(window.location.href == 'http://methark.com/br' && languageFistTwo == 'en'){
        window.location.href = 'http://methark.com';
        }
</script>
about 4 years ago · Juan Pablo Isaza Report
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!