more refactoring for dependency injection.

This commit is contained in:
Taylor Otwell
2011-09-09 20:55:24 -05:00
parent dc1b93e2ea
commit fb811af5fc
30 changed files with 545 additions and 404 deletions

View File

@@ -7,14 +7,14 @@ class HTML {
*
* @var string
*/
public $encoding;
protected $encoding;
/**
* The URL generator instance.
*
* @var URL
*/
private $url;
protected $url;
/**
* Create a new HTML writer instance.
@@ -278,7 +278,7 @@ class HTML {
*/
public function image($url, $alt = '', $attributes = array())
{
$attributes['alt'] = $this->entities($alt);
$attributes['alt'] = $alt;
return '<img src="'.$this->entities($this->url->to_asset($url)).'"'.$this->attributes($attributes).'>';
}