dom option: set both id and class for div
dom option: set both id and class for div
![gagarski](https://secure.gravatar.com/avatar/e67fa04cc260daa32ea9dd98ebb094fd/?default=https%3A%2F%2Fvanillicon.com%2Fe67fa04cc260daa32ea9dd98ebb094fd_200.png&rating=g&size=120)
Hi.
I am trying to customize Datatables DOM and cannot figure out how to create div that has both class and id.
The following code in DOM:
<'#zzz yyy'><'yyy #zzz'>
produces the following HTML:
<div id="zzz yyy"></div><div class="yyy #zzz">
Example on https://datatables.net/examples/basic_init/dom.html says:
You can also specify div wrapping containers (with an id and / or class) to provide complete layout flexibility.
Is it really "and/or" or just "or"?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
From the page you linked to:
<"#id.class"
and>
- div with an id and classi.e. use a
.
rather than a space in your above code.Allan
Oops, looks like I missed it![:) :)](https://datatables.net/forums/resources/emoji/smile.png)
Nevertheless, I think it s also should be mentioned that on the reference page.
Agreed! Committed here and will be published on the site shortly.
Thanks for pointing that out![:smile: :smile:](https://datatables.net/forums/resources/emoji/smile.png)
Allan