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. QNetworkAccessManager Problem
QtWS25 Last Chance

QNetworkAccessManager Problem

Scheduled Pinned Locked Moved Unsolved General and Desktop
7 Posts 2 Posters 743 Views
  • 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.
  • jondoeJ Offline
    jondoeJ Offline
    jondoe
    wrote on last edited by jondoe
    #1

    Hello,
    I have xenforo forum and I coded one page in php. This page getting nicknames who entered to forum.
    For example

    When I entering to site on nicknames.php writing my nickname
    Screenshoot
    SS 1

    When I dont entering to site on nicknames.php writing guest.
    Screeshoot
    SS 2

    I getting nicknames with php sessions.

    All is good till here but when I want get this text in QT with QNetworkAccessManager I getting " guest ". I entered site and nicknames.php writing my nickname but QNetworkAccessManager getting this text " guest ". Where is the problem ? How can I fix this ?

    jondoeJ 1 Reply Last reply
    0
    • jondoeJ jondoe

      Hello,
      I have xenforo forum and I coded one page in php. This page getting nicknames who entered to forum.
      For example

      When I entering to site on nicknames.php writing my nickname
      Screenshoot
      SS 1

      When I dont entering to site on nicknames.php writing guest.
      Screeshoot
      SS 2

      I getting nicknames with php sessions.

      All is good till here but when I want get this text in QT with QNetworkAccessManager I getting " guest ". I entered site and nicknames.php writing my nickname but QNetworkAccessManager getting this text " guest ". Where is the problem ? How can I fix this ?

      jondoeJ Offline
      jondoeJ Offline
      jondoe
      wrote on last edited by
      #2

      Please help still I have this problem :(

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi,

        Please show some patience. Allow at least 24 hours before bumping your own thread. The people answering are doing it on a voluntary basis and might not live in the save time zone as you.

        That said, it's impossible to answer your question. You don't give any detail on the backend, on what query is expected, etc.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        jondoeJ 1 Reply Last reply
        1
        • SGaistS SGaist

          Hi,

          Please show some patience. Allow at least 24 hours before bumping your own thread. The people answering are doing it on a voluntary basis and might not live in the save time zone as you.

          That said, it's impossible to answer your question. You don't give any detail on the backend, on what query is expected, etc.

          jondoeJ Offline
          jondoeJ Offline
          jondoe
          wrote on last edited by
          #4

          @SGaist

          hello
          thank you for answer to my thread
          backend nothing I have
          just I have nicknames.php and this php working with session
          if member entering to account on nicknames.php writing them nick
          if dont entering writing " guest "
          I first entering to my account and on nicknames.php writing my nick name all is good
          when my nicknames writing on nicknames.php I want get this text with QNetworkAccessManager
          I getting
          But I got " guest "
          in nicknames.php writing my nick name but when I getting this text with QNetworkAccessManager writing " guest ".

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #5

            How are you doing your requests with QNetworkAccessManager ?

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            jondoeJ 1 Reply Last reply
            0
            • SGaistS SGaist

              How are you doing your requests with QNetworkAccessManager ?

              jondoeJ Offline
              jondoeJ Offline
              jondoe
              wrote on last edited by
              #6

              @SGaist

              I do like this.

              QString newsurlgiris = "https://siteurl/nicknames.php";
              
                   QNetworkAccessManager LManager33;
                   QNetworkReply* reply33 = LManager33.get(QNetworkRequest(QUrl(newsurlgiris)));
                   QEventLoop event33;
                   connect(reply33, SIGNAL(finished()), &event33, SLOT(quit()));
                   event33.exec();
              
                   QString newsurl = reply33->readAll();
              
                   qDebug() << "---->" << newsurl;
              
              1 Reply Last reply
              0
              • SGaistS Offline
                SGaistS Offline
                SGaist
                Lifetime Qt Champion
                wrote on last edited by
                #7

                From the looks of it, you didn't login using QNetworkAccessManager.

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                1

                • Login

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