Difference between revisions of "Command Element"

From Level Access Web Labs
Jump to navigation Jump to search
 
Line 2: Line 2:
 
<head>
 
<head>
 
  <script type="text/javascript">
 
  <script type="text/javascript">
   function open() {
+
   function openBox() {
 
       alert('opened');
 
       alert('opened');
 
   }
 
   }
   function close() {
+
   function closeBox() {
 
       alert('closed');
 
       alert('closed');
 
   }
 
   }
Line 13: Line 13:
 
Below is a command menu bar.
 
Below is a command menu bar.
 
<menu>
 
<menu>
<command type="command" label="Open" onclick="open();">Open</command>
+
<command type="command" label="Open" onclick="openBox();">Open</command>
<command type="command" label="Close" onclick="close();">Close</command>
+
<command type="command" label="Close" onclick="closeBox();">Close</command>
 
</menu>
 
</menu>
<button onclick="open();"> test </button>
+
<button onclick="openBox();"> test </button>
 
</body>
 
</body>
 
</html>
 
</html>
 
[[Category:Elements]]
 
[[Category:Elements]]

Latest revision as of 15:21, 27 March 2014

Below is a command menu bar.

Open Close