<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
that's an interesting idea. i'll play with that, thanks adam!<br>
<br>
i need the ajax handling for the case of someone hitting the save
button on the canvas itself (and would like to keep that for ui
purposes), but i might be able to wing it using drupal's usual ahah
handling.<br>
<br>
On 11/18/2010 09:38 AM, Adam Gregory wrote:
<blockquote
 cite="mid:AANLkTikf0efY6Uedgeh05QvDjWbo6upKSFDvxuNOi4YB@mail.gmail.com"
 type="cite">Just a thought but why not just write the canvas data to a
hidden form field and then process it with the form data? Do you really
need to send it via ajax to be processed and then submit the form? I
know it creates a Huge post object but you're still dealing with the
same thing if you are sending it via ajax just with an extra step.<br
 clear="all">
-----<br>
Adam A. Gregory<br>
Drupal Developer &amp; Consultant<br>
Web: AdamAGregory.com<br>
Twitter: <a moz-do-not-send="true"
 href="http://twitter.com/adamgregory" target="_blank">twitter.com/adamgregory</a><br>
skype: aagregory2<br>
Phone: 910.808.1717<br>
Cell: 919.306.6138<br>
  <br>
  <br>
  <div class="gmail_quote">On Tue, Nov 16, 2010 at 1:48 PM, Aaron
Winborn <span dir="ltr">&lt;<a moz-do-not-send="true"
 href="mailto:winborn@advomatic.com">winborn@advomatic.com</a>&gt;</span>
wrote:<br>
  <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I'm
creating an HTML5 canvas editor for a filefield widget, which uploads a
canvas image, returning an FID to be stored in a textfield. Everything
works, except that now I want to delay node submission until the canvas
has a chance to save its work (assuming its associated 'Save' button
hasn't yet been clicked).<br>
    <br>
I'm mostly there, thanks to some help from merlinofchaos. Currently, I
save the work and return false on the submit/preview click, and
trigger('submit') after the ajax call to save the canvas. However, it's
not quite working -- the canvas saves properly, storing the new fid in
the field, but the form is reloaded, rather than processing.<br>
    <br>
    <a moz-do-not-send="true" href="http://drupalbin.com/16680"
 target="_blank">http://drupalbin.com/16680</a><br>
    <br>
Any ideas?<br>
    <br>
Thanks,<br>
Aaron<br>
    <br>
-- <br>
Aaron Winborn<br>
    <br>
Advomatic, LLC<br>
    <a moz-do-not-send="true" href="http://advomatic.com/"
 target="_blank">http://advomatic.com/</a><br>
    <br>
Drupal Multimedia available now!<br>
    <a moz-do-not-send="true"
 href="http://www.packtpub.com/create-multimedia-website-with-drupal/book"
 target="_blank">http://www.packtpub.com/create-multimedia-website-with-drupal/book</a><br>
    <br>
My blog:<br>
    <a moz-do-not-send="true" href="http://aaronwinborn.com/"
 target="_blank">http://aaronwinborn.com/</a><br>
    <br>
  </blockquote>
  </div>
  <br>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">-- 
Aaron Winborn

Advomatic, LLC
<a class="moz-txt-link-freetext" href="http://advomatic.com/">http://advomatic.com/</a>

Drupal Multimedia available in September!
<a class="moz-txt-link-freetext" href="http://www.packtpub.com/create-multimedia-website-with-drupal/book">http://www.packtpub.com/create-multimedia-website-with-drupal/book</a>

My blog:
<a class="moz-txt-link-freetext" href="http://aaronwinborn.com/">http://aaronwinborn.com/</a></pre>
</body>
</html>