It is not easily possible to use C++ code in HTML5; but it depends what you really want to do.
You should first understand what HTTP and HTML5 really are, and where you want the C++ code to run (in the browser - on the HTTP client side, or in the server - on the HTTP server side).
If you want to use C++ code on the client side (in the browser), you probably want something like Google Native Client. Not all browsers are supporting it, and your user needs to enable it. You could also consider compiling your C++ code to Javascript with Emscripten.
If you want C++ code on the server side, you may want to use CGI or FastCGI techniques, or make your C++ code a specialized HTTP server by using some HTTP server library (like libonion or Wt)
See also this question.