Code Duplication    Length = 10-11 lines in 3 locations

views/life/editPlayer.php 3 locations

@@ 352-362 (lines=11) @@
349
                        ?>
350
                        <div class="tab-pane fade well" id="civ_inv">
351
                            <?php
352
                            if ($player->civ_gear !== '"[]"' && $player->civ_gear !== '') {
353
                                echo '<h4 style="centred">'.$lang['civil'].' '.$lang['gear'].'</h4>';
354
                                echo "<textarea class='form-control' readonly rows='5' style='width: 100%' id='civ_gear' name='civ_gear'>".$player->civ_gear.'</textarea><br>';
355
356
                                if ($_SESSION['permissions']['edit']['inventory']) {
357
                                    echo '<a data-toggle="modal" href="#edit_civ_inv" class="btn btn-primary btn-xs" style="float: right;">';
358
                                    echo '<i class="fa fa-pencil"></i></a>';
359
                                }
360
                            } else {
361
                                echo '<h4>'.errorMessage(381, $lang).'</h4>';
362
                            } ?>
363
                        </div>
364
                        <div class="tab-pane fade well" id="police_inv">
365
                            <?php
@@ 366-375 (lines=10) @@
363
                        </div>
364
                        <div class="tab-pane fade well" id="police_inv">
365
                            <?php
366
                            if ($player->cop_gear !== '"[]"' && $player->cop_gear !== '') {
367
                                echo '<h4 style="centred">'.$lang['cop'].' '.$lang['gear'].'</h4>';
368
                                echo "<textarea class='form-control' readonly rows='5' style='width: 100%' id='cop_gear' name='cop_gear'>".$player->cop_gear.'</textarea><br>';
369
                                if ($_SESSION['permissions']['edit']['inventory']) {
370
                                    echo '<a data-toggle="modal" href="#edit_cop_inv" class="btn btn-primary btn-xs" style="float: right;">';
371
                                    echo '<i class="fa fa-pencil"></i></a>';
372
                                }
373
                            } else {
374
                                echo '<h4>'.errorMessage(383, $lang).'</h4>';
375
                            } ?>
376
                        </div>
377
                        <div class="tab-pane fade well" id="medic_inv">
378
                            <?php
@@ 379-388 (lines=10) @@
376
                        </div>
377
                        <div class="tab-pane fade well" id="medic_inv">
378
                            <?php
379
                            if ($player->med_gear !== '"[]"' && $player->med_gear !== '') {
380
                                echo '<h4 style="centred">'.$lang['medic'].' '.$lang['gear'].'</h4>';
381
                                echo "<textarea class='form-control' readonly rows='5' style='width: 100%' id='med_gear' name='med_gear'>".$player->med_gear.'</textarea><br>';
382
                                if ($_SESSION['permissions']['edit']['inventory']) {
383
                                    echo '<a data-toggle="modal" href="#edit_med_inv" class="btn btn-primary btn-xs" style="float: right;">';
384
                                    echo '<i class="fa fa-pencil"></i></a>';
385
                                }
386
                            } else {
387
                                echo '<h4>'.errorMessage(382, $lang).'</h4>';
388
                            } ?>
389
                        </div>
390
                        <?php
391
                    }