Login +

Documentation

SLS_String::countLines

Since SillySmart 1.0

Description

Count the number of lines in a string
static int countLines ( string $string);

Parameters

  • string $string
    the string to count

Return

int
the number of lines

Exemples

  •  var_dump(SLS_String::countLines(
     "SillySmart is a lightweight and flexible MVC Framework written in PHP5.
     It's based on XML/XSL's parsing."
     ));
     // will produce : 2

Comments

No comment on this function, be the first !

Add your comment

You must login/register to post a reply.