i’m having a jquery variable containing so much formatted data created by ckeditor and trying to pass it to another page without reloading so i’m using ajax but can’t pass this variable as a query string because it has so much formatted data so i’m trying to use PersistJS to save this variable. no problem with saving it and calling it back at the same page but the problem occurred when i was testing it. i have 2 pages page1 with this code
var proDetails = $('textarea.editor').val();
var store = new Persist.Store('My Data Store');
var data = proDetails;
store.set('saved_data', data);
page2 containing this code
$(document).ready(function() {
store.get('saved_data', function(ok, val) {
if (ok)
alert('saved data = ' + val);
});
});
but it doesn’t work and for sure i’m calling the persist-min.js in both pages
and if it didn’t work is there anyway to save the proDetails variable in a php session so i can call it in the other page ?
You have not initialized
storeobject on page 2.