You are here

function fckeditor_is_plaintext in FCKeditor - WYSIWYG HTML editor 6.2

Determines if the supplied text doesn't contain any HTML

Parameters

string $text :

Return value

bool

1 call to fckeditor_is_plaintext()
fckeditor_process_textarea in ./fckeditor.module
This function create the HTML objects required for the FCKeditor

File

./fckeditor.lib.inc, line 270
FCKeditor - The text editor for Internet - http://www.fckeditor.net Copyright (C) 2003-2008 Frederico Caldeira Knabben

Code

function fckeditor_is_plaintext($text) {
  if (strpos($text, '<p>') !== FALSE) {
    return FALSE;
  }
  if (strpos($text, '<div>') !== FALSE) {
    return FALSE;
  }
  if (strpos($text, '<br') !== FALSE) {
    return FALSE;
  }
  return TRUE;
}