Most of the time a simple comment asking for clarification is the best solution.
Sometimes I comment with things like "It sounds like XXXXX. Can you confirm this?" and typically I get a response from the OP. If positive, I can post my answer. If negative, I'll edit the question to include that information.
There are other times when I'm fairly positive I understand the problem and can provide a solution, even though the OP was a little unclear and I might be mistaken, so I'll post my answer anyways. In these cases I'll begin with something like "It sounds like you're trying to do xxxxx, so... " to be clear that my answer is based on a specific scenario. Often I'll also finish with something like "If this is not the case.... " and include an alternative solution for other scenarios if I can as well.
For me, the whole point of answering is to help people with problems. If my answer helps the OP, I've accomplished my goal. If I'm wrong with my guess, chances are someone will come along with a similar problem that matches my guess, and I end up helping someone else, also achieving this goal.
I guess the whole point is, if you have a good answer and are reasonably sure you know what the OP is asking, post your answer. Just be clear the answer is only valid for X situation.
If you're not sure, simply ask for clarification in a comment instead.