I have a slider at the top of my page using this HTML:

<div id='top_slider'>
    {exp:channel:entries channel="home" limit="1"}
        <!-- <div class="arrow_left white" onclick="slide('left')"></div>
        <div class="arrow_right white" onclick="slide('right')"></div> -->
            {if active == 'y'}
                {if row_count == 2}
                    <div class="arrow_left white" onclick="slide('right');stopAutoSlide();"></div>
                    <div class="arrow_right white" onclick="slide('left');stopAutoSlide();"></div>
                <div class='slide'>
                    {if url != ''}<a href="{url}">{/if}
                    <img class="fullscreen_img" src='{image}' />
                    {if url != ''}</a>{/if}

I want to link the images to a URL specified in the Homepage Content using a channel field. The problem is that this only works for internal links currently. If I enter "store" into the URL field it correctly takes me to http://mywebsite.com/store, but if I enter an external link such as http://google.com, the href becomes malformed and spits out this:

<a href="&lt;a href=" http:="" google.com"="">http://google.com</a>

Any ideas? Thanks in advance!

1 Answer 1


Check the Channel Preferences for this Channel for the Automatically turn URLs and email addresses into links option. It sounds like you have it set to "Yes" and this is causing the malformed HTML.

Control Panel Location: Admin > Channel Administration > Channels > Edit Preferences

enter image description here



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.