• Bug Report: Frontend Admin Free – Zero Values in Numeric Fields Not Saving Summary

    Frontend Admin Free is incorrectly handling numeric fields with zero values (0) during form submission. The value 0 is completely lost during the save process, while all other numeric values work correctly.

    Environment

    • Plugin Frontend Admin Free Version: 3.28.18
    • ACF Free Version: 6.5.1
    • WordPress Version: 6.8.2
    • PHP Version: 8.0.30

    Bug Description

    When submitting a form created with Frontend Admin Free containing ACF numeric fields with the value 0, the zero value is not saved to the database. The field appears empty after form submission, even though:

    1. The value 0 is correctly present in the HTTP POST payload
    2. The same ACF fields work perfectly when edited directly in the WordPress backend
    3. All other numeric values (1, 2, -1, 0.5, etc.) save correctly through Frontend Admin Free

    Steps to Reproduce

    1. Create an ACF numeric field
    2. Create a Frontend Admin Free form including this numeric field
    3. Pre-populate the field with value 0 (or any non-zero value)
    4. Load the form on frontend
    5. Change the field value to 0
    6. Submit the form
    7. Reload the page – the field will be empty
    8. Check the ACF backend – the field value is empty (not 0)

    Test Results

    • Direct ACF backend editing: Zero values save correctly ✅
    • Frontend Admin Free with zero values: Zero values are lost ❌
    • Frontend Admin Free with non-zero values: All other values save correctly ✅
    • HTTP POST payload inspection: Zero values are present in the request ✅

    Root Cause Analysis

    The bug appears to be in Frontend Admin Free’s internal value processing logic, where zero values are likely being treated as “empty” or “falsy” values and subsequently ignored during the save process.

    Impact

    This bug makes it impossible to save legitimate zero values in numeric fields, which is critical for many use cases (quantities, scores, measurements, etc.).

    Question

    Do you have a patch or hotfix available for this issue? This appears to be a critical bug that affects the core functionality of numeric fields in frontend forms.

    Additional Information

    We have attempted multiple workarounds including:

    • Custom ACF save_post hooks
    • JavaScript form manipulation
    • PHP POST data interception

    None of these approaches resolved the issue, confirming that the bug is within Frontend Admin Free’s core processing logic.

    We would appreciate any guidance or patch you can provide for this issue.

    Thank you for your assistance.

The topic ‘Zero Values in Numeric Fields Not Saving’ is closed to new replies.