Lightbox where to Place the code?

Discussion in 'WordPress' started by redwolf6, Feb 2, 2010.

  1. #1
    Hi guys.

    I installed lightbox2 on wordpress and it worked , but i can't seem to be able to put rel="lightbox" in this image tag.
    where to put it ?

    Thanks in advance
     
    redwolf6, Feb 2, 2010 IP
  2. SuburbanDollar

    SuburbanDollar Peon

    Messages:
    31
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I also run lightbox2, I have it configured to auto-lightbox image links though. Looking at the instructions on the project page you should place the rel="lightbox" in the link so it should look like this:

    
    <a class="postlink img_link" onclick="this.target='_blank';" rel="lightbox" href="http://www.upload.f1arab.com/img5/4863/105wri.jpg">
    
    <img src="http://www.upload.f1arab.com/img5/7606/091wri.th.jpg" alt="Image" />
    
    </a>
    
    Code (markup):
    The rel="lightbox" should share the space where you rel="nofollow" is in the anchor text.
     
    SuburbanDollar, Feb 2, 2010 IP
  3. ms.g

    ms.g Peon

    Messages:
    163
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #3
    How do you place image to your wordpress? Via the Post Image feature? Or Custom Fields? If from the former, you have to do the editing via post; the latter, via your theme.

    Also the rel="lightbox" should be added to the <a href> not on the <img>

    Let me know how can I further help you.
     
    ms.g, Feb 4, 2010 IP