Results 1 to 13 of 13

Thread: QNetworkAccessManager and post method

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Apr 2011
    Posts
    27
    Qt products
    Qt3 Qt4
    Platforms
    Symbian S60

    Post QNetworkAccessManager and post method

    sir ,

    i have been make server connection through the QNetworkAccessManager but i want to make post method and send name, userid, and possword to server please help how to make post method in Qt.see my code
    Qt Code:
    1. nam = new QNetworkAccessManager(this);
    2. QObject::connect(nam, SIGNAL(finished(QNetworkReply*)),
    3. this, SLOT(finishedSlot(QNetworkReply*)));
    4.  
    5. QUrl url(QLatin1String("http://taxinomics.com/mobile/Login.php?mobilenumber=number&password=m"));
    To copy to clipboard, switch view to plain text mode 
    this is get method i want to make post method how to make.i beginner for Qt.
    Thanks
    Last edited by wysota; 13th June 2011 at 00:34. Reason: missing [code] tags

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: QNetworkAccessManager and post method

    What was wrong with your earlier thread? You start these threads and as soon as it becomes apparent that no-one is going to post the exact, fully working solution within a day or so you just drop the thread only to come back later with the same question.

    To convert a GET to a POST you take the parameters you were encoding into the URL and put them in the POST request content with the relevant headers. The previous thread gives you all the components to achieve this.
    "We can't solve problems by using the same kind of thinking we used when we created them." -- Einstein
    If you are posting code then please use [code] [/code] tags around it - makes addressing the problem easier.

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QNetworkAccessManager and post method

    Threads merged. Please don't multipost ever again.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. HTTP Post from QNetworkAccessManager - no data sent
    By secureboot in forum Qt Programming
    Replies: 1
    Last Post: 13th April 2011, 18:46
  2. POST and QNetworkAccessManager
    By hakermania in forum Newbie
    Replies: 1
    Last Post: 13th February 2011, 00:05
  3. Replies: 0
    Last Post: 21st December 2009, 05:04
  4. QNetworkAccessManager::post() never returns
    By danc81 in forum Qt Programming
    Replies: 2
    Last Post: 21st October 2009, 09:13
  5. QNetworkAccessManager double post
    By QPlace in forum Qt Programming
    Replies: 1
    Last Post: 11th February 2009, 04:44

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.