The plugin needs to have it’s own folder name and contain the file plugin.php, it needs to be activated through the ‘Plugins’ menu in the administration area.
A simple plugin example adding a message at the start of your homepage.
Top of file (plugin details, commented):
Create the function returning the message.
In the simplest form ever you can use the language system to modify and translate the message.
echo _lang("Welcome to my great website");
Now we hook the function to the 'home-start' action present on top of home.php
Sure, you can use very complex logic and code here and on all the other actions, this is just a very simple example.