You want to get host records of the domain.

Given a website title (let's say: google.com) I have to obtain the host records (ex: CNAME, TXT etc..records). Can you really have them even if we don't possess the control about the domain (i.e domain not bought by us?

Really, my requirement is the fact that when customers enter domain title during my application (that is in development), I wish to see if the domain goes for them or otherwise (I'll be asking these phones then add random string as TXT record) after which will browse the TXT record of this domain within the after sales and verify the domain. I believe the search engines do this (whenever we setup google applications account). Any pointers in this helps a great deal. Thanks ahead of time.

you are able to only get records from the particular title (hostname or domain title)

To obtain a txt entry from the particular title run:

search TXT [title]

more details about search: http://en.wikipedia.org/wiki/Domain_Information_Groper

If you possess the charge of the dns server from the domain you are able to allow dns zone transfer which allows you to definitely get full configuration of the domain. But, more often than not, this really is forbidden.

Within this situation you'll run search AXFR [domainname]

You should use 'dig' with this in the command line to determine what output you're to obtain for any given domain, then, in php you should use dns_get_record to find the same information.

http://php.internet/manual/en/function.dns-get-record.php

The search command in LInux, can perform that.

For instance:

search stackoverflow.com TXT