1

I am using the bootstrap base css to style my table. However, on Chrome, I am unable to enter any input onto the table. I have changed it to checkboxes as well and nothing works.

I have tried it on Safari and on mobile and the input works. I am not using any extra css. My base css is the theme SBAdmin2 and I am using bootstrap css 3.3.7.

I am using CodeIgniter as my framework. I hope someone can help or someone has encountered this before.

This is my code

<div class="row">
    <div class="row col-md-6">
        <?php echo form_open_multipart('Events/Two/Search');?>
            <div class="input-group">
                <input type="text" name="search" id="search" class="form-control" placeholder="Search e.g. John Cena">
                <span class="input-group-btn">
                    <button type="submit" class="btn btn-primary">
                       <i class="fa fa-search" aria-hidden="true"></i>
                    </button>
                </span>
            </div>
        <?php echo form_close(); ?>
    </div>
    <div class="row col-md-12 table-responsive">
        <?php echo form_open_multipart('Events/Two/Search');?>
        <table class="table table-bordered">
            <thead>
                <tr>
                    <td></td>
                    <td>Name</td>
                    <td>Email</td>
                    <td>Phone Number</td>
                    <td>Address</td>
                </tr>
            </thead>
            <tbody>

                <?php 
                    if(!empty($datatable)){
                        foreach ($datatable as $data){

                ?>
                    <tr>
                        <td><input type="email" name="email" id="email"/></td>
                        <td><?php echo $data->first_name." ".$data->last_name; ?></td>
                        <td><?php echo $data->email; ?></td>
                        <td><?php echo $data->phone_number; ?></td>
                        <td><?php echo $data->address;?></td>
                    </tr>
                <?php 
                    }
                }
                ?>
            </tbody>
        </table>
        <?php echo form_close(); ?>
    </div>
    <div class="row col-lg-12">
        <div class="pull-right">
            <?php echo $links; ?>
        </div>
    </div>
    <div class="row col-lg-12">
        <div class="pull-right">
            <input type="submit" class="btn btn-primary" value="Next">
        </div>
    </div>
</div>
JianYA
  • 2,750
  • 8
  • 60
  • 136

1 Answers1

1

U need to use the class col-md-* for normal screens col-sm-* for tablet screen and col-xs-*

<div class="row">
<div class="col-sm-12">
    <table class="table table-bordered">
        <thead>
            <tr>
                <th>Very Small</th>
                <th>Very Small</th>
                <th>Very Small</th>
                <th>Large</th>
                <th>Small</th>
                <th>Medium</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td class="col-sm-1">
                    <input class="col-sm-12" placeholder="col-sm-1" />
                </td>
                <td class="col-sm-1">
                    <input class="col-sm-12" placeholder="col-sm-1" />
                </td>
                <td class="col-sm-1">
                    <input class="col-sm-12" placeholder="col-sm-1" />
                </td>
                <td class="col-sm-4">
                    <input class="col-sm-12" placeholder="col-sm-4" />
                </td>
                <td class="col-sm-2">
                    <input class="col-sm-12" placeholder="col-sm-2" />
                </td>
                <td class="col-sm-3">
                    <input class="col-sm-12" placeholder="col-sm-3" />
                </td>
            </tr>
        </tbody>
    </table>
</div>

Md.Jewel Mia
  • 3,345
  • 3
  • 19
  • 24