I am new to HTML5.
I want to create a program in HTML5, but I need also to have a backend which will handle all the logic.

Can I connect a backend which is written in C# or in Java to HTML5? if so how?

My program needs also to handle reading and writing to xml files. I guess that the backend will need to handle this task, but can the HTML side handle it as well?