Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Http post

Http post

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 2 Posters 509 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    satyanarayana143
    wrote on last edited by koahnig
    #1

    Hi friends,

        QNetworkAccessManager *Postmgr2 = new QNetworkAccessManager(this);
        QByteArray schedule_summaryData;
        QString cmd = "access_token="+access_token+"&start=02/21/2019&end=02/21/2019";
        qDebug() << "################ Command: ######################" << cmd;
        schedule_summaryData.append(cmd);
        QUrl request2("http://192.168.0.105:5001/api/yess_scheduleplans/get_schedule_summary?");
        QNetworkRequest r2(request2);
        r2.setRawHeader("Content-Type", "application/json");
        r2.setRawHeader("Accept-Encoding", "gzip");
        r2.setHeader(QNetworkRequest::ContentTypeHeader,"application/x-www-form-urlencoded;charset=UTF-8");
        r2.setRawHeader("Connection", "keep-alive");
        qDebug() << "schedule_summaryData:" << schedule_summaryData;
        Postmgr2->post(r2,schedule_summaryData);
    

    In above code i want to print whole command of Postmgr2 post can anybody give the soultion

    [koahnig:code tags added]

    Pablo J. RoginaP 1 Reply Last reply
    0
    • S satyanarayana143

      Hi friends,

          QNetworkAccessManager *Postmgr2 = new QNetworkAccessManager(this);
          QByteArray schedule_summaryData;
          QString cmd = "access_token="+access_token+"&start=02/21/2019&end=02/21/2019";
          qDebug() << "################ Command: ######################" << cmd;
          schedule_summaryData.append(cmd);
          QUrl request2("http://192.168.0.105:5001/api/yess_scheduleplans/get_schedule_summary?");
          QNetworkRequest r2(request2);
          r2.setRawHeader("Content-Type", "application/json");
          r2.setRawHeader("Accept-Encoding", "gzip");
          r2.setHeader(QNetworkRequest::ContentTypeHeader,"application/x-www-form-urlencoded;charset=UTF-8");
          r2.setRawHeader("Connection", "keep-alive");
          qDebug() << "schedule_summaryData:" << schedule_summaryData;
          Postmgr2->post(r2,schedule_summaryData);
      

      In above code i want to print whole command of Postmgr2 post can anybody give the soultion

      [koahnig:code tags added]

      Pablo J. RoginaP Offline
      Pablo J. RoginaP Offline
      Pablo J. Rogina
      wrote on last edited by
      #2

      @satyanarayana143 maybe using Wireshark to capture the actual network traffic is better to see what is actually being sent...

      Upvote the answer(s) that helped you solve the issue
      Use "Topic Tools" button to mark your post as Solved
      Add screenshots via postimage.org
      Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

      1 Reply Last reply
      2
      • S Offline
        S Offline
        satyanarayana143
        wrote on last edited by
        #3

        without whireshark no way to find post command.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved