trivektor
unread,Apr 2, 2012, 1:45:33 AM4/2/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to easyxdm
Hi,
I have a Backbone JS model called listing_info (listing_info =
Backbone.Model). I set up my socket provider such that when it
receives a specific message from the consumer, it's going to persist
listing_info thru an ajax call.
Here's my provider socket
var socket = new easyXDM.Socket({
remote: "/blank.html", //without this I got an error "X is
undefined"
onMessage: function(message, origin) {
console.log(listing_info.attributes)
}
})
The strange thing happens in onMessage. Even though I have written new
attribute values to listing_info (and I can verify that the attributes
have been updated properly), when I do console.log, listing_info still
retains the old , original attribute values.
I wonder if anyone has experienced this issue?