Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • bb80 5 posts 20 karma points
    Mar 20, 2009 @ 22:41
    bb80
    0

    Calling macro within anchor-tag's href-attribute

    Hi

    I have create a macro which takes a contentpicker as input, and returns the NiceURL.
    It works find for displaying it in text.

    But how can I call from with a:

  • bb80 5 posts 20 karma points
    Mar 21, 2009 @ 09:44
    bb80
    0

    Nevermind, I found out.

    The problem was solved by changing the outer " to '


  • Martijn Maris 37 posts 235 karma points MVP
    Aug 07, 2009 @ 08:07
    Martijn Maris
    0

    It is also possible to work the other way around, changing the inner " to ':

    Before (gives an error)

        <meta name="description" content="<umbraco:Macro runat="server" Alias="Showgoogledescription"></umbraco:Macro>"/>

    After

        <meta name="description" content="<umbraco:Macro runat='server' Alias='Showgoogledescription'></umbraco:Macro>"/>
  • Aaron Powell 1708 posts 3046 karma points c-trib
    Aug 07, 2009 @ 08:51
    Aaron Powell
    1

    If anyone's interested, it's to do with how .NET handles the string escaping within its parsing engine. If you have both using the same quoting style then it will not be able to determine where the tags start and end properly, resulting in the error you encountered.

Please Sign in or register to post replies

Write your reply to:

Draft