Created
May 14, 2009 08:35
-
-
Save rauchg/111565 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class ForgeMDParser | |
{ | |
var $errors = array(); | |
public function __construct($data){ | |
$this->data = $data; | |
$this->parse(); | |
} | |
public function parse(){ | |
$this->html = sfMarkdown::doConvert($this->data); | |
$xml = simplexml_load_string($this->html); | |
var_dump($xml); | |
} | |
public function hasErrors(){ | |
return !empty($this->errors); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment