0

I'm recently working on a project where I have classes written in C++ and a website which is written with HTML5 and JavaScript. Now I want to have data from the C++ program sent to the website. Which way is the best to solve that?

I was looking around for AMQP, WebSockets and JSON. But I didn't get how I can use them and what is the best for this problem and how I can use these technologies.

1 Answer 1

2

I recommend to use the C++ webtoolkit Wt (pronounced Witty), at http://www.webtoolkit.eu/.

This framework (with integrated application server) lets you design web applications in terms of widgets and signal/slot connections, and leaves much of the web cruft in the hands of the library. The resulting applications are object-oriented, strictly typed, and perfectly maintainable. The library autodetects the browser's capabilities and uses the proper way to render the site, avoiding browser bugs.

Wt is written in a modern C++ style, which doesn't need to lead to memory leaks and other mishaps that have always been associated with C++ applications. C++ is as good as any other language around. It is not a matter of performance, it is a matter of style.

Sign up to request clarification or add additional context in comments.

8 Comments

I think that is not what I'm looking for exactly. I just have to transfer data from a C++ program to the website which has JavaScript. I don't need to program a whole new website. I just want to get a connection between these two parts and send data.
Thank you. That is something I can work with. How do I setup a connection? Do I have to install a server between these two JavaScript and C++?
You'll need a web server.
I'd suggest to go for Wt. You can use existing website with some modifications. webtoolkit.eu/wt/examples/hello/hello.wt
Thank you. But I don't know how to set up this thing. I have the HTML5 page and the C++ program. What do I do with Witty now?
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.