Answers for "js parse php array"

PHP
1

copy php array to javascript

var js_array = [<?php echo '"'.implode('","', $php_array).'"' ?>];
Posted by: Guest on March-29-2020
1

convert php array to javascript json laravel

<script>
	var js_json_obt = @json($php_array ?? '');
</scritp>
Posted by: Guest on December-07-2020

Browse Popular Code Answers by Language