Php page determines whether a user has a page language

Source: Internet
Author: User
Php page judgment user generated page language I now use opencart to design web pages, using two languages, simplified, traditional, currency RMB, HKD encountered a problem: how can I determine which language to use based on the user, and show only one language and the other hidden? Determine the currency, RMB, and HKD based on the language used? Determine zh or zh-hk through the lang submitted by the user. but how does lang work here? Maybe I do not purchase clear php pages to determine the language on which the user generates the page
I now use opencart to design web pages, using two languages: simplified, traditional, currency RMB, HKD
Encountered a problem:
How can I determine which language to use based on the user, and show only one language and the other hidden?
Determine the currency, RMB, and HKD based on the language used?
Determine zh or zh-hk by using the lang submitted by the user.
But how does lang work?
Maybe I am not clear about the purchase. But some people are willing to tell me how to design the change?


------ Solution --------------------
You can obtain $ _ SERVER ['http _ ACCEPT_LANGUAGE '] for judgment, and then jump to the instruction language page for processing.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.