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 593483
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T15:51:02+00:00 2026-05-13T15:51:02+00:00

Response example for MD5 hash found, for example http://md5.noisette.ch/md5.php?hash=2a0231531bc1a7fc29e2fa8d64352ae9 : <md5lookup> <hash>2a0231531bc1a7fc29e2fa8d64352ae9</hash> <string>noisette</string> </md5lookup>

  • 0
Response example for MD5 hash found, for example http://md5.noisette.ch/md5.php?hash=2a0231531bc1a7fc29e2fa8d64352ae9 :

<md5lookup>
  <hash>2a0231531bc1a7fc29e2fa8d64352ae9</hash>
  <string>noisette</string>
</md5lookup>

Response for MD5 hash *not* found, for example http://md5.noisette.ch/md5.php?hash=11111111111111111111111111111111 :

<md5lookup>
  <error>
    No value in MD5 database for this hash.
  </error>
</md5lookup>

Response for MD5 hash *not* found, for example http://md5.noisette.ch/md5.php?hash=1 :

<md5lookup>
  <error>
    The string provided is not a true MD5 hash. Please try again.
  </error>
</md5lookup>

Okay I’m just learning how to use SimpleXML. I’m running a script to run similar API’s from different sites, but this is different. I’m not sure how I would use PHP to echo the error if it were an error or the string if it were a success. The API’s I’m using now have just have true or false but its still the same hierarchy no matter the result.

For example

http://gdataonline.com/qkhash.php?mode=xml&hash=notanactualhashandwillnotbefound
That hash will not be found.
http://gdataonline.com/qkhash.php?mode=xml&hash=098f6bcd4621d373cade4e832627b4f6
That hash will return “test”

As you can see the hierarchy will be the same, and thus easy to parse and echo

  • 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-13T15:51:03+00:00Added an answer on May 13, 2026 at 3:51 pm

    I’m not sure I understand what you are asking, but you simply load the URL to SimpleXml and access the nodes by regular object notation, e.g.

    $parentNode->childNode
    

    The example below will load the XML from the URL and output the error if it exists and if not it will output the string node.

    $baseUrl = 'http://md5.noisette.ch/md5.php?hash=';
    $hashes  =  array('2a0231531bc1a7fc29e2fa8d64352ae9',
                      '11111111111111111111111111111111',
                      'not a hash');
    
    foreach($hashes as $hash) {
    
        // load the XML from the URL
        $dom = simplexml_load_file($baseUrl . $hash);
    
        if($dom->error) {
            echo $dom->error;
        } else {
            echo $hash, ' : ', $dom->string;
        }
    
        echo PHP_EOL; // linebreak
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In http://www.anyexample.com/programming/java/java_simple_class_to_compute_md5_hash.xml an example is given how to calculate an MD5 hash of String.
I am trying to read in a string from a C# Response.Write(string example) into
I have the following XML: <ns:response xmlns:ns=http://example.com xmlns:ax=http://example.com/xsd > <ns:return type=mytype> <ax:roleID>1</ax:roleID> <ax:roleName>ADM</ax:roleName> </ns:return>
I'd like to move an asp.net mvc response to http://example.com/emails/list/rob@email.com Using RedirectToAction(list, emails, new
Why can't I redirect page to a image for example: Response.Redirect(http://www.domain.com/images/image.gif); This doesn't show
Consider the following code sending an HTTP 201 Created response to the client: String
I'm using PHP and since this server response is not pure XML I've been
My application receives email from users. A response from gmail, for example, comes in
response.setHeader(keys[i].toString(),value); in a servlet is throwing null pointer exception even though none of keys[i]
Response to : Regular Expression to find a string included between two characters while

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.