php - Storing KineticJS json string in mySQL and then get it with other page to reload the canvas -


i hope understand problem is...

i built little t-shirt-shop kineticjs.

i store stage tojson() in json-string , save in mysql database.

now when try string other page database , insert string kineticjs function

    var stage = kinetic.node.create(json, 'container'); 

it doesn't work.

the curious thing when database , copy whole string directly javascript work. fact string database javascript, save in variable , try use gets me "unexpected token" error.

make sure "json" variable string, not object.

otherwise, make string:

json.stringify(json); 

Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

html - Unable to style the color of bullets in a list -

c# - must be a non-abstract type with a public parameterless constructor in redis -