You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
jmarnold edited this page Jul 7, 2012
·
1 revision
Overview
It can be handy to pass custom information along to your policies (metadata, jquery objects, etc.). Any options passed along are made available via the options property on the continuation.
There are two ways to do this:
$.ajax
If you are making a simple $.ajax post, you can pass an options object:
$.ajax({ options: { customProperty: '1234' } })
$.correlatedSubmit
If you are using the correlatedSubmit method, any properties you specify will be used as options:
$('#myForm').({ customProperty: '1234' })
Consuming the options
The following is an example of a policy consuming the options: