How to add an id element to a field in Drupal 7 I am try to find out a way that I can add in #ID element to a link field in Drupal 7. When you Edit the field it give you a chance to create a CLASS (Additional CSS Class) for it, however I want to add an #ID element so that I can use it to trigger an event for google analytics. I actually was able to add and #ID to that panel display but it is 2  above and not triggering it.

Is there a way to do this without code, if not what approach would I take to handle through code(not my specialty).
Here is an example of what I have...

&lt;div class="panel-pane pane-entity-field pane-node-field-print-link"  id="newsletterPrint"&gt;
  &lt;div class="pane-content"&gt;
    &lt;div class="field-print-link"&gt;
      &lt;a href="http://stage.ecgcme.com/print/project/MTH095AE1"&gt;Print&lt;/a&gt;  &lt;/div&gt;
  &lt;/div&gt;
  &lt;/div&gt;
  &lt;/div&gt;


and I want this...

&lt;div class="field-print-link" id="newsletterPrint"&gt;
          &lt;a href="http://stage.ecgcme.com/print/project/MTH095AE1"&gt;Print&lt;/a&gt;  &lt;/div&gt;
First of all are you using the Link module? Just so we know.

I would create a template to the field:

You can copy the /modules/field/theme/field.tpl.php to your theme, change the name to field--field-print-link.tpl.php and customize it in any way wanted.

Don't forget to flush your caches!

Or, of course, you could add the id with JS using a bit of jQuery (as Drupal already uses it):

$('element').attr('id', 'value');