Hello. I read about the daniweb api competition thing and I have an idea of what I want to create. I have never done anything webby before (aside from using dreamweaver to make websites) and I think its about time that I did! I am hoping that it is possible for me to use the daniweb api to make a kind of editor in c++. I want to use c++ because it is what I am most familiar in, if it is overly complicated in c++ please tell me what language it wouldn't be complicated in. Anyways I just want to know how to use a web api in c++.

I just finished posting a program on a web site found here that does just that for a different web site. The only thing you could probably use from my program is how to use sockets to access the api from DaniWeb. I have not gone tough DaniWeb's api yet to find out how it works.

It would be nice if we could edit the snippet code and/or description at some later date.

I have never been able to understand sockets... I have tried a couple of tutorials, but understanding them always seems to elude me. Could you maybe point me to a decent tutorial for them, and maybe explain exactly what they are? Thanks.

I use this socket library witten by someone else. It's pretty simple to use.

That is helpful, but I prefer to be able to make something work from scratch before using a library to make it easier. I'm sure I could do what I want with that library, but I wouldn't understand what it was that I was doing. I would prefer an explanation (or a link to an explanation) of what sockets are and how to use them. For example in the first example on that site you sent me they have a line like this:

s.SendLine("GET / HTTP/1.0");

I think I understand that its sending "GET / HTTP/1.0" to the server that the socket is linked to, but what does "GET / HTTP/1.0" mean? How did they know that that is what they wanted sent?

what does "GET / HTTP/1.0" mean?

That is not related to sockets. To understand what that means requiires knowledge about how servers and clients pass data back and forth. Suggest you read tutorials about HTML etc from www.w3schools.com, for example this page explains get and post commands.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.