mirror of
https://github.com/YGGverse/yggverse.github.io.git
synced 2025-01-01 16:24:49 +00:00
35 lines
864 B
Plaintext
35 lines
864 B
Plaintext
# gemini-php 0.7.0
|
|
|
|
Client::Request method now supports resolved host as optional argument!
|
|
|
|
This feature useful to
|
|
|
|
* reduce traffic usage
|
|
* increase page loading time by DNS results cache in memory
|
|
* alternative networks resolvers, isolated of system
|
|
|
|
Update dedicated to the Yo! crawler project
|
|
|
|
=> https://github.com/YGGverse/Yo/tree/gemini
|
|
|
|
## Example
|
|
|
|
``` php
|
|
$request = new \Yggverse\Gemini\Client\Request(
|
|
'gemini://yggverse.cities.yesterweb.org:1965/index.gmi' // target URL
|
|
'68.133.1.71' // resolved IP, skip to use system-wide resolver
|
|
);
|
|
```
|
|
|
|
Alternatively, use setResolvedHost method of Request object before getResponse
|
|
|
|
``` php
|
|
$request->setResolvedHost(
|
|
'68.133.1.71'
|
|
)
|
|
```
|
|
|
|
## Links
|
|
|
|
=> https://github.com/YGGverse/gemini-php/releases/tag/0.7.0 Download gemini-php 0.7.0
|
|
=> https://github.com/YGGverse/net-php Network Resolver in PHP 8 |