PHPackages                             smeghead/text-link-encoder - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. smeghead/text-link-encoder

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

smeghead/text-link-encoder
==========================

A library that converts any string containing a URL (such as a user-entered string) into a html string containing url link. Non-URL parts are html-encoded.

v0.2.1(2y ago)1131Apache-2.0PHPPHP &gt;=7.4

Since Aug 24Pushed 2y ago1 watchersCompare

[ Source](https://github.com/smeghead/php-text-link-encoder)[ Packagist](https://packagist.org/packages/smeghead/text-link-encoder)[ RSS](/packages/smeghead-text-link-encoder/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (2)Versions (5)Used By (0)

php-text-link-encoder
=====================

[](#php-text-link-encoder)

A library that converts any string containing URLs and Emails (such as a user-entered string) into a html string containing url link. Non-URL parts are html-encoded.

[![Testing](https://github.com/smeghead/php-text-link-encoder/actions/workflows/php.yml/badge.svg?event=push)](https://github.com/smeghead/php-text-link-encoder/actions/workflows/php.yml/badge.svg?event=push) [![Latest Stable Version](https://camo.githubusercontent.com/c9d4a5a507c9df2eeeb2bb41a7f1c9b7f4fb5df7903d4263defdfdb4fadbe671/687474703a2f2f706f7365722e707567782e6f72672f736d6567686561642f746578742d6c696e6b2d656e636f6465722f76)](https://packagist.org/packages/smeghead/text-link-encoder) [![Total Downloads](https://camo.githubusercontent.com/34dcffcd0a706a737345a5db1d352aeeb274028c417504d5448352ae7b3f1e35/687474703a2f2f706f7365722e707567782e6f72672f736d6567686561642f746578742d6c696e6b2d656e636f6465722f646f776e6c6f616473)](https://packagist.org/packages/smeghead/text-link-encoder) [![Latest Unstable Version](https://camo.githubusercontent.com/7a1aa76e6eacb2fd1eebf297675113990c38c79e1a01466c2445b9752e4bde16/687474703a2f2f706f7365722e707567782e6f72672f736d6567686561642f746578742d6c696e6b2d656e636f6465722f762f756e737461626c65)](https://packagist.org/packages/smeghead/text-link-encoder) [![License](https://camo.githubusercontent.com/f396027b4e02d390bfa67612cc07b06e2d67b87b3ec7596733a8bc89ba9af7fe/687474703a2f2f706f7365722e707567782e6f72672f736d6567686561642f746578742d6c696e6b2d656e636f6465722f6c6963656e7365)](https://packagist.org/packages/smeghead/text-link-encoder) [![PHP Version Require](https://camo.githubusercontent.com/965a3a9a6e76840d8250384f7cb9a4279a0a6b151613f5f2974a33b86078e14e/687474703a2f2f706f7365722e707567782e6f72672f736d6567686561642f746578742d6c696e6b2d656e636f6465722f726571756972652f706870)](https://packagist.org/packages/smeghead/text-link-encoder)

Features
--------

[](#features)

- Converts urls and Emails in text to link tags.
- Other parts are properly encoded.

Install
-------

[](#install)

### From Composer

[](#from-composer)

```
$ composer require smeghead/text-link-encoder
```

Usage
-----

[](#usage)

```
