Viewing 6 replies - 1 through 6 (of 6 total)
  • Anonymous User 18274256

    (@anonymized-18274256)

    Hi @mira404,

    You need to add two classes in CSS code in Appearance -> Customize -> Additional CSS section

    .internal_link{color: #000;text-decoration: underline;}
    .external_link{ color: #ef3737;font-weight: 700;text-decoration: underline;}

    Once you will add it then everywhere you need to use these classes as per your requirements, for an external link you need to use the ‘external_link’ class and for an internal link you need to use the “internal_link” class.

    Hope this will work for you.

    Regards,

    Thread Starter mira404

    (@mira404)

    I’m using the GeneratePress theme, code isn’t working check this: https://prnt.sc/uix2do

    @mira404 … @ravivaddweb code works just fine but your have to add classes to all your links for it to work.

    You can also use:

    a { color: green; }
    a[href*="//"]:not([href*="your_site.com"]) {
    	color: pink;
    }

    Of course, change the your_site.com to whatever your site is.

    Thread Starter mira404

    (@mira404)

    @tugbucket

    a { color: #111111; }
    a[href*="//"]:not([href*="*****.com"]) {
    	color: #fc7d46;
    }

    Now code working fine. Also want to add underline interlink only like this: https://prnt.sc/uivvbz

    • This reply was modified 4 years, 2 months ago by mira404.
    a { color: #111111; text-decoration: underline; }
    a[href*="//"]:not([href*="*****.com"]) {
    	color: #fc7d46; text-decoration: none;
    }
    Thread Starter mira404

    (@mira404)

    Thanks

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Change only internal links color’ is closed to new replies.