Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

getting (title="img name") to show up


Reply

3 Posts   815 Views

Avatar
JPG

13 December 2010 at 9:14am (Last edited: 13 December 2010 10:16am), Community Member, 53 Posts

Hi - right, as it states in the title.

I have a gallery that has been built and now I am trying the get the "title" curser-pop up to appear, it seems to refuse when I add it to either the <a> or <img> tags that I add it to (my use of the <img> is in conjunction with <a> in this case, I have tried every combination of where to house the "title" tag).

Here is a link to my example - please note that this is the live version that does not have the tags in use - I am experimenting with change on my local devserver.

http://www.zenz.net
(the links that I cannot get to behave are the gallery images that serve as links to other pages in the main content - I know the links are not working at the moment either - also as you can see the title tags work in the main navigation...)

In case it proves too much a pain to find the relevant files and code from the live site (and I think it will be), here is the ripped out code from the files that control the img and anchors from the home page.

<div id="primaryContent">
<div class="innerpad">
<div id="Content">
<% if URLSegment = home %>
<h2>architecture building design making</h2>
<div style="float:left;width:380px;font-size: 14px;line-height: 1.5;color: #AAA;" class="galleryDescription">
$Content</div>
<% else %>
   

   <div class="content-gal-div"> <h2>$Title</h2>
<% if AlbumTitle %>
   <% control CurrentAlbum %>
   <p class="galleryDescription">$Description</p>
   </div>
   <% end_control %>
   <% end_if %><% end_if %>
   
      

         

            <div id="galleria">
               <% control GalleryItems %>
                     <div >
                  

                <% if ImageLink %><a id="ViewLink-$ID" rel="$RelAttr" class="$ClassAttr" title="$Caption" href="$ImageLink" >
                  <% else %>
                   <a href="#" title="$Title" ><% end_if %>
                   <img src="$ThumbnailURL" alt="$Caption" title="$Title" /> </a>
                   <span>$Description</span>
                     
                     </div>
               <% end_control %>
               
            </div>   
   
</div>
</div>
</div>

Many thanks

Avatar
JPG

15 December 2010 at 8:59pm Community Member, 53 Posts

Shameless bump - still no joy...

Avatar
JPG

17 December 2010 at 4:58am Community Member, 53 Posts

Okay - so I have noticed on a few sites that have the same function (of a gallery type main content) seem to be missing this function. Is it actually the case that SS is over-writing the tags of the IMGs that are in the gallery/main content and rendering the "title=" section of the <img> and <a> tags useless as I STILL cannot get them to appear when the mouse id hovering...

:(