• I created the website for my tennis club. On the starting site (here page ID=40) there are some links to the actual themes followed by the blog list using the plugin ?content views“ (pt-view ID=0c7aab3kcx).

    As additional feature I want to highlight the thumbnail of a special post (here post-14515) giving a thick red border with radius.

    I found in a former post on this forum an instruction as additional CSS
    .pt-cv-XX a[href=?INSERT_URL_OF_THE_POST_HERE“ ] { }
    in my example I tried
    .pt-cv-thumbnail a[href=”https://…URL_OF_POST-14515″%5D {
    border: 10px #db3200 solid !important;
    border-radius: 7px !important;
    }

    But it doesn‘t work.
    What‘s the correct CSS code?

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter schallmueller

    (@schallmueller)

    Correct line:

    .pt-cv-thumbnail a[href=?https://…URL_OF_POST-14515“] {

    Hi
    Hope I have understood things. If you inspect the CSS selectors relating to the 17 Content View thumbnails on your home page BLOG you get ;

    div.col-md-4:nth-child(1) > div:nth-child(1) > a:nth-child(1) > img:nth-child(1)
    through to…….
    div.col-md-4:nth-child(17) > div:nth-child(1) > a:nth-child(1) > img:nth-child(1)

    So as an example: to change the 5th thumbnail of the BLOG on the homepage with what you want try this CSS:

    #pt-cv-view-0e7aab3kcx div.col-md-4:nth-child(5) > div:nth-child(1) > a:nth-child(1) > img:nth-child(1)
    {border: 10px #db3200 solid; border-radius: 7px}

    Hope it works
    Regards
    Neil

    Thread Starter schallmueller

    (@schallmueller)

    Thank you, it works!

    But I can‘t retrace it!

    When I use the firefox inspector for the 17 thumbnails of my starting page, I receive 17 equal terms:
    <div class=“col-md-4 col-sm-4 col-xs-12 pt-cv-content-item- pt-cv-1-col
    Why?

    And I have another question:

    Is it possible to hide on my website a special post (here postid-14515) in the content views bloglist with an attached condition [here for wide screens: @media screen and (min-width:55.875em)]?

    Glad that worked for you.

    The inspector must highlight just the thumbnail, not the whole CV section. You will then see the individual pt-cv-thumbnail section highlighted inthe Firefox inspector section -so you can right click and choose the CSS Selector.

    As per my previous example to hide the 5th post in the blog I think this would work-so you can adapt it as required. Note: Firefox inspector is highlighting the “pt-cv-ifield” for the 5th thumbnail

    @media screen and (min-width:55.875em) { #pt-cv-view-0e7aab3kcx div.col-md-4:nth-child(5) > div:nth-child(1) {display:none} }

    Hope that all makes sense
    regards
    Neil

    Plugin Author Content Views

    (@pt-guy)

    Hi @ng63,
    Always thank you for your contribution here.

    Hi @schallmueller,
    Thank you for contacting us.

    Your CSS didn’t work because it is invalid.

    It should be

    
    .pt-cv-content-item a[href="FULL_URL_OF_POST"] {
    
    }
    

    And it is possible to hide a specific post in a specific screen size, but it is out of our support for the Free version.
    You can get the PRO version here: https://www.contentviewspro.com/ to get premium support for this kind of request.

    Best regards,

    Thread Starter schallmueller

    (@schallmueller)

    CSS code
    @media screen and (min-width:55.875em) { #pt-cv-view-0e7aab3kcx div.col-md-4:nth-child(5) > div:nth-child(1) {display:none} }
    is working well and it makes sense for me.

    Thank you for your support.

    One more question:
    Is it possible to change the breakpoint for the content views bloglist on the starting page to display 2 columns online in case of a horizontal smartphone screen?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Highlight special post in bloglist on starting page’ is closed to new replies.