Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setAttribute does not work without an array as value #15

Closed
frazehmad opened this issue Feb 22, 2015 · 1 comment
Closed

setAttribute does not work without an array as value #15

frazehmad opened this issue Feb 22, 2015 · 1 comment
Labels

Comments

@frazehmad
Copy link

On home page of this repo, I see an example of setting an attribute:

$tag->setAttribute('class', 'foo');

But above code does not work and through below error:

Illegal string offset 'value'

But If I use an array for second parameter then it works fine:

$tag->setAttribute('class', array('value'=>'foo', 'doubleQuote'=>true));
@paquettg
Copy link
Owner

I'll take a look at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants