-2
작은 문제가 있습니다. 24 가지 경우에 모달을 사용해야합니다.이 ID를 모달 ID로 테스트하고 결과를 표시하려면 모달로 이동하기 전에 ID를 얻어야합니다. 모달로. 나는 잘 표현했는지 모르겠다! 그러나 여기 당신이 수동으로 모든 24 조동사를 만드는 것 같다 코드모달에서 사용할 변수 복구
<!-- Modal -->
<?php
$x=7;
$case = $fun -> getCaseByIde($x);
?>
<div id="myModal-<?php echo $x; ?>" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<!-- Modal content-->
<div class="modal-content" style="text-align: center;">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h1><?php echo $x; $case['titre']; ?></h1>
</div>
</div>
</div>
</div>
<!-- #END# Modal -->
<!-- Modal -->
<?php
$x=8;
$case = $fun -> getCaseByIde($x);
?>
<div id="myModal-<?php echo $x; ?>" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<!-- Modal content-->
<div class="modal-content" style="text-align: center;">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h1><?php echo $x; $case['titre']; ?></h1>
</div>
</div>
</div>
</div>
<!-- #END# Modal -->
<!-- Modal -->
<?php
$x=9;
$case = $fun -> getCaseByIde($x);
?>
<div id="myModal-<?php echo $x; ?>" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<!-- Modal content-->
<div class="modal-content" style="text-align: center;">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h1><?php echo $x; $case['titre']; ?></h1>
</div>
</div>
</div>
</div>
<!-- #END# Modal -->
영어로 부탁드립니다. – aynber
안녕하세요, 작은 문제가 있습니다. 24 가지 사례에 대해 모달을 사용해야합니다.이 ID를 모달 ID로 테스트하고 모달에 결과를 표시하려면 모달로 이동하기 전에 ID를 얻어야합니다. 나는 잘 표현했는지 모르겠다! 여기에 코드가 있습니다 –
덧글로 추가하는 대신 더 자세한 개요를 보려면 추가 정보로 질문을 편집하십시오; – BenRoob