Когда пользователь нажимает на стрелку, чтобы изменить отзыв, как я могу заставить его перейти к следующему комментарию? - PullRequest
0 голосов
/ 20 марта 2019

Когда я нажимаю на стрелку, чтобы изменить отзыв, моя страница автоматически прокручивается вверх страницы? Ниже представлен HTML-код для слайдера для раздела отзывов. Когда пользователь нажимает на стрелку, чтобы изменить отзыв, как я могу заставить его перейти к следующему комментарию? Github repo , если вам нужно посмотреть больше кода. Это для страницы index.html.

<!-- Section -->
<div class="template-section template-section-padding-reset template-clear-fix">
<!-- Flex layout 50x50% -->
<div class="template-layout-flex template-clear-fix template-background-color-1">
<!-- Left column -->
<div>
   <!-- Header + subheader -->
   <div class="template-component-header-subheader">
      <h2>Testimonials</h2>
      <div></div>
      <span>Our customers love us</span>
   </div>
   <!-- Space -->
   <div class="template-component-space template-component-space-2"></div>
   <!-- Testimonials list -->
   <div class="template-component-testimonial-list template-clear-fix">
      <!-- Content -->
      <ul class="template-clear-fix">
         <li>
            <p>I could not be happier with the job you did on my car. It looks great. Thank you for your great service and I will continue to refer friends and family to you all.</p>
            <h6>Dotti Newman</h6>
            <span>Audi Q5</span>
         </li>
         <li>
            <p>I think Auto Spa is the best car washers ever. Love the price, convenience and customer service. Thanks so much! My car looks like new. I will definitely come again.</p>
            <h6>David Magnus</h6>
            <span>Nissan Titan X5</span>
         </li>
         <li>
            <p>Finally a car wash that does pay attention to the detail. I have a little extra time and money and I let them do the full detail and it always has turned out great.</p>
            <h6>Josh Williams</h6>
            <span>Toyota Avensis</span>
         </li>
      </ul>
      <!-- Navigation -->
      <div class="template-component-testimonial-list-navigation">
         <a href="#" class="template-component-testimonial-list-navigation-left template-icon-meta-arrow-large-rl"></a>
         <span class="template-component-testimonial-list-navigation-center template-icon-feature-testimonials"></span>
         <a href="#" class="template-component-testimonial-list-navigation-right template-icon-meta-arrow-large-rl"></a>
      </div>
   </div>
</div>

1 Ответ

0 голосов
/ 20 марта 2019

Добавить тег ID. Для этого взгляните на это https://www.w3schools.com/html/html_id.asp

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...