9

I would like to set the class for a table in html export, e.g.: <table class="table table-striped">

While it seems that setting some attributes for export of tables to HTML are possible: #+ATTR_HTML: :border 2 :rules all :frame border I could not find any documentation on setting the class. Is this possible?

user1031565
  • 93
  • 1
  • 3

1 Answers1

8

You can treat the class attribute the same as other attributes and just set it:

#+ATTR_HTML: :border 2 :rules all :frame border :class striped table-striped

Which yielded (adding a newline for clarity):

<table border="2" cellspacing="0" cellpadding="6" rules="all" 
 frame="border" class="striped table-striped">
Mike Hall
  • 98
  • 3