If I have an international website and I have two clients:
- client from Spain.
- client from Israel.
I want the placeholder will be match for the client user.
The pseudo-code is:
if (client_from_israel)
HTML CODE: <input type="text" placeholder="israel">
else
HTML CODE: <input type="text" placeholder="spain">
How can I write it to work and display at the web browser?
I think I will need to use php to do it.
I know its a LONG answer but if you don’t have the power to write the code just tell me what to do in general.
You could get the user’s IP address through $_SERVER[‘REMOTE_ADDR’] and then use some geotargeting class to translate it to a country.
I found a good tutorial on this subject. You can of course use a free PHP geotargeting class for your project