fabrik form module submission problems

Discussion in 'Standard Support' started by keroman, Mar 23, 2012.

  1. keroman Member

    Level: Community
    I want to put a form in a fabrik form module on a page where there is a table.

    I however can't validate that form nor be redirected to an other page using te redirection plugin.

    I set "use ajax" option on both position. When this option is on "yes" there is a box with a spinner which is indefinitly displayed, and set on "no" the form is reloaded. In both case none of the submitted data are recorded into the database and I am not redirected to the page indicated in the redirect plugin of that form.

    What should I do to make it work ?
  2. cheesegrits Support Gopher

    Level: Community
    Can you point me at the page?

    -- hugh
  3. keroman Member

    Level: Community
  4. keroman Member

    Level: Community
    Let me explain a little bit what I did.

    I want a newly registred to be obliged to select the currency associated to his account. I therefore have that form (and the transparent grey background) which are displayed when the result of a query on a customer_currency table return is empty.

    After the customer subimitted the form I make a redirection on the same page, but as the result of this form is supposed to be recorded in the customer_currency table the result of the query is not empty and as a consequence that form (and the transparent grey background) does not appear anymore.

    A kind of "modal box" without modal box in fact...
  5. keroman Member

    Level: Community
    The form in question is the #300. It is placed in a <div> called "popup_content". The backrgound is the <div> called "popup".

    These 2 divs are in the head of my template with the following script


    $user =& JFactory::getUser();
    $id = $user->get('id');
    $db =& JFactory::getDBO();
    $db->setQuery("SELECT `devise` FROM `jom15_fab_user_devise` WHERE `id_user` = $id");
    $devise = $db->loadResult();
    if (empty($devise)) { ?>
    <div id="popup" >
    <div id="popup_content" ><jdoc:include type="modules" name="full_screen" style="xhtml" />
    } ?>
    The underlying table of form #300 is `jom15_fab_user_devise`.
  6. cheesegrits Support Gopher

    Level: Community
    As far as I can tell, the problem was that your id_user element on form 300 was a field, with an incorrect eval'ed default that was trying to set the user ID. So the form was submitting, but it wasn't setting the id_user element with the user ID. So on the next page load, your test to see if there is a row with the matching id_user doesn't find anything, so your form pops up again.

    I set id_user to be a normal 'user' element, and the logic now seems to work. I set my currency, it recorded a new row with my user ID and currency, and on the next page load, the form does not show.

    -- hugh
  7. keroman Member

    Level: Community
    Great. thanks !
  8. keroman Member

    Level: Community

    I have problems with 2 other forms which are displayed using the method described in that thread:

    - forms displayed depending on the result return by a query on a table.

    - a redirection on the same page after the form submission.

    After the validation of these forms, the submited data are recorded but:

    - I have a message of validation with a spinner which is displayed indefinitly.
    - the page isn't reloaded.

    You can see the problem on the forms displayed on the middle of the pages reached after login from http://marinewanted.com/joomla1.5/ with the following details:

    Tino@domain3.com/domain1 - form 456
    Toni/domain1 - form 460

    You will probably see the problem on one of these 2 page only, as I can't block the access to the whole site. These 2 forms are however very similar and the problem will most certainly be exactly the same on both forms.
  9. rob Administrator

    Level: Community
    hmm i could only test once - can you PM me an admin login so I can remove the record i added to test again please?

  10. keroman Member

    Level: Community
    Rob, I just sent a PM to you.
  11. keroman Member

    Level: Community
    Friendly bump.
  12. keroman Member

    Level: Community
    Friendly bump.

    This problem will have to be solved ...
  13. rob Administrator

    Level: Community
  14. keroman Member

    Level: Community
    You didn't miss anything. I just working on that part of the site and I therefore desactivate this form.

    Try with Toni/domain1.

    If you want to test the form again you need to:

    - Access the backend of the site with the details I sent to yu by PM.
    - Delete in table #293 the row where id_user=188.
    - Reload the page where the form is displayed.
  15. keroman Member

    Level: Community
    I don't know if you did something, but it seems to work when I set "use ajax" to "no" in the mod_fabrik_form settings.

Share This Page