How to render field attribute in foreach I have a link field with multiple values. I want to display the link title for each of these fields. I can print the slide link titles individually but not using the foreach. 

Currently I have:

&lt;ul id="slideLinks"&gt;
&lt;?php $slideshow_counter = 0; 
    $slide_link = $node-&gt;field_slideshow_link;
    print $slide_link['und'][0]['title'];
?&gt;
&lt;?php foreach ($slide_link as $link) : ?&gt;
    &lt;li&gt;&lt;a class="slideControl" href="javascript:void(0);"&gt;&lt;?php print $link['und'][$slideshow_counter]['title']; ?&gt;&lt;/a&gt;&lt;/li&gt;
    &lt;?php print $slideshow_counter; ?&gt;
    &lt;?php $slideshow_counter++; ?&gt;
&lt;?php
if ($slideshow_counter == 4)
    break;
endforeach;
?&gt;
As I understand your question, I recommend you to use for statement, you can do this:

&lt;ul id="slideLinks"&gt;
&lt;?php $slide_link = $node-&gt;field_slideshow_link['und']; ?&gt;
&lt;?php for ($i = 0; $i &lt; count($slide_link); ++$i): ?&gt;
    &lt;li&gt;&lt;a class="slideControl" href="javascript:void(0);"&gt;&lt;?php print render($slide_link[$i]['title']); ?&gt;&lt;/a&gt;&lt;/li&gt;
&lt;?php endfor; ?&gt;
&lt;/ul&gt;


This will print all your titles...