php-whois | PHP class to retrieve WHOIS information | Web Framework library
kandi X-RAY | php-whois Summary
kandi X-RAY | php-whois Summary
PHP class to retrieve WHOIS information.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Get information about the whois server .
- Checks if the user is available
- Check if the domain is valid
- Get html info .
- Get the domain name .
- Get the list of TLDs .
- Returns the sub domain .
php-whois Key Features
php-whois Examples and Code Snippets
Community Discussions
Trending Discussions on php-whois
QUESTION
I'm currently outputting some Whois information on a PHP template (using this) which returns a large block of text via this variable $whois_answer
:
Relevant dates: Registered on: 19-Aug-2015 Expiry date: 19-Aug-2025 Last updated: 21-Sep-2015 Registration status: Registered until expiry date. Name servers: xxx.mainnameserver.com xxx.mainnameserver.com WHOIS lookup made at 09:34:40 10-Nov-2017 -- This WHOIS information is provided for free by Nominet UK the central registry for .uk domain names. This information and the .uk WHOIS are: Copyright Nominet UK 1996 - 2017. You may not access the .uk WHOIS or use any data from it except as permitted by the terms of use available in full at http://www.nominet.uk/whoisterms, which includes restrictions on: (A) use of the data for advertising, or its repackaging, recompilation, redistribution or reuse (B) obscuring, removing or hiding any or all of this notice and (C) exceeding query rate or volume limits. The data is provided on an 'as-is' basis and may lag behind the register. Access may be withdrawn or restricted at any time. Domain is registered
I don't want to amend the original code, just amend the final output (as I may use other functionality at a later date).
I purely want to grab the expiry date of the domain, how can I target that and strip everything else out? Be aware that the domain is dynamic so the date could be anything but will always be in that format.
...ANSWER
Answered 2017-Nov-10 at 10:04Use preg_match:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install php-whois
PHP requires the Visual C runtime (CRT). The Microsoft Visual C++ Redistributable for Visual Studio 2019 is suitable for all these PHP versions, see visualstudio.microsoft.com. You MUST download the x86 CRT for PHP x86 builds and the x64 CRT for PHP x64 builds. The CRT installer supports the /quiet and /norestart command-line switches, so you can also script it.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page