Yes you can but you have to make sure that the load current of
the 7805 exceeds the quiecent current of the LM317. (The current
trough the resistive divider.) If there's an additional load connected
between the output of the LM317 and the output of the 7805 you have
to take this extra current in to account as well.
Do you need a higher output voltage than the maximum of the LM317 ?
You can do that without stacking it on top of another regulator on
condition that you don't short circuit or overload it, otherwise the
maximum permissable voltage will be exceeded.
You also could use a TL783 to replace the LM317.
I hooked it up the same way you did, it worked fine. I couldn't
find any instability, but in absence of any load the 750 Ω resistor
should be present, otherwise it's not necessary.
You can also use the LM317 as a preregulator for the 7805.
It is always a good idea to have a small load connected to the regulator's output ..
Instead of a resistor connect a resitor and an LED - this will give you an indication that a voltage is present ..
However, I still think that you should separete both regulators and reference them individually to 0V ..