3v4l.org

run code in 500+ PHP versions simultaneously
<?php if ( ! is_admin() ) { global $woocommerce; $cart_total_prod1 = 1100; $cart_total_prod2 = 1500; $cart_total_prod3 = 2000; if( $woocommerce->cart->total >= $cart_total_prod1 && $woocommerce->cart->total <= $cart_total_prod2) { echo "подарок 1"; } if( $woocommerce->cart->total >= $cart_total_prod2 && $woocommerce->cart->total <= $cart_total_prod3) { echo "подарок 2"; } if( $woocommerce->cart->total >= $cart_total_prod3) { echo "подарок 3"; } } ?>
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function is_admin() in /in/OLpSZ:4 Stack trace: #0 {main} thrown in /in/OLpSZ on line 4
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
51.99 ms | 1508 KiB | 4 Q