Hi everyone! I just want to ask, how do I use socket programming in C to open/go to web sites? I want to create a program that should look like this: the program asks for an integer input from the user and depending on the input number, the program invokes and tries to connect to a specific website. For example, if the input is 1, the program will try to connect to htttp://www.yahoo.com and if the input is 2, the program will try to connect to http://www.google.com. The websites will be pre-determined, meaning if the input is 1, the program will go to www.yahoo.com only, the program shouldn't try to connect to random websites. I have Linux as my OS. Any concepts/strategies/links to tutorials/sample codes would be great. I'm relatively new to socket programming so I would really appreciate it if I could see some simple codes on how to implement this. Thank you.
All 3 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.