Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS how to build a slide down page content?

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #34993
    bhuten
    Participant

    I am wondering how to incorporate a smooth slide down content like this one on CSS Tricks : https://css-tricks.com/snippets/

    #89988
    Sam_Purcell
    Member

    I’m not sure if this was how CSSTricks did it, but I assume that the slide function is either js or a -webkit-transition. Using the transition function in combo with a position change upon clicking the bar could yield that effect. I’m no js expert, but code like:

    function HideContent(d) {
    document.getElementById(d).style.display = “none”;
    }
    function ShowContent(d) {
    document.getElementById(d).style.display = “block”;
    }
    function ReverseDisplay(d) {
    if(document.getElementById(d).style.display == “block”) { document.getElementById(d).style.display = “none”; }
    else { document.getElementById(d).style.display = “block”; }
    }

    would show the divs containing the links. Again, not an expert, just thinking out loud.

    #90096
    bhuten
    Participant

    Thanks! I figured out from your links!

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.