Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6650901
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T00:56:49+00:00 2026-05-26T00:56:49+00:00

All, I am accessing a web-page through command prompt using simple_html_dom in php as

  • 0

All,

I am accessing a web-page through command prompt using simple_html_dom in php as

  $page = file_get_html($url, false, $context); 

where $url is the web-URL.
If you URL is like http://abc.com/xyz.html?s=“sometext”
Then i am getting proper response.
But I am getting HTTP/1.1 400 Bad Request if the URL has white space in the get parameter like http://abc.com/xyz.html?s=“some text”.

Can anyone please help me how to resolve this issue.

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T00:56:50+00:00Added an answer on May 26, 2026 at 12:56 am

    You need to encode the parameter:

    $text = urlencode('some text');
    $url = "http://abc.com/xyz.html?s=$text";
    $page = file_get_html($url, false, $context); 
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am accessing Lotus and Groupwise using javamail via IMAP, recursively accessing all folders
I am new to PHP+MySQL and followed an example to build a web page.
I'm accessing a database in steps, and making sure that I dispose of all
consider this code: Partial Public Class MyAspNETClass Inherits System.Web.UI.Page Protected Shared MyVariable As String
I'm writing a web page that will detect which college campus a user is
I am trying to design a web page that provides content depending on the
I am using php session for a basic login without encryption for my site.
I am using file_get_contents through proxy to fetch a webpage. This setup was working
In asp.net, c# web applciation, is it possible to prevent bots from accessing a
Now I'm trying to work with System.Web.Routing. All is just fine, but I can't

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.