LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 07-02-2005, 08:23 AM   #1
caminoix
Member
 
Registered: Mar 2005
Location: cracow, poland
Distribution: Linnex, Gentoo, KateOS, PLD
Posts: 53

Rep: Reputation: 15
simple networking in c++


hello

i'd like to write a simple program in c++ that would go to a couple of websites, extract a few sentences and write them to a file on my disk.

could you please tell me how i could do it or where i could look for help?
 
Old 07-02-2005, 08:57 AM   #2
NCC-1701&NCC-1701-D
Member
 
Registered: May 2005
Distribution: Debian Woody,Knoppix
Posts: 88

Rep: Reputation: 16
Have a look at
http://www.linuxgazette.com/issue74/tougher.html#3.2
Hope it helped!
 
Old 07-02-2005, 11:16 AM   #3
caminoix
Member
 
Registered: Mar 2005
Location: cracow, poland
Distribution: Linnex, Gentoo, KateOS, PLD
Posts: 53

Original Poster
Rep: Reputation: 15
it looks helpful, thanks
still, it doesn't seem too easy, at least at first glance. i'm just beginning my c++, and i'm not desperate to stick with it.
could you tell me please whether such a task would be easier with other languages? python perhaps?

ps. it's not for getting mails to spam i need it to getting to sites like www.warez.com and extracting the number of users for purely statistical purposes.

Last edited by caminoix; 07-02-2005 at 11:18 AM.
 
Old 07-02-2005, 03:01 PM   #4
NCC-1701&NCC-1701-D
Member
 
Registered: May 2005
Distribution: Debian Woody,Knoppix
Posts: 88

Rep: Reputation: 16
Personally, I use(and prefer) more C than C++,not only in socket programming. I don't think it's going to be easier,unless you get familiar.Have a look at
http://pont.net/socket/
http://www.cs.wustl.edu/~schmidt/cs544/socket1.html
for c socket programming. If you find c/c++ to difficult, try using java sockets,
http://www.javaworld.com/javaworld/j...2-sockets.html

I cannot tell you about other languages because i'm unfamiliar with them!
Hope it helped!
 
Old 07-03-2005, 06:30 AM   #5
caminoix
Member
 
Registered: Mar 2005
Location: cracow, poland
Distribution: Linnex, Gentoo, KateOS, PLD
Posts: 53

Original Poster
Rep: Reputation: 15
hmm... it doesn't look just too easy
i started learning python. i don't yet know what's ahead of me but so far it's gee so easy! i found a nice help on networking in python and it seems like you can get round the whole socket stuff with it. i'll see what i can do and if i can't do it, i'll be back to c/c++.

thank you for help, anyway
 
Old 07-03-2005, 08:44 AM   #6
Michael Johnson
Member
 
Registered: Jul 2005
Location: Wagga Wagga, Australia
Posts: 262

Rep: Reputation: 30
I f you have Qt installed it has a QSocket part that I use in my projects. I also use kdevelop for my development.
 
Old 07-04-2005, 03:32 PM   #7
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,991

Rep: Reputation: 76
This doesn't really sound like a socket-level problem to me. Perl has some rather nice support for various protocols, including SMTP, HTTP and so on, that will probably do the job. Take a look at the modules on http://www.cpan.org
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Simple Networking Pen Linux - Networking 7 09-09-2004 10:27 PM
Hi, Simple networking help please WarriorWarren Linux - Networking 1 08-23-2004 07:58 AM
simple networking question ruwach Linux - Networking 5 08-02-2004 08:25 AM
Simple networking jmweb Linux - Networking 6 09-21-2003 02:56 PM
simple networking...please! g4hlr Linux - Newbie 2 09-15-2003 08:16 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration