html-tag-printer
文件大小: unknow
源码售价: 5 个金币 积分规则     积分充值
资源说明:A simple & small tool easily output HTML tags in php
# HTML tag printer
> Make the code clean when there are many dynamic attributes to be set on the element

### Example

```php
echo T('a', array(
  'href' => '//www.google.com',
  'id' => 'google'
), 'hi google');
```
Outputs:
```html
hi google
```

### More examples

The arguments vary in number as well as type.

```php
echo T();
// ''

echo T('p');
// 

echo T('p', 'hi'); //

hi

echo T('p', array( 'id' => 'test', 'class' => 'test' ), 'hi'); //

hi

``` ### Nested tags ```php echo T('div', array( T('p', 'content1'), T('p', 'content2'), T('p', 'content3') )); echo T('div', array('id' => 'hello'), T('div', array('id' => 'world'), array( T('p', 'hello'), T('p', 'world') ) )); echo T('ul', array('id' => 'nav'), array( T('li', T('a', array('href' => '#', 'id' => 'current'), 'link1')), T('li', T('a', array('href' => '#'), 'link2')) )); ```

本源码包内暂不包含可直接显示的源代码文件,请下载源码包。