# Property Inquiry Form Field Reorder **Date:** 2026-01-12 **Purpose:** Reorder Contact Form 7 "Property Inquiry Form" fields so Additional Comments appears after Name/Email/Phone **Status:** Applied to dev on 2026-01-12 ## Background The property inquiry form should have this field order: 1. Your Inquiry (readonly display message) 2. Your Name 3. Email / Phone (side by side) 4. Additional Comments 5. Submit button Previously, Additional Comments was above the contact fields. ## Changes Required ### Via WP Admin (Recommended) 1. Go to WP Admin > Contact > Forms 2. Edit "Property Inquiry Form" 3. Reorder the form fields as shown below 4. Save the form ### New Form Structure ```
[hidden listing-key] [hidden listing-id] [hidden property-address] [hidden property-price] [hidden property-url] [hidden default-message] [hidden agent-email] [hidden agent-name]
[text* your-name]
[email* your-email]
[tel* your-phone]
[textarea comments placeholder "Any specific questions or information you'd like to know..."]
[submit class:btn class:btn-primary class:btn-lg "Send Inquiry"] ``` ### Via SQL (Alternative) **Important:** CF7 stores the form structure in `wp_postmeta._form`, not `wp_posts.post_content`. First, find the form ID: ```sql SELECT ID, post_title FROM wp_posts WHERE post_type = 'wpcf7_contact_form' AND post_title = 'Property Inquiry Form'; -- Result: ID = 156 (in dev) ``` Then update the `_form` meta with the new form structure: ```sql UPDATE wp_postmeta SET meta_value = '
[hidden listing-key] [hidden listing-id] [hidden property-address] [hidden property-price] [hidden property-url] [hidden default-message] [hidden agent-email] [hidden agent-name]
[text* your-name]
[email* your-email]
[tel* your-phone]
[textarea comments placeholder "Any specific questions or information you would like to know..."]
[submit class:btn class:btn-primary class:btn-lg "Send Inquiry"]' WHERE post_id = (SELECT ID FROM wp_posts WHERE post_type = 'wpcf7_contact_form' AND post_title = 'Property Inquiry Form') AND meta_key = '_form'; ``` ## Related Code Changes The following theme files were also updated to support this change: - `page-property-inquiry.php` - Updated fallback form field order, added agent lookup, split display vs submission messages - `inc/wpcf7-hooks.php` - Updated HomeProz listing detection to use office name - `template-parts/property/property-agent.php` - Updated to use listing key for inquiry URL ## Why - Better UX: Users should enter their contact info before typing additional comments - The display message shown to users no longer includes MLS# (cleaner) - The submitted message includes MLS#, property URL, and user comments for agent reference