Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Advanced Search
  • 0

Custom navigation button with folder issue


PlenitudPR

Question

Site URL: https://plenitudpr.org

Hi!

I have a multilingual site with 2 folders for each language, 1 folder on the primary navigation and 1 folder on the secondary navigation. I wanted to add a call to action button to the right of the header and added this code.

// Last 2nd Nav Item Orange Button //
.Header-nav.Header-nav--secondary a:last-child {
    background-color: #ffffff; /* button color */
      color: #ea7c3a; /* text color */
      border: 2px solid #ea7c3a;
    padding: 15px !important;
    border-radius: 2px,  
}

// Last 2nd Nav Item Orange Button HOVER //
.Header-nav.Header-nav--secondary a:last-child {
  background-color: #fafafa;
  color: #ea7c3a;
  border: 2px solid #ea7c3a;
}
.Header-nav.Header-nav--secondary a:last-child:hover {
  background-color: #ea7c3a;
  color: white;
}

The button turned out great, however, the last item inside the folder I have on the secondary navigation is displaying the same formatting. How can I fix this so that the button formats only show on the call to action (secondary navigation item), and not inside the last folder item.

Any help is greatly appreciated!

Edited by Plenitud
Link to post
  • Answers 2
  • Created
  • Last Reply

Top Posters For This Question

Top Posters For This Question

2 answers to this question

Recommended Posts

  • 0

Edit to

// Last 2nd Nav Item Orange Button //
.Header-nav.Header-nav--secondary a[href="/donate"] {
    background-color: #ffffff; /* button color */
      color: #ea7c3a; /* text color */
      border: 2px solid #ea7c3a;
    padding: 15px !important;
    border-radius: 2px,  
}

// Last 2nd Nav Item Orange Button HOVER //
.Header-nav.Header-nav--secondary a[href="/donate"] {
  background-color: #fafafa;
  color: #ea7c3a;
  border: 2px solid #ea7c3a;
}
.Header-nav.Header-nav--secondary a[href="/donate"]:hover {
  background-color: #ea7c3a;
  color: white;
}

 

You can send your question to my email to get detail answer. / How to Setup Password & Share URL

--- Happy New Year

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • Create New...