Win a copy of Murach's Python Programming this week in the Jython/Python forum!
    Bookmark Topic Watch Topic
  • New Topic

HttpUrlConnection is not working  RSS feed

 
enkhbat dash
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Report post to moderator
When I copy and paste http://www.google.com/search?q=test in address bar, it works perfectly. But when I using HttpUrlConnection to connect it, it doesn't work. Here is my code.




When I copy and paste link to address bar, it's accessing web via get method right? And code uses get method, too. Any suggestion and help?
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65826
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please do not cross-post the same question in multiple forums. It wastes people's time when multiple redundant conversations take place. Please read this for more information.
 
It is sorta covered in the JavaRanch Style Guide.
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!