utopia-php / domains Goto Github PK
View Code? Open in Web Editor NEWLite & fast micro PHP domain parsing library that is **easy to use**.
License: MIT License
Lite & fast micro PHP domain parsing library that is **easy to use**.
License: MIT License
I dont think that this result is expected, also getRegisterable returns the complete domain name with the subdomain in it.
Example:
Utopia\Domains\Domain Object
(
[domain:protected] => notcivil.blogspot.com
[TLD:protected] =>
[suffix:protected] =>
[name:protected] =>
[sub:protected] =>
[parts:protected] => Array
(
[0] => notcivil
[1] => blogspot
[2] => com
)
)
Invoked via
require_once(dirname(__FILE__) . "/vendor/autoload.php");
$domain = new \Utopia\Domains\Domain("notcivil.blogspot.com");
GitHub has recently rolled out a public beta for their issue forms feature. This would allow you to create interactive issue templates and validate them ๐คฏ.
Appwrite currently uses the older issue template format. Your task is to create GitHub issue forms for this repository. Please use Appwrite's issue templates as a reference for this PR.
.github/ISSUE_TEMPLATE/bug.yaml
.github/ISSUE_TEMPLATE/documentation.yaml
.github/ISSUE_TEMPLATE/feature.yaml
If you need any help, reach out to us on our Discord server.
Are you ready to work on this issue? ๐ค Let us know, and we will assign it to you ๐
Happy Appwriting!
This occurs for domains with * in the suffix list: https://publicsuffix.org/list/public_suffix_list.dat
for example:
$domain = new Domain('example.com.jm');
$domain->getSuffix();
"com.jm"
"" (empty)
Version 0.2.x
Linux
PHP 7.4.x
No response
$domain_check = new Domain($data['domain']);
var_dump($domain_check->get());
var_dump($domain_check->getTLD());
var_dump($domain_check->getSuffix());
var_dump($domain_check->getRegisterable());
var_dump($domain_check->getName());
var_dump($domain_check->getSub());
var_dump($domain_check->isKnown());
var_dump($domain_check->isICANN());
var_dump($domain_check->isPrivate());
var_dump($domain_check->isTest());die();
string(16) "www.test-8__.com"
string(3) "com"
string(3) "com"
string(12) "test-8__.com"
string(8) "test-8__"
string(3) "www"
bool(true)
bool(true)
bool(false)
bool(false)
test-8__.com is not valid for Register
I think should add $domain_check->isRootDomain()
to check if is a valid domain with Registerable
1
Version 0.2.x
Linux
PHP 8.0
No response
Steps to reproduce
$domain = new Domain('http://facebook.com');
$domain2 = new Domain('http://www.facebook.com');
$domain->getRegisterable()); // 'http://facebook.com'
$domain2->getRegisterable()); // 'facebook.com'
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.