jeremykendall / php-domain-parser

Public Suffix List based domain parsing implemented in PHP
MIT License
1.16k stars 128 forks source link

Documentation improvement #352

Closed cvladan closed 1 year ago

cvladan commented 1 year ago

I had to consult ChatGPT for assistance, as the terminology was unclear to me. It even seems as if the AI is not entirely certain.

image

Might it be possible to incorporate an explanation about this in the README file? Preferably, not buried deep within the document, but rather presented at the beginning in the simplest manner.

Once again, I extend my gratitude to the author for his efforts in creating this useful library!

nyamsprod commented 1 year ago

@cvladan thanks for your remarks. I believe the terminilogy used is the correct one coming from RFC and other official documentation. The package does indeed takes the stand that term like

are known from the user consuming the package. I may either provide a link to the official documentation or provide further explanation if needed. In the meantime I believe the second paragraph of the documentation:

Consider the domain www.pref.okinawa.jp. In this domain, the public suffix portion is okinawa.jp, the registrable domain is pref.okinawa.jp, the subdomain is www and the second level domain is pref. You can't regex that.

does provide a perfect example and explanation of each part of a domain