Adding text banners to your site

Created by Ezra Weinstein, Modified on Tue, Jul 9 at 11:45 PM by Raymond Sarreal


  1. Navigate to Website > Templates > click Content Tab and Insert %module:fragment:TEXT_SLIDER% after the <header> tag.


  1. Once added, navigate to Website > Fragments. Create a new Fragment called “Text Slider”



  1. Insert this content into the Fragment’s content. 


<style>

 .text-slider {

   background-color#000000/*Update this*/

   color#ffffff/*Update this*/

   padding5px;

   text-aligncenter;

 }

 .text-slider p {

   margin0;

 }

</style>


<div class="text-slider">

 <div class="text-item">

   <p>Update me</p> 

 </div>

 <div class="text-item">

   <p>You can delete me or add a new text slider</p> <!--Update this-->

 </div>

</div>


<script>

 $(function () {

   var $textSlider = $(".text-slider");

   $textSlider

     .slick({

       arrows: false,

       autoplaySpeed: 5000,

       autoplay: true,

       dots: false,

       infinite: true,

     })

     .on("setPosition"function () {

       if (!($(this).find('.slick-slide').length > 1)) {

         $(this).find(".slick-arrow").hide();

       }

     });

 })

</script>


  1. Update the background and color in the <style></style> section to match your website’s theme. The text to be displayed should also be updated and if you want to add more.  Insert this element: 


 <div class="text-item">

   <p>Update me</p> 

 </div>


  1. Click Save.


    

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article