Welcome To Snipplr


Everyone's Recent PHP Snippets Tagged text



1 2 Next »
split_to_chunks splits the string up into an array with elements containing 140 characters <b>or less</b>. This enables you to keep words intact when sending automated twitter messages. $to is needed in order to subtract from 140 the amount of cha...
0 852 posted 14 years ago by s0l1dsnak3123
Add to functions.php file.
0 708 posted 14 years ago by Xtraboy
Con esta funcion podemos recortar una cadena de texto indicandole cuantos caracteres queremos que tenga y ademas no cortara la ultima palabra.
0 504 posted 14 years ago by jacinmontava
I wrote this really quick and dirty script to paginate a very large chunk of text. A client site was setup with the understanding their about page would consist of 5-6 paragraphs but their biography ended up being 60 paragraphs. At the end of the d...
0 573 posted 14 years ago by aristoworks
0 649 posted 14 years ago by yazu
Used to convert URLs in a string into links
1 406 posted 14 years ago by jspicher
Convert string to underscore, for SE safe URLs etc.
1 475 posted 14 years ago by jspicher
Used to sanitize user input for email.
0 479 posted 14 years ago by jspicher
Used to cleanly truncate text.
0 471 posted 14 years ago by jspicher
This piece of code will store each line of a txt file into a mysql database
2 994 posted 14 years ago by fackz
1 481 posted 14 years ago by radarseven
1 888 posted 14 years ago by shahways
closes opened tags in text piece. original code slightly modified to supress PHP warnings NOTE: need to fix the order of closing tags to get standards compliance
0 587 posted 15 years ago by kossmoss
Nice simple snippet. Great for forum scripts.
1 765 posted 15 years ago by Unreal
First Remove all capital letters, then capitalise the first ones in each word.
1 618 posted 15 years ago by Wardy
Checks the size of skypes online "status buttons" to determine online/offline status, so you're able to use custom buttons, text.. etc, etc
2 632 posted 15 years ago by davidsword
Useful for taking incorrectly-formatted UTF-8 strings containing HTML data, and converting them to correctly-formatted UTF-8 plain text. A handy tool for displaying HTML stored in a database.
4 1623 posted 15 years ago by X3Maverick
Two functions. 1) Find the string between characters. 2) Create array of strings found between two characters.
1 639 posted 15 years ago by jamesming
Another way of showing long text to end user...
0 641 posted 15 years ago by skywalker
Elimina las etiquetas de p&aacute;rrafo &lt;P&lt; y &lt;/P&lt; (sin par&aacute;metros) y las sustituye por saltos de l&iacute;nea &lt;BR /&gt;. En caso necesario inserta un &lt;BR /&gt; adicional para simular la separaci&oacute;n de p&aacute;rrafos.
0 606 posted 17 years ago by Navegante
1 2 Next »