title: Is it possible to use values in a <span> as the parameters for a Ruby function?
body: <p>I'm passing a span to an HTML file from a javascript file using:</p>
  
  <pre><code>$('#eventCode').html event.code
  </code></pre>
  
  <p>From said HTML file I'm displaying the contents of the selected code with:</p>
  
  <pre><code>&lt;span id="eventCode"&gt;&lt;/span&gt;
  </code></pre>
  
  <p>This works fine, but I also am trying to make a ruby function call as follows:</p>
  
  <pre><code>&lt;%= link_to "Delete", Event.find_by_code("eventCode would go here"), 
      method: :delete, confirm: "Are you sure you want to delete the event?" %&gt;
  </code></pre>
  
  <p>Is there any way I can take the contents of a HTML span and use them as a parameter for a Ruby function, as shown above?</p>