Deactivating hyperlink by CSS

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Deactivating hyperlink by CSS

יגאל חיטרון
Hello. Is there a way to deactivate a hyperlink using CSS? I tried
pointer-events: none, but wiki does not recognize it. Thank you.
Igal (User:Ikhitron)
_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

bawolff
You could force the link to be behind (in a z-index sense) another
transparent element.

(Not really deactivated because you can still reach it via keyboard,
but it would stop people clicking)
--
Brian

On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <[hidden email]> wrote:
> Hello. Is there a way to deactivate a hyperlink using CSS? I tried
> pointer-events: none, but wiki does not recognize it. Thank you.
> Igal (User:Ikhitron)
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l

_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

יגאל חיטרון
Thank you. But how can I create this element using css?
Igal


2018-05-10 15:34 GMT+03:00 bawolff <[hidden email]>:

> You could force the link to be behind (in a z-index sense) another
> transparent element.
>
> (Not really deactivated because you can still reach it via keyboard,
> but it would stop people clicking)
> --
> Brian
>
> On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <[hidden email]>
> wrote:
> > Hello. Is there a way to deactivate a hyperlink using CSS? I tried
> > pointer-events: none, but wiki does not recognize it. Thank you.
> > Igal (User:Ikhitron)
> > _______________________________________________
> > Wikitech-l mailing list
> > [hidden email]
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

Nick Wilson (Quiddity)
Igal, For what reason (use-case) are you wanting to deactivate the link?
Are you trying to make an image un-clickable [1], or something else?
If you explain that context, then we might be able to help better. I.e.
Examples/links always help!

[1] If this is your goal, then see this link AND the warning underneath
https://www.mediawiki.org/wiki/Help:Images#Altering_the_default_link_target

On Thu, May 10, 2018 at 5:42 AM, יגאל חיטרון <[hidden email]> wrote:

> Thank you. But how can I create this element using css?
> Igal
>
>
> 2018-05-10 15:34 GMT+03:00 bawolff <[hidden email]>:
>
> > You could force the link to be behind (in a z-index sense) another
> > transparent element.
> >
> > (Not really deactivated because you can still reach it via keyboard,
> > but it would stop people clicking)
> > --
> > Brian
> >
> > On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <[hidden email]>
> > wrote:
> > > Hello. Is there a way to deactivate a hyperlink using CSS? I tried
> > > pointer-events: none, but wiki does not recognize it. Thank you.
> > > Igal (User:Ikhitron)
> > > _______________________________________________
> > > Wikitech-l mailing list
> > > [hidden email]
> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >
> > _______________________________________________
> > Wikitech-l mailing list
> > [hidden email]
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>



--
Nick Wilson (Quiddity)
Community Liaison, Wikimedia Foundation
_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

יגאל חיטרון
Hi Quiddity.
I'm working with an old script, that (beyond other things) creates a
collapsed navigation template below imagemap tags. For better reading, for
browser search, for desktop view in mobile etc. So, the links created using
javascript, as hlist. And selflink does not get ".mw-selflink .selflink". I
can add the styles of course, but I need the behavior too. Thank you.
Igal


2018-05-10 19:48 GMT+03:00 Nick Wilson (Quiddity) <[hidden email]>:

> Igal, For what reason (use-case) are you wanting to deactivate the link?
> Are you trying to make an image un-clickable [1], or something else?
> If you explain that context, then we might be able to help better. I.e.
> Examples/links always help!
>
> [1] If this is your goal, then see this link AND the warning underneath
> https://www.mediawiki.org/wiki/Help:Images#Altering_the_
> default_link_target
>
> On Thu, May 10, 2018 at 5:42 AM, יגאל חיטרון <[hidden email]>
> wrote:
>
> > Thank you. But how can I create this element using css?
> > Igal
> >
> >
> > 2018-05-10 15:34 GMT+03:00 bawolff <[hidden email]>:
> >
> > > You could force the link to be behind (in a z-index sense) another
> > > transparent element.
> > >
> > > (Not really deactivated because you can still reach it via keyboard,
> > > but it would stop people clicking)
> > > --
> > > Brian
> > >
> > > On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <[hidden email]>
> > > wrote:
> > > > Hello. Is there a way to deactivate a hyperlink using CSS? I tried
> > > > pointer-events: none, but wiki does not recognize it. Thank you.
> > > > Igal (User:Ikhitron)
> > > > _______________________________________________
> > > > Wikitech-l mailing list
> > > > [hidden email]
> > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > >
> > > _______________________________________________
> > > Wikitech-l mailing list
> > > [hidden email]
> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > _______________________________________________
> > Wikitech-l mailing list
> > [hidden email]
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >
>
>
>
> --
> Nick Wilson (Quiddity)
> Community Liaison, Wikimedia Foundation
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

Derk-Jan Hartman
You cannot do this with CSS. You need to remove the href attribute from
such an <a> element if you want it to stop linking to something (which is
what the mw-selflink's do).

DJ
‪On Thu, May 10, 2018 at 6:56 PM ‫יגאל חיטרון‬‎ <[hidden email]>
wrote:‬

> Hi Quiddity.
> I'm working with an old script, that (beyond other things) creates a
> collapsed navigation template below imagemap tags. For better reading, for
> browser search, for desktop view in mobile etc. So, the links created
using
> javascript, as hlist. And selflink does not get ".mw-selflink .selflink".
I
> can add the styles of course, but I need the behavior too. Thank you.
> Igal


> 2018-05-10 19:48 GMT+03:00 Nick Wilson (Quiddity) <[hidden email]>:

> > Igal, For what reason (use-case) are you wanting to deactivate the link?
> > Are you trying to make an image un-clickable [1], or something else?
> > If you explain that context, then we might be able to help better. I.e.
> > Examples/links always help!
> >
> > [1] If this is your goal, then see this link AND the warning underneath
> > https://www.mediawiki.org/wiki/Help:Images#Altering_the_
> > default_link_target
> >
> > On Thu, May 10, 2018 at 5:42 AM, יגאל חיטרון <[hidden email]>
> > wrote:
> >
> > > Thank you. But how can I create this element using css?
> > > Igal
> > >
> > >
> > > 2018-05-10 15:34 GMT+03:00 bawolff <[hidden email]>:
> > >
> > > > You could force the link to be behind (in a z-index sense) another
> > > > transparent element.
> > > >
> > > > (Not really deactivated because you can still reach it via keyboard,
> > > > but it would stop people clicking)
> > > > --
> > > > Brian
> > > >
> > > > On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <
[hidden email]>

> > > > wrote:
> > > > > Hello. Is there a way to deactivate a hyperlink using CSS? I tried
> > > > > pointer-events: none, but wiki does not recognize it. Thank you.
> > > > > Igal (User:Ikhitron)
> > > > > _______________________________________________
> > > > > Wikitech-l mailing list
> > > > > [hidden email]
> > > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > > >
> > > > _______________________________________________
> > > > Wikitech-l mailing list
> > > > [hidden email]
> > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > > _______________________________________________
> > > Wikitech-l mailing list
> > > [hidden email]
> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > >
> >
> >
> >
> > --
> > Nick Wilson (Quiddity)
> > Community Liaison, Wikimedia Foundation
> > _______________________________________________
> > Wikitech-l mailing list
> > [hidden email]
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l

_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Reply | Threaded
Open this post in threaded view
|

Re: Deactivating hyperlink by CSS

יגאל חיטרון-2
A pity. Thank you.
Igal


On May 11, 2018 10:46, "Derk-Jan Hartman" <[hidden email]>
wrote:

> You cannot do this with CSS. You need to remove the href attribute from
> such an <a> element if you want it to stop linking to something (which is
> what the mw-selflink's do).
>
> DJ
> ‪On Thu, May 10, 2018 at 6:56 PM ‫יגאל חיטרון‬‎ <[hidden email]>
> wrote:‬
>
> > Hi Quiddity.
> > I'm working with an old script, that (beyond other things) creates a
> > collapsed navigation template below imagemap tags. For better reading,
> for
> > browser search, for desktop view in mobile etc. So, the links created
> using
> > javascript, as hlist. And selflink does not get ".mw-selflink .selflink".
> I
> > can add the styles of course, but I need the behavior too. Thank you.
> > Igal
>
>
> > 2018-05-10 19:48 GMT+03:00 Nick Wilson (Quiddity) <[hidden email]
> >:
>
> > > Igal, For what reason (use-case) are you wanting to deactivate the
> link?
> > > Are you trying to make an image un-clickable [1], or something else?
> > > If you explain that context, then we might be able to help better. I.e.
> > > Examples/links always help!
> > >
> > > [1] If this is your goal, then see this link AND the warning underneath
> > > https://www.mediawiki.org/wiki/Help:Images#Altering_the_
> > > default_link_target
> > >
> > > On Thu, May 10, 2018 at 5:42 AM, יגאל חיטרון <[hidden email]>
> > > wrote:
> > >
> > > > Thank you. But how can I create this element using css?
> > > > Igal
> > > >
> > > >
> > > > 2018-05-10 15:34 GMT+03:00 bawolff <[hidden email]>:
> > > >
> > > > > You could force the link to be behind (in a z-index sense) another
> > > > > transparent element.
> > > > >
> > > > > (Not really deactivated because you can still reach it via
> keyboard,
> > > > > but it would stop people clicking)
> > > > > --
> > > > > Brian
> > > > >
> > > > > On Thu, May 10, 2018 at 12:15 PM, יגאל חיטרון <
> [hidden email]>
> > > > > wrote:
> > > > > > Hello. Is there a way to deactivate a hyperlink using CSS? I
> tried
> > > > > > pointer-events: none, but wiki does not recognize it. Thank you.
> > > > > > Igal (User:Ikhitron)
> > > > > > _______________________________________________
> > > > > > Wikitech-l mailing list
> > > > > > [hidden email]
> > > > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > > > >
> > > > > _______________________________________________
> > > > > Wikitech-l mailing list
> > > > > [hidden email]
> > > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > > > _______________________________________________
> > > > Wikitech-l mailing list
> > > > [hidden email]
> > > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > > >
> > >
> > >
> > >
> > > --
> > > Nick Wilson (Quiddity)
> > > Community Liaison, Wikimedia Foundation
> > > _______________________________________________
> > > Wikitech-l mailing list
> > > [hidden email]
> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > >
> > _______________________________________________
> > Wikitech-l mailing list
> > [hidden email]
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
> _______________________________________________
> Wikitech-l mailing list
> [hidden email]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
_______________________________________________
Wikitech-l mailing list
[hidden email]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l