/** * Generates a bar chart from the entered data and returns the HTML code to render the graph * * @param $input String Input between the <pBar> and </pBar> tags or null is the tag is closed (<pBar />) * @param $args Array Tag arguments, which are entered like HTML tag attributes; this is an associative * array indexed by attribute name * @param $parser Object The parent parser; more advanced extensions use this to obtain the contextual Title, * parse wiki text, expand braces, register link relationships and dependencies etc. * @returns String HTML code to show the bar chart */ public static function render($input, $args, $parser) { // Recursively parse the wikitext $parsedText = $parser->recursiveTagParse($input); // Create the chart $chart = new pChart4mwBars(); return $chart->renderChart($parsedText, $args); }