# How can I copy-paste questions/answers with the latex symbols intact?

Some answers in physics.stackexchange seem to me so extremely brilliant! I would like to join some of the best ones in a single document by copy-paste. How can I do that, preserving the LaTeX code?

(Some of the gems happen even in very innocent questions... I don't know how many people have I already told in the last weeks, about that answer to the question "why the kinetic energy goes as $v^{2}$ " involving two pieces of clay and a thermometer...)

Direct copy-paste works if it's an HTML document in Word. Sometimes.

Otherwise, here's a trick: open about:blank (URL bar), type javascript:document.body.contentEditable=true in the URL bar and hit Enter. Now, copy-paste the LaTeX-formatted stuff. It ought to work. You can type and modify stuff as well. Then, save the HTML document and/or print to pdf. This userscript may help in cleaning up posts for better copy-pasting

Note that you should attribute the owner of each post (see here).

If you want un-mathified LaTeX source:

• For individual equations: right click, show math as>TeX commands
• For the whole post: Click "edit", copy-paste the source code to here, see the preview.
• Does the trick work in any browser? – Qmechanic Nov 23 '12 at 1:47
• @Qmechanic: Pretty much. Older versions of FF and IE won't support it. And FF/IE don't have a built in print-to-pdf, you have to have Acrobat installed. But for all intents and purposes, yeah, it works everywhere :) – Manishearth Nov 23 '12 at 1:48
• That doesn't seem to work (firefox, kubuntu 10.04, java installed) – Eduardo Guerras Valera Nov 23 '12 at 13:38
• Isn't there any way to simply make my navigator show latex commands instead of rendered formulas? I remember to have seen it somewhere... – Eduardo Guerras Valera Nov 23 '12 at 13:40
• @Eduardo: Right click on the formula, a little menu shows up. Show math as>TeX commands. If you want to see the commands embedded in the post, copy-paste the source (you can find it via "edit"), into the meta.physics "ask question" box, and look in the preview area. That will unmathify everything. – Manishearth Nov 23 '12 at 13:47
• @Eduardo: Hmm, yeah, it seems to depend. On Chrome it works, but some formatting is lost... – Manishearth Nov 23 '12 at 13:48
• Oh, finding the source via "edit" is nice enough, thanks! (I was thinking I couldn't do it without much reputation). If you add that to your answer, I'll mark it as "answered". – Eduardo Guerras Valera Nov 23 '12 at 14:13
• @Eduardo: Done :) – Manishearth Nov 23 '12 at 14:16