![]() |
|
Little Help Needed - Rotating Text with CSS - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Webmasters (https://hackforums.net/forumdisplay.php?fid=141) +---- Forum: Website Construction (https://hackforums.net/forumdisplay.php?fid=50) +---- Thread: Little Help Needed - Rotating Text with CSS (/showthread.php?tid=6005775) |
Little Help Needed - Rotating Text with CSS - Rishabh - Sep 7, 2019 Hey guys! So I referred to this guide - https://labrumfield.com/rotating-text-with-css-animations/ for adding rotating text in a heading on my webpage. I had to obviously modify the final output used by the blogger there in order for it suite my web page's design. Essentially, my heading is aligned centrally, while she has aligned it to the left. Like her, I am using the code to rotate three sets of words as well. So you can refer to the final set of code she used on her website. The problem I am facing is that each set is coming down below the other, rather than showing up in the same place as the last set, i.e. this - https://gph.is/g/apVDXd6 Here's the code - HTML: Code <div id="cspio-content" class="wrapper">CSS: Code /*Wrapper*/I am just not sure how to go about fixing this issue at the moment. Any help would be appreciated. RE: Little Help Needed - Rotating Text with CSS - Nachfolger - Sep 7, 2019 Looks like they should be placed in a absolute position, rather than relative to eachother. In fact, her code even shows this, and I'm not sure why you changed it to position: relative; Code .slidingVertical span{RE: Little Help Needed - Rotating Text with CSS - Rishabh - Sep 7, 2019 (Sep 7, 2019 12:32 PM)Nachfolger Wrote: Looks like they should be placed in a absolute position, rather than relative to eachother. In fact, her code even shows this, and I'm not sure why you changed it to position: relative; That's because putting it in absolute made the animated text drift to the right side, as in not below the 'TECHNOLOGY THAT' line centrally aligned. I'll PM you the link to the web page if you could have a look? RE: Little Help Needed - Rotating Text with CSS - Nachfolger - Sep 7, 2019 (Sep 7, 2019 12:52 PM)Rishabh Wrote: That's because putting it in absolute made the animated text drift to the right side, as in not below the 'TECHNOLOGY THAT' line centrally aligned. I'll PM you the link to the web page if you could have a look?I don't usually work out of thread, but that is fine. It will be easier anyway. RE: Little Help Needed - Rotating Text with CSS - Rishabh - Sep 7, 2019 (Sep 7, 2019 12:59 PM)Nachfolger Wrote: I don't usually work out of thread, but that is fine. It will be easier anyway. Thanks! I was just not comfortable posting the link here on the thread. Appreciate your help in advance 🙂 RE: Little Help Needed - Rotating Text with CSS - Nachfolger - Sep 7, 2019 (Sep 7, 2019 01:16 PM)Rishabh Wrote: Thanks! I was just not comfortable posting the link here on the thread.The following code should solve your issues. Do not copy and paste it, only make the appropriate changes to the existing classes. Code .slidingVertical {Let me know if you have any other issues. RE: Little Help Needed - Rotating Text with CSS - Rishabh - Sep 7, 2019 (Sep 7, 2019 01:44 PM)Nachfolger Wrote: The following code should solve your issues. Do not copy and paste it, only make the appropriate changes to the existing classes. Thank you so much! It works fine now. I also added the css media query for smaller devices and altered the height for slidingVertical. Works perfectly! I have been trying to figure out an alternate color, that would go well with all the three colored elements - the animated text, the subtitle below that and the social media icons below that. It's just that the background photo has some contrasting colors under each element, hence a little harder to pick a color with slightly varying shades. |