값 (자바 스크립트)이있는 경우 섹션 숨기기, 나는 내보기에 일부 변수를 전달 OR "> 0"나는 HIDE이 원하는Laravel 5.1 변수 내가 laravel 5.1 (전자 상거래)와 함께 일하고 있어요
예를 들어 10, 20 등 ...에 대한 :
<tr class="cart-subtotal" id="coupon">
<th>Coupon:</th>
<td>
<span class="amount">€{{ number_format($price_coupon, 2) }}</span>
</td>
</tr>
$ price_coupon IF = 0 AND $ price_coupon> 0
내가 생각하는 경우 표시 그것은 바로 자바 스크립트에 대한 기능입니까? 어떻게 할 수 있니? 도와 줘서 고마워!
이 내보기의 모든 테이블 : 주문 detail.php
<table>
<tbody>
<tr class="cart-subtotal">
<th>Subtotale:</th>
<td><span class="amount">€{{ number_format($total, 2) }}</span></td>
</tr>
<tr class="cart-subtotal" id="coupon">
<th>Coupon:</th>
<td><span class="amount">€{{ number_format($price_coupon, 2) }}</span></td>
</tr>
<tr class="shipping">
<th>shipping:</th>
<td>€<input type="text" id="price_ship" name="price_ship" class="price_ship" disabled /></td>
</tr>
<tr class="order-total">
<th>Totale Ordine:</th>
<td><strong><span class="amount">
€<input type="text" id="total_ship" name="total_ship" class="total_ship" disabled />
</span></strong> </td>
</tr>
</tbody>
</table>
내가이 질문을 수정 : 나는 또한 블레이드 템플릿을 사용하고 있습니다. 자바 스크립트
'경우 (X == 0) {...}''--- 경우 (x> 0) {...}' . –
이것이 마지막 단계 인 경우 Blade에서 직접 숨겨야합니다. – Pyton
나는 어떻게 잎에 그것을 점칠 수 있냐? –