[development] Need some Drupal FAPI/AJAX advice
Randy Fay
randy at randyfay.com
Fri Oct 30 19:30:51 UTC 2009
AHAH/AJAX does do fine with a complete form. You can process a part of a
form, the whole form, or even do HTML replacement on something outside the
form. I'm still not sure it's what you want, of course.
The Examples module (http://drupal.org/project/examples) now has both D6 and
D7 versions of the AHAH example.
There is a D6 AHAH tutorial at http://randyfay.com/ahah.
-Randy
On Fri, Oct 30, 2009 at 8:39 AM, Josh Miller <JoshM at haanmc.com> wrote:
> I'm trying to figure out how best to make the following happen, any
> pointers/documentation/example modules would be awesome:
>
>
>
> 1) Click a button on the webpage
>
> 2) Jquery fires off a request for a unique form that is not a node or menu
> or anything else
>
> 3) Somehow drupal understands the url that I use and fires the appropriate
> function
>
> 4) mymodule_send_form() will invoke drupal_get_form() (maybe?)
>
> 5) Jquery recieves the rendered form, adds stuff to it via hidden inputs
> like x & y, $_Get['q'], $user->id, etc.
>
> 6) user can fill it out
>
> 7) Jquery sends data back to be saved/verified
>
> 8) Jquery recieves a final themed output of content
>
> 9) Repeat as many times as user wants on the same page by clicking the
> button mentioned in #1
>
> What has me very confused is that I need to send and receive themed
> output, but without the entire site. Simply need chunks of final output to
> be sent back and forth. After a discussion on #drupal the other night I
> determined that AHAH is not exactly designed to do entire forms.
>
> If anyone is interested (I know from a tweet discussion that bangpound is)
> I've got a working javascript framework for adding comments to entire pages.
> I'm going to call this module "critique" and it's main use will be turning
> it on and having clients add comments to pages (like you would for PDFs or
> Word Documents). The problem is I can't decide how to architect the backend
> as it will have to be very AJAX-y.
>
> I think I know more about Drupal 7 (having spent the most time in D7
> issue que), but I'd like a working version in Drupal 6 first.
>
>
> Josh
>
>
>
>
>
> _____________________________________
>
> *Josh Miller*
>
> Web / Technology Director
>
>
>
> Haan Marketing + Communications
>
> http://www.haanmc.com/
>
> 123 N. 8th Street, Lafayette, IN 47902-0350
>
>
>
> T. 765.423.5470
>
> F. 765-742-2881
>
>
>
--
Randy Fay
Drupal Development, troubleshooting, and debugging
randy at randyfay.com
+1 970.462.7450
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20091030/2bc271b3/attachment.html
More information about the development
mailing list