While the previous recipe showed how to look up the translation of a text item and return its value for further processing in the plugin code, there are many instances where it is more practical to display the translated content immediately.
This recipe shows how to translate the contents of a simple administration page for immediate display.
You should have already followed the Adapting default user settings for translation recipe to have a starting point for this recipe. Alternatively, you can get the resulting code (Chapter 11/ch11-hello-world/ch11-hello-world-v1.php
) for that recipe from the code bundle. You should rename the file to ch11-hello-world.php
before starting.