Click here to Skip to main content
12,248,339 members (43,060 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: C++ HTML
I want C++ coding in Html, is it possible ?
Posted 13-May-11 20:34pm
Edited 13-May-11 20:51pm
v2
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 2

Your question is very vague, so let me answer the question "How to interact with HTML using C++?"

1. The most obvious way is to emit HTML using a program written in C++. Example: XHtmlLog - Convert text log files to HTML[^]

2. Next, you could write an addin for a browser using C++. I have not done this personally, but I'm sure google will have many hits.

3. You could host the Microsoft HTML control in a program using C++. There are some articles here on CodeProject that discuss this.

4. You could access the HTML DOM hierarchy of a browser using Microsoft's MSAA accessibility SDK. This allows you to view the elements and properties of a HTML document.

5. You want to display some C++ code on a HTML page, with syntax coloring. There are some articles here on that topic.

If you can provide more information as to what you're trying to do, we will be able to help you better.
  Permalink  
v2
Comments
SAKryukov 14-May-11 17:25pm
   
Did you do your best to attribute at least some sense to something which does not have sense at all? If so, you're pretty inventive, my 5.

I decided to complement this exercise with just one more item.
Please see, hope you find it funny.
--SA
Hans Dietrich 14-May-11 18:41pm
   
I did my best to understand that the OP had a real question. I don't think a lack of vocabulary should be penalized. So, as always, I believe there is no such thing as a bad question, although in this case it could have been phrased a little better.
SAKryukov 16-May-11 3:56am
   
Your opinion of question if kind of unusual. Ideally, you may be right, but, taking into account limited resources, having questions of different quality (more importantly, lazy and good hard-working people) and other factor, some questions are steeling attention from good ones. You cannot deny some do not deserve any attention, or... do you? :-)
--SA
Hans Dietrich 16-May-11 4:40am
   
You are correct; one has to give attention where there is best opportunity to help and to teach. At the same time, I refuse to be be judgmental. My choice of which question to answer does *not* mean other questions do not deserve a serious, professional answer.
S Mewara 15-May-11 2:02am
   
I agree to you here that it was badly formed question and not a 'bad' question. Thus, I did not down vote.

But, I will try to share few 'bad' questions with you in future and get your thoughts on the same.
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 3

The whole question really does not make sense.

I hope I will not increase amount of evil in the world if in return I'll add my answer which has little sense, but not exactly zero sense.

So,
  1. Get some C++ code, highlight and copy it to the clipboard.
  2. Open the following CodeProject page: http://www.codeproject.com/Questions/ask.aspx[^].
  3. Select radio button "encode HTML characters".
  4. Past C++ code in the big text area.
  5. Sandwich selected text in <pre lang="cpp">[you C++ text here]</pre>.
  6. If this is part of your question about C++, add all the details, issue report; comment your C++ source code with exception information and exact lines where exception was thrown or do same thing with compilation errors/warning.
  7. If this is not your question, copy obtained HTML code to clipboard and use somewhere — you "converted" C++ to HTML.

—SA
  Permalink  
Comments
Hans Dietrich 14-May-11 18:36pm
   
Evil. God will get you for this.
SAKryukov 15-May-11 12:13pm
   
Ha ha ha.
S Mewara 15-May-11 2:03am
   
:laugh:
Take my 5 for the humor.
SAKryukov 15-May-11 12:17pm
   
Thank you, Sandeep.
(By the way, why? What if someone have trouble presenting code in HTML? Remember how many posts has broken formatting because of "<" in the middle of code? :-)
--SA
S Mewara 15-May-11 12:26pm
   
Haha! Right... okay... 5 for 'no-humor' :-)
SAKryukov 16-May-11 3:52am
   
:-)
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

Your question does not make much sense. Overall, no, you cannot do a C++ code in HTML.
  Permalink  
Comments
Richard MacCutchan 14-May-11 5:04am
   
You are too kind, the question does not make any sense.
SAKryukov 14-May-11 15:20pm
   
Agree with Richard. My 5.
--SA
SAKryukov 14-May-11 17:23pm
   
I agree, but I just added my answer which at least has some little sense, hope you find it funny.
Please see.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web02 | 2.8.160426.1 | Last Updated 15 May 2011
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100