Results 1 to 2 of 2

Thread: qhttp

  1. #1
    Join Date
    Jan 2006
    Location
    Grenoble, France
    Posts
    165
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    106

    Default qhttp

    2nd try with ie rather than firefox...

    when i use :
    Qt Code:
    1. //*****************************************************************************
    2. void ApplicationWindow::receivePbStartAmazonFr()
    3. //*****************************************************************************
    4. {
    5. // indicate that now we have to wait
    6. QApplication::setOverrideCursor( QCursor( Qt::WaitCursor ) );
    7. // target url
    8. QUrl url("http://www.amazon.fr");
    9. // http://www.amazon.fr/exec/obidos/tg/browse/-/405320
    10. // http://www.amazon.fr
    11. http = new QHttp(this);
    12. connect(http, SIGNAL(requestFinished(int, bool)), this, SLOT(receiveP01AmazonFr(int, bool)));
    13. // remember to set the host
    14. http->setHost(url.host());
    15. // the resulting data will be stored in the buffer
    16. buffer = new QBuffer(this);
    17. http->get(url.toString(), buffer);
    18. }
    To copy to clipboard, switch view to plain text mode 
    I get a valid buffer but two errors :
    - An unknown error has occurred. (int=1)
    - The host name lookup failed. (int=2)
    If I use the redirection url returned i get no buffer and the same two errors.
    Can somebody help me ?
    Last edited by jacek; 1st August 2006 at 21:01. Reason: fixed URLs inside [ code ] tags

  2. #2
    Join Date
    Jan 2006
    Location
    Grenoble, France
    Posts
    165
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    106

    Default Re: qhttp

    you can ignore the additional html coding.
    i can't make it disappear.
    it is not in the code, the code has just h t t p : / / w w w...

Similar Threads

  1. how to use QHttp inside QThread in Qt3
    By alusuel in forum Qt Programming
    Replies: 3
    Last Post: 14th July 2006, 12:19
  2. QHttp related
    By whoops.slo in forum Qt Programming
    Replies: 12
    Last Post: 20th June 2006, 21:57
  3. using Qhttp with www(x) sites
    By importantman in forum Qt Programming
    Replies: 18
    Last Post: 4th April 2006, 01:12
  4. Help with QHttp needed.
    By bitChanger in forum Qt Programming
    Replies: 5
    Last Post: 25th January 2006, 22:09
  5. MultiThreading n Qhttp
    By Shambhavi in forum Qt Programming
    Replies: 1
    Last Post: 18th January 2006, 14:36

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.