title: Use HTML5 data attribute as variable, not string
body: <p>I have an edit account button on each row of a table that makes the table editable. Above each row there are different messages that need to be display. I'd like to pass the different messages with a data attribute on each link. But currently the data attribute only is used as a string. Not to change the different messages. See jQuery below...</p>
  
  <pre><code>      var editAccount = $(".accounts_edit");
  
        editAccount.click(function(e) {
          e.preventDefault();
  
          var origHTML = $(this).parents("tr").html();
  
          var newAccountMsg = "&lt;p&gt;A new account was added by your bank adminstrator. To make payments from the account please link it to your bank account by entering the account number.&lt;/p&gt;"
  
          var authPaymentsMsg = "&lt;p&gt;Contact your &lt;a href=\"#\"&gt;bank adminstrator&lt;/a&gt; who can authorize payments from this account. This is a security feature.&lt;/p&gt;"
  
          var acctSystemMsg = "&lt;p class=\"error_msg\"&gt;This account was retrieved from your accounting system. To make payments from this account, please link it to your bank account by entering your account number.&lt;/p&gt;"
  
          var whatMessage = $(this).data("msg");
          console.log(whatMessage);
  
          var editHTML = "&lt;tr class=\"accounts_message\"&gt;" +
                    "&lt;td class=\"accounts_primary\"&gt;&lt;/td&gt;" +
                    "&lt;td colspan=\"5\"&gt;" + whatMessage + "&lt;/td&gt;" +
                  "&lt;/tr&gt;" + 
                  "&lt;tr class=\"accounts_edit\"&gt;" +
                    "&lt;td&gt;&lt;/td&gt;" +
                    "&lt;td&gt;&lt;input type=\"text\" class=\"new_account_no\" required=\"required\" /&gt;&lt;/td&gt;" +
                    "&lt;td&gt;&lt;input type=\"text\" class=\"new_account_name\" required=\"required\" /&gt;&lt;/td&gt;" +
                    "&lt;td&gt;&lt;input type=\"text\" class=\"new_starting_check\" required=\"required\" /&gt;&lt;/td&gt;" +
                    "&lt;td class=\"accounts_enable_ach\"&gt;Yes&lt;/td&gt;" +
                    "&lt;td class=\"accounts_manage\"&gt;" +
                      "&lt;a class=\"btn btn-custom\" href=\"#\"&gt;Save&lt;/a&gt;&lt;a class=\"btn\" href=\"#\"&gt;Cancel&lt;/a&gt;" +
                    "&lt;/td&gt;" +
                  "&lt;/tr&gt;";
  
          $(this).parents("tr").replaceWith(editHTML);
        });
  </code></pre>
  
  <p>Please let me know how var whatMessage can call the different messages and not simply print the data string. Thanks!</p>