When you are going to be offline for awhile (because you are going to work, school, you are going to sleep, or because you have a life outside of Evony) schedule things that take a long time to do. Build walls, town halls, and things that may take 8 hours or 40 hours or whatever to complete. Don’t forget to setup research for high level skills that take a long time to train. (Archery 10 can take 100+ hours to complete for example.) Also make sure you schedule multiple batches of troops to be trained so that they are training the entire time you are offline.
If you’re going to be away for awhile you might consider sending an army or two to help defend your allies and be garrisoned in their city.
If you’re afraid your army might be destroyed in attacks on your city you can close your gates. Some people prefer to send their armies to the other side of the world while they are going to be offline so that there army can’t be destroyed in battle. (That way they don’t forget to open their gates when they come back online.) You can send them to a flat or valley a few hundred miles away. Your troops will be marching overnight so they won’t be home in your city to be destroyed in battle.