Results 1 to 2 of 2

Thread: Logo to take you to home page

  1. #1
    User Carolina's Avatar
    Join Date
    09-05-12.
    Location
    London
    Posts
    99

    Beitrag Logo to take you to home page

    Hi,

    In this version of Contao, if I write this: <a href="/"> on the logo module, doesn't work.

    <div id="logo"><a href="/"><img src="/files/assembly21/assembly21-logo.png" alt="Assembly 21"></div>

    I get a red sign with a cross saying:

    "Start tag seen without seeing a doctype first. Expected eg. <!DOCTYPE html>. End tag (div) seen to early. Expected other end tag.".

    Despite this warning, I saved it, and the logo does take you to the home page, but I'd like to keep things tidy anyway.

    Thanks in advance.
    Carolina

  2. #2
    User Andreas's Avatar
    Join Date
    07-11-09.
    Location
    Mönchengladbach
    Posts
    499

    Default

    You simply did not close the A-Element. To prevent this write no own HTML code, it's for experts only.

    1. Create an unpublished page named f.e. "Page wide articles".
    2. Create a module type "HTML".
    3. Fill in
      HTML Code:
      <!-- indexer::stop -->
      {{insert_article::logo}} (or "header")
      <!-- indexer::continue -->
    4. Include this module in your layout(s).
    5. Inside the article "logo" create whatever you want. A CE type image that links to your homepage, or a CE type hyperlink with an image that links to your homepage.
    6. For the link use the inserttag {{env::host}}.



    There's an old german wiki topic by me, it's alike what I told you here. http://de.contaowiki.org/Diskussion:...der_und_Footer
    Web-Development, Freelancer, Burgtech, XHTML, HTML5, CSS, PHP, Javascript, MooTools, MySQL and more
    Amazon wishlist

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
  •