diff --git a/.DS_Store b/.DS_Store index b751a41e..afc5aca4 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/admin/.DS_Store b/admin/.DS_Store index 23d82676..6378195d 100644 Binary files a/admin/.DS_Store and b/admin/.DS_Store differ diff --git a/admin/pages/class-wp-sweepbright-contact.php b/admin/pages/class-wp-sweepbright-contact.php index f17bc370..317202f5 100644 --- a/admin/pages/class-wp-sweepbright-contact.php +++ b/admin/pages/class-wp-sweepbright-contact.php @@ -113,6 +113,7 @@ public function emit_event($event) public function parse_template($template, $form) { $output = str_replace('[title]', $form['title'], $template); + $output = str_replace('[address]', $form['address'], $template); $output = str_replace('[url]', $form['url'], $output); $output = str_replace('[first_name]', $form['first_name'], $output); $output = str_replace('[last_name]', $form['last_name'], $output); @@ -149,6 +150,7 @@ public function submit_estate_form() $form = [ 'title' => get_the_title(), 'url' => 'View property', + 'address' => get_field('location')['formatted_agency'], 'first_name' => $this->validate_input($_POST['first_name']), 'last_name' => $this->validate_input($_POST['last_name']), 'email' => $this->validate_input($_POST['email']), diff --git a/admin/partials/contact.php b/admin/partials/contact.php index 2f0dd254..3097e854 100644 --- a/admin/partials/contact.php +++ b/admin/partials/contact.php @@ -71,7 +71,7 @@
- Available tags: [title], [url], [first_name], [last_name], [email], [phone], [message].
+ Available tags: [title], [address], [url], [first_name], [last_name], [email], [phone], [message].
[title], [url] are only available for estate contact requests.
- Available tags: [title], [url], [first_name], [last_name], [email], [phone], [message].
+ Available tags: [title], [address], [url], [first_name], [last_name], [email], [phone], [message].
[title], [url] are only available for estate contact requests.