function postit()

in salesforce/canvas/public/javascripts/canvas-all.js [991:1009]


      function postit(clientscb, message) {
        var wrapped, to, c;
        seq = seq > 100 ? 0 : seq + 1;
        cbs[seq] = clientscb;
        wrapped = {
          seq: seq,
          src: 'client',
          clientVersion: cversion,
          parentVersion: pversion,
          body: message,
        };
        c = message && message.config && message.config.client;
        to = getTargetOrigin($$.isNil(c) ? null : c.targetOrigin);
        if ($$.isNil(to)) {
          throw 'ERROR: targetOrigin was not supplied and was not found on the hash tag, this can result from a redirect or link to another page.';
        }
        $$.console.log('posting message ', { message: wrapped, to: to });
        $$.xd.post(wrapped, to, parent);
      }