Appnitro Software Forums » MachForm

I (still) have a problem with removing empty fields...

(9 posts)

  1. MvdL79
    Member

    I already asked this before and I received an answer, but it didn't solve the problem.

    I quote:

    To remove empty fields from your review page, edit includes/view-functions.php file,
    search around line 2330 and you'll find this code:
    
    foreach ($entry_details as $data){
    
    Right under that line, insert this code:
    
    if($data['value'] == ' '){
    	continue;
    }
    that would remove empty fields.

    It works fine with empty fields, however it does not work properly with radio buttons and pulldown fields. It will show the radio buttons and pulldown fields on both the review page as on the emailed form.

    Is there a way to hide the radio buttons and pulldown fields from the review page and from the email? E.g. adding a default value like "Please choose" for the pulldown fields and a "Do nothing" radio button. And make them invisible (through PHP or CSS) whenever a customer does not change them?

    Hopefully you can understand...

    Posted 3 years ago #
  2. MvdL79
    Member

    Any ideas Yuniar? :(

    Posted 3 years ago #
  3. oh,, I missed this one!

    Hmm..the code above should remove empty fields for pulldown and radio buttons too.
    I've tested the code locally and it works fine here.

    Can I test your form?
    Paste me the URL here or send to email: customer.service [at] appnitro.com

    Posted 3 years ago #
  4. oh,, I missed this one!

    Hmm..the code above should remove empty fields for pulldown and radio buttons too.
    I've tested the code locally and it works fine here.

    Can I test your form?
    Paste me the URL here or send to email: customer.service [at] appnitro.com

    Posted 3 years ago #
  5. MvdL79
    Member

    God, I am stupid...

    The reason why it showed up everytime, was very simple... :S
    I checked "Default" in the form setup. :(

    How lame. :( :( :(

    One more question though; regarding the code in the first post. You said it showed up around line 2330. However in your latest version of MachForm, it shows up 2 times. I added the extra code on both occassions. Is that good?

    Posted 3 years ago #
  6. Actually, that's a good call!

    The other code is being used to display form review in the advanced form code.

    Posted 3 years ago #
  7. MvdL79
    Member

    Hi Yuniar,
    I have send you an email, regarding the checkboxes situation.

    Posted 3 years ago #
  8. MvdL79
    Member

    :(

    Posted 3 years ago #
  9. sorry for delay!
    I'm (still) on vacation until the end of this week :)

    I've replied to your email.

    Posted 3 years ago #

RSS feed for this topic

Reply

You must log in to post.