1

I am trying to accomplish a data-toggle similar as the code sample when run on a desktop browser.

The problem of this code is that it does not run on mobile. example: Samsung(s6, s7) and Apple(Iphone 6s and 7s)

<div class="row">
        <div class="faq">   
            <div class="container">
                <div class="col-md-12">
                    <h1>FREQUENTLY ASKED QUESTIONS</h1>
                </div>
                <table class="table">
                    <thead>
                        <th>General</th>
                    </thead>

                    <tbody>
                        <tr data-toggle="collapse" data-target="#faq6" class="clickable faq-header">
                            <td>What are your hours of operation?
                            </td>
                        </tr>
                        <tr>
                            <td colspan="3">
                                <div id="faq6" class="collapse">
                                    Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.
                                </div>
                            </td>
                        </tr>

                        <tr data-toggle="collapse" data-target="#faq7" class="clickable faq-header">
                            <td>What is the minimum storage period?
                            </td>
                        </tr>
                        <tr>
                            <td colspan="3">
                                <div id="faq7" class="collapse">
                                    You can store as short as three months. But the longer you store the more money you will save!
                                </div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
     </div>

I expect it to be just as the same as the browser where is when you click a question it will trigger and show the corresponding answer.

The actual result I currently get is that it does not respond to any touch/tap. my menu dropdown works and etc but the data-toggles seems to be not responding.

I have tried these answers: The data-toggle attributes in Twitter Bootstrap / Bootstrap3 accordion table not working on IOS mobile / Bootstrap data-toggle not working in Safari / but none of them apparently seems to work for me

Cœur
  • 37,241
  • 25
  • 195
  • 267
Kevz
  • 604
  • 2
  • 8
  • 23

1 Answers1

2

Try adding href="#" to the <a tag, which is actually not shown in your question. That solved it for me.

Alex R
  • 11,364
  • 15
  • 100
  • 180