WordPress\AiClientDependencies\Psr\Http\Message
UriInterface::withFragment
Return an instance with the specified URI fragment.
This method MUST retain the state of the current instance, and return an instance that contains the specified URI fragment.
Users can provide both encoded and decoded fragment characters. Implementations ensure the correct encoding as outlined in getFragment().
An empty fragment value is equivalent to removing the fragment.
Method of the class: UriInterface{}
No Hooks.
Returns
static. A new instance with the specified fragment.
Usage
$UriInterface = new UriInterface(); $UriInterface->withFragment( $fragment ): UriInterface;
- $fragment(string) (required)
- The fragment to use with the new instance.
UriInterface::withFragment() UriInterface::withFragment code WP 7.0
public function withFragment(string $fragment): UriInterface;