<p>Jeff: Have you tried putting the url in the array through the url() function? That sounds like something to try. Possibly with the &#39;absolute&#39; option set to True.</p>
<div class="gmail_quote">On Dec 30, 2010 5:41 PM,  &lt;<a href="mailto:jeff@ayendesigns.com">jeff@ayendesigns.com</a>&gt; wrote:<br type="attribution">&gt; Almost there. I have the ahah appearing now by using #after_build. I <br>
&gt; guess from what I read that this had something to do with CCK fields <br>&gt; (such as content profile fields) not cooperating with hook_form_alter <br>&gt; due to timing.<br>&gt; <br>&gt; My (hopefully) last hurdle is probably just a need for another pair of <br>
&gt; eyes. When the change event fires and the throbber spins, I get a 404 <br>&gt; error on the callback.<br>&gt; <br>&gt; function test_menu() {<br>&gt;      $items = array();<br>&gt;      $items[&#39;test/change_value/callback&#39;] = array(<br>
&gt;          &#39;page callback&#39; =&gt; &#39;test_change_callback&#39;,<br>&gt;          &#39;access callback&#39; =&gt; TRUE,<br>&gt;          &#39;type&#39; =&gt; MENU_CALLBACK,<br>&gt;      );<br>&gt; <br>&gt;      return $items;<br>
&gt; }<br>&gt; <br>&gt; function test_form_alter(&amp;$form, &amp;$form_state, $form_id) {<br>&gt;      if ($form_id == &#39;test_profile_node_form&#39;) {<br>&gt;          $form[&#39;field_result&#39;][&#39;#prefix&#39;] = &#39;&lt;div <br>
&gt; id=&quot;field-result-wrapper&quot;&gt;&#39;;<br>&gt;          $form[&#39;field_result&#39;][&#39;#suffix&#39;] = &#39;&lt;/div&gt;&#39;;<br>&gt; <br>&gt;        $form[&#39;#after_build&#39;][] = &#39;test_add_ahah&#39;;<br>
&gt;      }<br>&gt; }<br>&gt; <br>&gt; function test_add_ahah($form, $form_state) {<br>&gt; <br>&gt;     $ahah = array();<br>&gt; <br>&gt;       $ahah[&#39;edit-field-test-value&#39;] = array(<br>&gt;         &#39;button&#39; =&gt; false,<br>
&gt;         &#39;effect&#39; =&gt; &#39;none&#39;,<br>&gt;         &#39;event&#39; =&gt; &#39;change&#39;,<br>&gt;         &#39;keypress&#39; =&gt; NULL,<br>&gt;         &#39;method&#39; =&gt; &#39;replace&#39;,<br>&gt;         &#39;progress&#39; =&gt; array(&#39;type&#39; =&gt; &#39;throbber&#39;),<br>
&gt;         &#39;selector&#39; =&gt; &#39;#edit-field-test-value&#39;,<br>&gt;         &#39;url&#39; =&gt; &#39;test/change_value/callback&#39;,<br>&gt;         &#39;wrapper&#39; =&gt; &#39;field-result-wrapper&#39;,<br>
&gt;       );<br>&gt;     drupal_add_js(array(&#39;ahah&#39; =&gt; $ahah), &#39;setting&#39;);<br>&gt; <br>&gt; <br>&gt;     return $form;<br>&gt; }<br>&gt; <br>&gt; function test_callback_helper() {<br>&gt;    $form_state = array(&#39;storage&#39; =&gt; NULL, &#39;submitted&#39; =&gt; FALSE);<br>
&gt;    $form_build_id = $_POST[&#39;form_build_id&#39;];<br>&gt;    $form = form_get_cache($form_build_id, $form_state);<br>&gt;    $args = $form[&#39;#parameters&#39;];<br>&gt;    $form_id = array_shift($args);<br>&gt;    $form_state[&#39;post&#39;] = $form[&#39;#post&#39;] = $_POST;<br>
&gt;    $form_state[&#39;ahah_submission&#39;] = TRUE;<br>&gt;    $form[&#39;#programmed&#39;] = $form[&#39;#redirect&#39;] = FALSE;<br>&gt;    drupal_process_form($form_id, $form, $form_state);<br>&gt;    $form = drupal_rebuild_form($form_id, $form_state, $args, <br>
&gt; $form_build_id);<br>&gt;    return $form;<br>&gt; }<br>&gt; <br>&gt; function test_change_callback() {<br>&gt; <br>&gt;      $form = test_callback_helper();<br>&gt;      $output= test_do_stuff();<br>&gt;      drupal_json(array(&#39;status&#39; =&gt; TRUE, &#39;data&#39; =&gt; $output));<br>
&gt;      exit();<br>&gt; }<br>&gt; <br></div>