We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 38503
    • 8 Posts
    Hi guys, this maybe a simple task to a few of you, but for me this one is a little above my head.

    I have create TV's for posting an image and thumb. But i need to also be alble to post the alt="" info.
    My site has resizeonupload set up, so when i post images to my "image" dir manually prior to creating a post. so with this i naturally get the thumb nail and main image placed in the dir ready to be pulled into blog. There are two tvs that i have set up one to calls the thumbnail on publish ie to home page. The other as you can guess calls the main image to post to a nivo-slider. Example: www.thespawned.co.uk (my dev url). The call and post of each image (non gallery items) works perfect with the tv call, but i would like to be able to call/show the alt="" info in the nivo-slider.... Problem is how to call the pagetitle for the physical page that the image is tied too. In the tv output it states the alt option and can post [[*id]] which works and shows as HOME but as mentioned i need the file name or article pagetitle instead.

    This is the end output as currently.

    <div id="slider" class="nivoSlider"><a href="mixes/i-am-architekt-2015-04-10.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-04-10/iam20150410-600x600.jpg" alt="Home" /></a>
    
    <a href="featured-mixes/duplicate-of-i-am-architekt-2015-04-10.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-04-10/iam20150410-600x600.jpg" alt="Home" /></a>
    
    <a href="mixes/i-am-architekt-2015-03-24.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-03-24/Iamarchitekt20150324-600x600.jpg" alt="Home" /></a>
    
    <a href="featured-mixes/duplicate-of-i-am-architekt-2015-03-24.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-03-24/Iamarchitekt20150324-600x600.jpg" alt="Home" /></a>
    
    <a href="mixes/i-am-architekt-2015-02-09.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-02-09/Iamarchitekt20150209_600x600.jpg" alt="Home" /></a>
    
    <a href="featured-mixes/duplicate-of-i-am-architekt-2015-02-09.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-02-09/Iamarchitekt20150209_600x600.jpg" alt="Home" /></a>
    
    <a href="mixes/i-am-architekt-2015-01-24.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-01-24/1am20150124-600.jpg" alt="Home" /></a>
    
    <a href="featured-mixes/duplicate-of-i-am-architekt-2015-01-24.html"><img src="images/GDMK Mixes/I_AM_ARCHiTEKT - 2015-01-24/1am20150124-600.jpg" alt="Home" /></a>
    </div>
    


    Call is as follows.
    [[!getResourcesTag? &elementClass=`modSnippet` &element=`getResources` &tpl=`PostImage` &parents=`11,45` &limit=`8` &includeContent=`0` &includeTVs=`6` &processTVs=`6` &showHidden=`0` &hideContainers=`0` &cache=`0` &pageVarKey=`page` ]]


    tpl:
    <a href="[[~[[+id]]]]">[[+tv.postimage]]</a>


    So if anyone can point me on the right path i would worship the ground taht you walk on smiley

    Please help, and thanks in advance - steve f.
      • 4172
      • 5,888 Posts
      make ths output-type of your image-TV not 'image' but 'default'

      then try:

      <a href="[[~[[+id]]]]"> <img src="[[+tv.postimage]]" alt="[[+pagetitle]]" /></a>

        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!
        • 38503
        • 8 Posts
        Thanks Bruno......... works a treat!

          • 38503
          • 8 Posts
          In the end the extra was as you replied with but also a quick refresh on my custom Nivo-Slider revealed.

          <a href="[[~[[+id]]]]"><img src="[[+tv.postthumb]]" alt="[[+pagetitle]]" title="[[+pagetitle]]" /></a>
            • 9995
            • 1,613 Posts
            fourroses666 Reply #5, 9 years ago
            alt is for images, title for a hrefs.


            <a href="[[~[[+id]]]]" title="[[+pagetitle]]"><img src="[[+tv.postthumb]]" alt="[[+pagetitle]]" /></a> 
              Evolution user, I like the back-end speed and simplicity smiley
              • 38503
              • 8 Posts
              Ah you spotted my error here, thanks @fourroses666.....