In Object Mode, you manipulate Objects. In Edit Mode, you manipulate meshes.
In Object Mode, press spacebar in the 3D View and go to Transform > Clear/Apply > Clear Rotation to set your Object back to standard orientation.
In Edit Mode, rotate your mesh so that it's rotated how you would like it to appear in Second Life.
Object Mode vs Edit Mode
By now, you've probably switched between Object Mode and Edit Mode enough to be comfortable with both, but do you really understand the difference?
When you are in Object Mode, your are editing Objects. When you're in Edit Mode, you're editing Meshes and there is a BIG difference between the two. I won't get into all the techinical details here, but I'll just give you what you need.
Objects ALWAYS have a standard orientation. A state in which they are "right-side up" and "facing forward." If you rotated your sculpt mesh while in Object Mode, the Object is now in a state of rotation. It is NO LONGER at their standard orientation. Blender considers it to be rotated.
In Edit Mode, however, no matter HOW much you rotate the mesh, twist it around, or move it, it's actual rotation stays relative TO THE OBJECT.
Let's give you an example. Lets say you rotate your template in Object Mode. Then you rotate it BACK in Edit Mode:


Your template is now rotated, whether it looks like it or not. If you bake your sculpt map at this point and upload it into Second Life, it will be at an angle.
On a side note:
The images above show you one of the many differences between Objects and Meshes. In Object Mode, the Object rotates around the pink Center Point by default, no matter where this point is. The mesh, in Edit Mode, rotates around the absolute center of all the selected points. The same is true for scaling and grabbing.
So before we can re-orient our Mesh with any success, we need to re-orient the Object to its Standard Orientation. Thankfully, this is really easy to do in Blender. In Object Mode, with the cursor in the 3D View window, tap spacebar to bring up a menu. Select Transform > Clear/Apply > Clear Rotation.


Notice that you could clear the Location and Scale as well, but none of these effects how a mesh will look in Second Life. Now that you have the Rotation cleared, you can go into Edit Mode and rotate the mesh to the correct orientation.
Alternatively, you can select Transform > Clear/Apply > Apply Scale/Rotation to make the reset the standard orientation. I had you use "Clear Rotation" here so you could better understand why your mesh was rotated in Second Life.
Now that you have your Object re-oriented, and your mesh rotated to how you want it in Second Life, rebake your sculpt map and upload it.
Also note that when you Mirror a mesh in Blender using the M key (
see this tutorial), it doesn't mirror the Object rotation, so if you tried to mirror a rotated sculpt with this method, each sculpt would end up with a completely different rotation, and would scale differently. This is why it's usually better to mirror a sculpt in an image editor than in Blender.