Results 1 to 5 of 5

Thread: [Solved]Lightbox link in search engine

  1. #1
    User
    Join Date
    04-27-10.
    Posts
    134

    Default [Solved]Lightbox link in search engine

    Hi,
    I edited the search_default.tpl so links open in a lightbox/mediabox.
    The problem is, if I add rel="lightbox[943 75%]" in the link, all the results get treated like a gallery so pressing left and right arrows go to the next result within the lightbox. I don't want this to happen. How can I get links to open in a lightbox at a set size without left and right arrows switching links? Just putting rel="lightbox" means the lightbox opens quite small.

    Code:
    <h3>title; ?>" rel="lightbox[943 75%]"><?php echo $this->link; ?> <span class="relevance">[<?php echo $this->relevance; ?>%]</span></h3>
    Thanks

  2. #2
    User
    Join Date
    06-19-09.
    Posts
    328

    Default Re: Lightbox link in search engine

    try with:
    Code:
    rel="lightbox[something 943 75%]"
    Consulenza Contao CMS https://www.intco.it

  3. #3
    Community-Moderator xchs's Avatar
    Join Date
    06-19-09.
    Posts
    1,287

    Default Re: Lightbox link in search engine

    Why do you put the "rel" attribute twice in your anchor element?
    Contao Community Moderator
    → Support options

  4. #4
    User
    Join Date
    04-27-10.
    Posts
    134

    Default Re: Lightbox link in search engine

    Ah, that was a mistake.

    I tried adding a word but that didn't work. Maybe I need to have a random string for each link generated with a little php.
    I thought adding the a word in the [ ] made it part of a gallery.

    Just putting rel="lightbox" means that the links are single items.

  5. #5
    User
    Join Date
    04-27-10.
    Posts
    134

    Default [solved] Lightbox link in search engine

    I've acheived what I wanted to.
    I used this line instead.
    Code:
    rel="lightbox[a<?php echo mt_rand(1,9999); ?>a 945 75%]">
    I added letters either end because the at first I just used the linkid but a couple of links still appeared as a gallery when number was a2 and a20

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •