|
CORE
NATIVE
TABLE
MAKE
CUSTOMIZE
EFFECTS
effects_base.js
effects_morph.js
effects_fade.js
effects_move.js
effects_extra.js
effects_toggle.js
effects_cycle.js
effects_cycles.js
VIRTUAL BOX
PLUG-IN
|
string_php.js
Contains prototypes to apply some php string methods to String constructor Contains Class String Summary
Extends the native String object with many methods that works like PHP string methods.These are indispensable into server-side applications, but their functionalities can be very useful into client-sideapplications too. This String extension allows you to use PHP string methods with Javascript. Extends Class String Methods
top method stripTags strips all HTML tags from the string
Example var s = '<table><tr><td>some data</td></tr></table>'; // returns 'some data' s.stripTags(); top method addslashes adds slashes before all ' or " characters
Example var s = 'som'e da'ta' // s is now 'som\'e da\'ta' s.addslashes(); top method nl2br replaces all newline characters with the XHTML 'br' tags
Example var s = 'this is \n some data \n'; // s is now: 'this is <br /> some data <br />' s.nl2br(); top method br2nl replaces all XHTML 'br' tags with the newline characters
Example var s = 'this is <br /> some data <br />'; // s is now: 'this is \n some data \n' s.br2ln(); top method stripslashes strips slashes before all ' or " characters
Example s = 'som\'e dat\'a'; // s is now 'som'e dat'a' s.stripslashes(); top method htmlEntities converts all possible characters into HTML entities
Example var s = '<code><i></i></code>'; // returns '<code><i></i></code>'; s.htmlEntities(); top method html_entity_decode converts all HTML entities into normal characters
Example var s = '<code><i>some data</i></code>'; // returns '<code><i>some data</i></code>'; s.html_entity_decode(); top method trim trims a string
Example var s = ' some data '; // returns 'some data' s.trim(); top method ltrim deletes all spaces at beginning of the string
Example var s = ' some data'; // returns 'some data' s.trim(); top method rtrim deletes all spaces at the end of the string
Example var s = 'some data '; // returns 'some data' s.trim();
Documentation By
Riccardo Degni -
powered by MakeDocs, CMS by RD |