I actually have the exact answer you're looking for. I searched everywhere for this answer and nothing anyone suggested worked perfectly. So, I thought up a solution and tried it and was floored that it worked without any flaw!
Garrow was actually right (he just didn't explain it or take it all the way). The solution is instead of putting "& nbsp;" alone, put "& nbsp;< wbr>". (remove the spaces of course). Just do a simple search and replace and add the < wbr> tag after every & nbsp;. Works perfectly!
The < wbr> tag is a little known tag supported in all major browsers that tells the browser to put a newline here ONLY if it is needed.
Update: I found one browser that this doesn't work exactly right in - IE 8! They actually took out the < wbr> tag!. I solved this issue by creating a class that says:
.wbr:before { content: "\200B" }
and instead of replacing "& nbsp;" with "& nbsp;< wbr>", replace it with the following:
& nbsp;<wbr><span class='wbr'></span>
In php, this would look like:
$text = str_replace(" ","& nbsp;<wbr><span class='wbr'></span>", $text);
Don't forget to add the class as well.
Obviously this is getting quite a bit excessive, replacing a single space with all of that, but it does work just as desired and since I never saw the markup it worked for me.
If this is too messy, another solution is to exchange double spaces for a nbsp followed by a normal space. This will alternate nbsp and normal spaces and works in my tests.
In php, this would look like:
$text = str_replace(" ","& nbsp; ", $text);
Hope this helps! I put enough research into this, I thought I should pass it on.