Skip to main content
Participant
August 25, 2022
Question

How to make a link unclickable

  • August 25, 2022
  • 6 replies
  • 370 views

Hello I am trying to make a link unclickable on Dreamweaver. My customer requested that the link should not be clickable. I was wondering if anyone knew how to do that?

Thanks!!

    This topic has been closed for replies.

    6 replies

    Liam Dilley
    Inspiring
    August 29, 2022

    Firstly, as the others have pointed out - If there is no need for a link - remove the link. Simple as that.

     

    - Outside of the logical action if for what ever reason the links is to remain but not clickable suggestions to remove the link to leave a blank anchor link or # are not good suggestions. People will click the link with nothing happening.

    - Suggestions of a asp button - if it is a link - ignore this, incorect advice.

    - While Javascript would work - WHY? too much effort.


    To have something that is clickable but not and something that can be done for device screens (Media queries) and like you simpley do it in CSS.

     

    .avoid-clicks { pointer-events: none; }

     

    Add that class on an element and it can not be clicked. Use the CSS itself when ever and where ever you like  on media quries etc as mentioned or on Javascript events.

    Nancy OShea
    Community Expert
    Community Expert
    August 25, 2022

    Dreamweaver is just a glorified code editor.  Working with code is much quicker than panels.   But if you really want to use panels, use Ctrl + F3 to open Properties. 

    Highlight linked object and remove link from Link field.  See screenshot.

     

     

     

     

     

    Nancy O'Shea— Product User & Community Expert
    Nancy OShea
    Community Expert
    Community Expert
    August 25, 2022

    To render it unclickable means removing the hyperlink, also known as the anchor tag.

    <a href="https://example.com">Link</a>

     

    Nancy O'Shea— Product User & Community Expert
    Jon Fritz
    Community Expert
    Community Expert
    August 25, 2022

    You can remove a link a few different ways...

    1. Highlight the link in Design or Live View, then delete the Link field in the Properties Window (hit Ctrl + F3 if the window isn't open).

    2. You could also go into Code View and remove the <a href="your_link_here"> and </a> from around a text or image link.

    If neither of those help, we're going to need more information about your code, what's happening, and how it differs from what you expect in order to help you further.

    Community Expert
    August 25, 2022

    If it's not clickable it's not a link.  If you are talking about temporarily disabling something like a button or disabling it until a specific event/action takes place you can use the disabled attribute on a button to keep it in a disabled state until you activate it: https://www.w3schools.com/tags/att_button_disabled.asp .

    Legend
    August 25, 2022

    Then dont have a link just use plain text. I dont see the point in using a link if your client doesn't want a link.........or am l missing something?