Not a developer? Go to


Action Buttons

Action Buttons

To insert buttons into the table’s header, you use the action_buttons block. Inside this block you insert links that Movable Type will automatically style as buttons for you. The following example does use a little javascript magic which we will explain in a moment.

<mt:setvarblock name="action_buttons">
  <a href="javascript:void(0)"
                 'event', 'events', 'id', 'itemset_hide_events'); 
                 return false;"
     title="Hide selected events (h)">Hide</a>
  <!-- more buttons here if you wish -->

The javascript involved here does all of the work for you:

doForMarkedInThisWindow(<table ID>,<singular>,<plural>,
                        <id name>,<mode>);
  • table ID - the DOM ID of the table that contains the selected rows
  • singular - the singular term for the object being displayed, e.g. “cat” or “dog.”
  • plural - the pluralized term for the object being displayed, e.g. “cats” or “dogs.”
  • id name - the name of the parameter that will hold the list of selected items in the request that is submitted
  • mode - the mode to submit the form to that will process the request