1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2002
    Rep Power

    Question Help in C++ to open the URL Coonection

    I am a Java Programmer. I am new to C++.
    I want to open the url connection in C++.
    Can anyone guide me ??
    I'll be greatful if anyone helps me with an example.
  2. #2
  3. Banned ;)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2001
    Woodland Hills, Los Angeles County, California, USA
    Rep Power
    If you're using Visual C++ and the Microsoft Foundation Classes (MFC), you might want to start here for an overview of the functions and some sample code.

    If you want to be really macho about it, you can do your own socket programming to open an HTTP connection, but there are lots of class libraries (both free and commercial) that have the protocols neatly encapsulated into objects.
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed God 1st Plane (5500 - 5999 posts)

    Join Date
    Oct 2000
    Back in the real world.
    Rep Power
    "maso" is what i would call it...

    The language C / C++ is mainly for low-level programming, java is for mainly for high-level stuff. Eg. thus C does not implement anything but output to / from text consoles and no graphix.

    you need libraries for anything or you need to start with programming your own "drivers" for everything you want to do.
    java comes with 100īs of libraries already ("classes"), like the applet.Applet class which contains your method "getUrl()"

    for C / C++ this would mean: get a pre-made class that already contains your needed functions or you need a good book about tcp/ip and the http protocols. really a lot of work.

    i would prefer java for this task. if you have the choice ;)

    but then - if you want to learn C / C++, you will anyway need to learn a lot about pc- and os architectures, networking and drivers. i really do recommend this, it can be a lot of fun to learn this way how java was derived from C and how programs work "behind the scenes" (and all the other "fun" stuff) :)

    Did you ever try assembler? this is the most hard-core stuff to do in this direction. but C is like the "connection" between assembler and java - if you know the other two, youīll have a good time using C / C++

IMN logo majestic logo threadwatch logo seochat tools logo