June 16, 2012

ommz ommz
Lab Rat
15 posts

[SOLVED] Simple socket client inside app

 

I want to send the contents of a QLineEdit to a php web app that is listening on that port. Someone please show me a simple code snippet of the client source code

6 replies

June 16, 2012

tucnak tucnak
Robot Herder
384 posts

You should use QNetworkAccessManager [qt-project.org] instead of sockets.

Read about it and if you will have questions, ask here.

 Signature 

Qt Developer (upper-intermediate)
PHP/JS Developer (intermediate)

June 16, 2012

ommz ommz
Lab Rat
15 posts

Thainks a tonne. It works!!

June 20, 2012

tucnak tucnak
Robot Herder
384 posts

  1. Thread * current = devnet->currentThread();
  2. QString title = current->title();
  3. title.prepend("[SOLVED] ");
  4. current->setTitle(title);
  5. current->update();

 Signature 

Qt Developer (upper-intermediate)
PHP/JS Developer (intermediate)

June 20, 2012

mlong mlong
Mad Scientist
1517 posts

In other words, please be sure and edit the title of the thread to add [Solved] to the beginning of the title. Thanks ever so much!

 Signature 

Senior Software Engineer
AccuWeather Enterprise Solutions
/* My views and opinions do not necessarily reflect those of my employer.  Void where prohibited. */

June 21, 2012

tucnak tucnak
Robot Herder
384 posts
mlong wrote:
In other words, please be sure and edit the title of the thread to add [Solved] to the beginning of the title. Thanks ever so much!

Have you thought about it? Can moderators add this tags (SOLVED)?

 Signature 

Qt Developer (upper-intermediate)
PHP/JS Developer (intermediate)

June 21, 2012

mlong mlong
Mad Scientist
1517 posts

Moderators can edit the post titles, but that’s really the task of the thread owner. ;-)

 Signature 

Senior Software Engineer
AccuWeather Enterprise Solutions
/* My views and opinions do not necessarily reflect those of my employer.  Void where prohibited. */

 
  ‹‹ qmake: import an OSX framework from ~/Library/Frameworks      Custom control ››

You must log in to post a reply. Not a member yet? Register here!