3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = '{"527":{"id":"527","f_id":"49","e_id":"12","data":"{\\"e_id\\":\\"12\\",\\"name\\":\\"HTML\\",\\"html\\":\\"In this example, you can see how elements can conditionally set other values. This is useful if you want to restrict certain element values to be changed by the user.\\\\r\\\\n\\\\r\\\\nSubtotal values cannot be set since these elements are calculated separately.\\\\r\\\\n\\\\r\\\\n&lt;strong&gt;Please note that target values cannot be changed by the user this way!&lt;\\\\\\/strong&gt;\\",\\"show_in_email\\":\\"1\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"6\\"}","position":"6"},"522":{"id":"522","f_id":"49","e_id":"4","data":"{\\"e_id\\":\\"4\\",\\"name\\":\\"Set values\\",\\"label\\":\\"Set values\\",\\"required\\":\\"0\\",\\"calculate_enabled\\":\\"0\\",\\"is_currency\\":\\"0\\",\\"options\\":[{\\"value\\":\\"1\\",\\"text\\":\\"10\\"},{\\"value\\":\\"2\\",\\"text\\":\\"20\\"},{\\"value\\":\\"3\\",\\"text\\":\\"30\\"}],\\"calculate\\":[{\\"operator\\":\\"0\\",\\"target\\":\\"0\\",\\"value\\":\\"\\"}],\\"overwrite_price\\":\\"0\\",\\"calculate_before\\":\\"0\\",\\"conditional\\":[{\\"action\\":\\"set\\",\\"target\\":\\"4\\",\\"target_value\\":\\"10\\",\\"operator\\":\\"equals\\",\\"value\\":\\"1\\"},{\\"action\\":\\"set\\",\\"target\\":\\"4\\",\\"target_value\\":\\"20\\",\\"operator\\":\\"equals\\",\\"value\\":\\"2\\"},{\\"action\\":\\"set\\",\\"target\\":\\"4\\",\\"target_value\\":\\"30\\",\\"operator\\":\\"equals\\",\\"value\\":\\"3\\"},{\\"action\\":\\"set\\",\\"target\\":\\"3\\",\\"target_value\\":\\"10\\",\\"operator\\":\\"equals\\",\\"value\\":\\"1\\"},{\\"action\\":\\"set\\",\\"target\\":\\"3\\",\\"target_value\\":\\"20\\",\\"operator\\":\\"equals\\",\\"value\\":\\"2\\"},{\\"action\\":\\"set\\",\\"target\\":\\"3\\",\\"target_value\\":\\"30\\",\\"operator\\":\\"equals\\",\\"value\\":\\"3\\"},{\\"action\\":\\"set\\",\\"target\\":\\"2\\",\\"target_value\\":\\"10\\",\\"operator\\":\\"equals\\",\\"value\\":\\"1\\"},{\\"action\\":\\"set\\",\\"target\\":\\"2\\",\\"target_value\\":\\"20\\",\\"operator\\":\\"equals\\",\\"value\\":\\"2\\"},{\\"action\\":\\"set\\",\\"target\\":\\"2\\",\\"target_value\\":\\"30\\",\\"operator\\":\\"equals\\",\\"value\\":\\"3\\"},{\\"action\\":\\"set\\",\\"target\\":\\"1\\",\\"target_value\\":\\"10\\",\\"operator\\":\\"equals\\",\\"value\\":\\"1\\"},{\\"action\\":\\"set\\",\\"target\\":\\"1\\",\\"target_value\\":\\"20\\",\\"operator\\":\\"equals\\",\\"value\\":\\"2\\"},{\\"action\\":\\"set\\",\\"target\\":\\"1\\",\\"target_value\\":\\"30\\",\\"operator\\":\\"equals\\",\\"value\\":\\"3\\"}],\\"discount\\":[{\\"range_min\\":\\"\\",\\"range_max\\":\\"\\",\\"operator\\":\\"0\\",\\"discount_value\\":\\"\\"}],\\"show_in_email\\":\\"1\\",\\"class\\":\\"\\",\\"style\\":\\"\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"6\\"}","position":"5"},"523":{"id":"523","f_id":"49","e_id":"7","data":"{\\"e_id\\":\\"7\\",\\"name\\":\\"Numbers\\",\\"label\\":\\"Numbers\\",\\"required\\":\\"0\\",\\"calculate_enabled\\":\\"1\\",\\"is_currency\\":\\"1\\",\\"factor\\":\\"\\",\\"value\\":\\"\\",\\"value_external\\":\\"\\",\\"min\\":\\"0\\",\\"max\\":\\"100\\",\\"slider\\":\\"0\\",\\"steps_slider\\":\\"1\\",\\"spinner\\":\\"0\\",\\"steps_spinner\\":\\"1\\",\\"calculate\\":[{\\"operator\\":\\"0\\",\\"target\\":\\"0\\",\\"value\\":\\"\\"}],\\"overwrite_price\\":\\"0\\",\\"calculate_before\\":\\"0\\",\\"conditional\\":[{\\"action\\":\\"0\\",\\"target\\":\\"0\\",\\"target_value\\":\\"\\",\\"operator\\":\\"0\\",\\"value\\":\\"\\"}],\\"discount\\":[{\\"range_min\\":\\"\\",\\"range_max\\":\\"\\",\\"operator\\":\\"0\\",\\"discount_value\\":\\"\\"}],\\"placeholder\\":\\"\\",\\"show_in_email\\":\\"1\\",\\"class\\":\\"\\",\\"style\\":\\"\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"3\\"}","position":"4"},"524":{"id":"524","f_id":"49","e_id":"4","data":"{\\"e_id\\":\\"4\\",\\"name\\":\\"Dropdown\\",\\"label\\":\\"Dropdown\\",\\"required\\":\\"0\\",\\"calculate_enabled\\":\\"1\\",\\"is_currency\\":\\"1\\",\\"options\\":[{\\"value\\":\\"10\\",\\"text\\":\\"Option 10\\"},{\\"value\\":\\"20\\",\\"text\\":\\"Option 20\\"},{\\"value\\":\\"30\\",\\"text\\":\\"Option 30\\"}],\\"calculate\\":[{\\"operator\\":\\"0\\",\\"target\\":\\"0\\",\\"value\\":\\"\\"}],\\"overwrite_price\\":\\"0\\",\\"calculate_before\\":\\"0\\",\\"conditional\\":[{\\"action\\":\\"0\\",\\"target\\":\\"0\\",\\"target_value\\":\\"\\",\\"operator\\":\\"0\\",\\"value\\":\\"\\"}],\\"discount\\":[{\\"range_min\\":\\"\\",\\"range_max\\":\\"\\",\\"operator\\":\\"0\\",\\"discount_value\\":\\"\\"}],\\"show_in_email\\":\\"1\\",\\"class\\":\\"\\",\\"style\\":\\"\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"3\\"}","position":"3"},"525":{"id":"525","f_id":"49","e_id":"5","data":"{\\"e_id\\":\\"5\\",\\"name\\":\\"Radio\\",\\"label\\":\\"Radio\\",\\"required\\":\\"0\\",\\"calculate_enabled\\":\\"1\\",\\"is_currency\\":\\"1\\",\\"options\\":[{\\"value\\":\\"10\\",\\"text\\":\\"Option 10\\"},{\\"value\\":\\"20\\",\\"text\\":\\"Option 20\\"},{\\"value\\":\\"30\\",\\"text\\":\\"Option 30\\"}],\\"calculate\\":[{\\"operator\\":\\"0\\",\\"target\\":\\"0\\",\\"value\\":\\"\\"}],\\"overwrite_price\\":\\"0\\",\\"calculate_before\\":\\"0\\",\\"conditional\\":[{\\"action\\":\\"0\\",\\"target\\":\\"0\\",\\"target_value\\":\\"\\",\\"operator\\":\\"0\\",\\"value\\":\\"\\"}],\\"discount\\":[{\\"range_min\\":\\"\\",\\"range_max\\":\\"\\",\\"operator\\":\\"0\\",\\"discount_value\\":\\"\\"}],\\"show_in_email\\":\\"1\\",\\"class\\":\\"\\",\\"style\\":\\"\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"3\\"}","position":"2"},"526":{"id":"526","f_id":"49","e_id":"6","data":"{\\"e_id\\":\\"6\\",\\"name\\":\\"Checkbox\\",\\"label\\":\\"Checkbox\\",\\"required\\":\\"0\\",\\"calculate_enabled\\":\\"1\\",\\"is_currency\\":\\"1\\",\\"options\\":[{\\"value\\":\\"10\\",\\"text\\":\\"Checkbox 10\\"},{\\"value\\":\\"20\\",\\"text\\":\\"Checkbox 20\\"},{\\"value\\":\\"30\\",\\"text\\":\\"Checkbox 30\\"}],\\"preselect\\":\\"\\",\\"calculate\\":[{\\"operator\\":\\"0\\",\\"target\\":\\"0\\",\\"value\\":\\"\\"}],\\"overwrite_price\\":\\"0\\",\\"calculate_before\\":\\"0\\",\\"conditional\\":[{\\"action\\":\\"0\\",\\"target\\":\\"0\\",\\"target_value\\":\\"\\",\\"operator\\":\\"0\\",\\"value\\":\\"\\"}],\\"discount\\":[{\\"range_min\\":\\"\\",\\"range_max\\":\\"\\",\\"operator\\":\\"0\\",\\"discount_value\\":\\"\\"}],\\"show_in_email\\":\\"1\\",\\"class\\":\\"\\",\\"style\\":\\"\\",\\"hidden\\":\\"0\\",\\"columns\\":\\"3\\"}","position":"1"}}'; echo stripslashes($a);
Output for 4.3.0 - 7.2.0
{"527":{"id":"527","f_id":"49","e_id":"12","data":"{"e_id":"12","name":"HTML","html":"In this example, you can see how elements can conditionally set other values. This is useful if you want to restrict certain element values to be changed by the user.\r\n\r\nSubtotal values cannot be set since these elements are calculated separately.\r\n\r\n&lt;strong&gt;Please note that target values cannot be changed by the user this way!&lt;\/strong&gt;","show_in_email":"1","hidden":"0","columns":"6"}","position":"6"},"522":{"id":"522","f_id":"49","e_id":"4","data":"{"e_id":"4","name":"Set values","label":"Set values","required":"0","calculate_enabled":"0","is_currency":"0","options":[{"value":"1","text":"10"},{"value":"2","text":"20"},{"value":"3","text":"30"}],"calculate":[{"operator":"0","target":"0","value":""}],"overwrite_price":"0","calculate_before":"0","conditional":[{"action":"set","target":"4","target_value":"10","operator":"equals","value":"1"},{"action":"set","target":"4","target_value":"20","operator":"equals","value":"2"},{"action":"set","target":"4","target_value":"30","operator":"equals","value":"3"},{"action":"set","target":"3","target_value":"10","operator":"equals","value":"1"},{"action":"set","target":"3","target_value":"20","operator":"equals","value":"2"},{"action":"set","target":"3","target_value":"30","operator":"equals","value":"3"},{"action":"set","target":"2","target_value":"10","operator":"equals","value":"1"},{"action":"set","target":"2","target_value":"20","operator":"equals","value":"2"},{"action":"set","target":"2","target_value":"30","operator":"equals","value":"3"},{"action":"set","target":"1","target_value":"10","operator":"equals","value":"1"},{"action":"set","target":"1","target_value":"20","operator":"equals","value":"2"},{"action":"set","target":"1","target_value":"30","operator":"equals","value":"3"}],"discount":[{"range_min":"","range_max":"","operator":"0","discount_value":""}],"show_in_email":"1","class":"","style":"","hidden":"0","columns":"6"}","position":"5"},"523":{"id":"523","f_id":"49","e_id":"7","data":"{"e_id":"7","name":"Numbers","label":"Numbers","required":"0","calculate_enabled":"1","is_currency":"1","factor":"","value":"","value_external":"","min":"0","max":"100","slider":"0","steps_slider":"1","spinner":"0","steps_spinner":"1","calculate":[{"operator":"0","target":"0","value":""}],"overwrite_price":"0","calculate_before":"0","conditional":[{"action":"0","target":"0","target_value":"","operator":"0","value":""}],"discount":[{"range_min":"","range_max":"","operator":"0","discount_value":""}],"placeholder":"","show_in_email":"1","class":"","style":"","hidden":"0","columns":"3"}","position":"4"},"524":{"id":"524","f_id":"49","e_id":"4","data":"{"e_id":"4","name":"Dropdown","label":"Dropdown","required":"0","calculate_enabled":"1","is_currency":"1","options":[{"value":"10","text":"Option 10"},{"value":"20","text":"Option 20"},{"value":"30","text":"Option 30"}],"calculate":[{"operator":"0","target":"0","value":""}],"overwrite_price":"0","calculate_before":"0","conditional":[{"action":"0","target":"0","target_value":"","operator":"0","value":""}],"discount":[{"range_min":"","range_max":"","operator":"0","discount_value":""}],"show_in_email":"1","class":"","style":"","hidden":"0","columns":"3"}","position":"3"},"525":{"id":"525","f_id":"49","e_id":"5","data":"{"e_id":"5","name":"Radio","label":"Radio","required":"0","calculate_enabled":"1","is_currency":"1","options":[{"value":"10","text":"Option 10"},{"value":"20","text":"Option 20"},{"value":"30","text":"Option 30"}],"calculate":[{"operator":"0","target":"0","value":""}],"overwrite_price":"0","calculate_before":"0","conditional":[{"action":"0","target":"0","target_value":"","operator":"0","value":""}],"discount":[{"range_min":"","range_max":"","operator":"0","discount_value":""}],"show_in_email":"1","class":"","style":"","hidden":"0","columns":"3"}","position":"2"},"526":{"id":"526","f_id":"49","e_id":"6","data":"{"e_id":"6","name":"Checkbox","label":"Checkbox","required":"0","calculate_enabled":"1","is_currency":"1","options":[{"value":"10","text":"Checkbox 10"},{"value":"20","text":"Checkbox 20"},{"value":"30","text":"Checkbox 30"}],"preselect":"","calculate":[{"operator":"0","target":"0","value":""}],"overwrite_price":"0","calculate_before":"0","conditional":[{"action":"0","target":"0","target_value":"","operator":"0","value":""}],"discount":[{"range_min":"","range_max":"","operator":"0","discount_value":""}],"show_in_email":"1","class":"","style":"","hidden":"0","columns":"3"}","position":"1"}}