Code in \lstlisting breaks document (compile error) Thank you David! Yes, I use babel. The problem was that the name of my chapter was "\chapter{Implementation of "`Jiga"'}". I changed it to "\chapter{Implementation of Jiga}" which removed the error.
How to define HTML keywords in \listings Wow. That was easy. I missed the forest for the trees. Thank you! You can write this as a solution, so that I can check off the question.