mercredi 4 janvier 2017

Assign unserialize Laravel object to JS array

I have serialize object returning from Controller to blade view in laravel like:

"a:3:{i:0;s:1:"2";i:1;s:1:"4";i:2;s:1:"6";}"

from my blade view I use this JS code block to get those value as array.

var branches = ;

But in there I'm getting error saying

expression expected

any suggestions to solve this situation..?



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2iIo2kv
via IFTTT

Aucun commentaire:

Enregistrer un commentaire