Merge branch 'wip-MDL-35847-master' of git://github.com/phalacee/moodle

This commit is contained in:
Eloy Lafuente (stronk7) 2013-02-05 00:08:44 +01:00
commit 1615caae6f
3 changed files with 17 additions and 0 deletions

View File

@ -2325,12 +2325,14 @@ EOD;
* If the error message is blank, nothing is output.
*
* @param string $message the error message.
* @param bool $icon display the icon along with the error message.
* @return string the HTML to output.
*/
public function error_text($message) {
if (empty($message)) {
return '';
}
$message = $this->pix_icon('i/warning', get_string('error'), '', array('class' => 'icon icon-pre', 'title'=>'')) . $message;
return html_writer::tag('span', $message, array('class' => 'error'));
}

BIN
pix/i/warning.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 278 B

15
pix/i/warning.svg Normal file
View File

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 15.1.0, SVG Export Plug-In -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
]>
<svg version="1.1"
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
x="0px" y="0px" width="16px" height="16px" viewBox="0 0 16 16" style="overflow:visible;enable-background:new 0 0 16 16;"
xml:space="preserve">
<defs>
</defs>
<path style="fill:#999999;" d="M7,0.7L0.2,14.1c-0.5,1,0,1.8,1.1,1.8h13.2c1.1,0,1.6-0.8,1.1-1.8L8.8,0.7C8.3-0.2,7.5-0.2,7,0.7z
M9.4,13.4c0,0.8-0.7,1.5-1.5,1.5c-0.8,0-1.5-0.7-1.5-1.5c0-0.8,0.7-1.5,1.5-1.5C8.7,11.9,9.4,12.5,9.4,13.4z M9.2,5.9v4
c0,0.5-0.5,1-1,1H7.6c-0.5,0-1-0.5-1-1v-4c0-0.6,0.5-1,1-1h0.6C8.8,4.9,9.2,5.3,9.2,5.9z"/>
</svg>

After

Width:  |  Height:  |  Size: 938 B