PluginProbe
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder / 2.14.0
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder v2.14.0
2.14.0 2.13.0 2.13.1 2.12.0 2.11.1 2.11.0 2.10.0 2.9.0 2.7.4 2.7.5 2.7.6 2.7.7 2.8.0 2.8.1 2.9.1 trunk 1.0 1.0-beta1 1.0-beta2 1.0-beta3 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 All 81 releases
← All changes | includes/blocks/form-builder/helper.php +8 -2 2.9.1 → 2.14.0 View file →
@@ -1,7 +1,11 @@
1 1 <?php
2 2 namespace ABlocks\Blocks\FormBuilder;
3 3
4 +if ( ! defined( 'ABSPATH' ) ) {
5 + exit;
6 +}
7 +
4 8 use ABlocks\Blocks\FormBuilder\EmailVerification;
5 9 use SplTempFileObject;
6 10 /**
7 11 * @class Query
@@ -12,13 +16,15 @@
12 16 string $attr = '',
13 17 bool $check_alloed_host = false
14 18 ) : string {
15 19 $parsed_url = wp_parse_url( $url );
20 + $curr_host = wp_parse_url( home_url( '/' ), PHP_URL_HOST );
16 21 $parsed_url['query'] = $parsed_url['query'] ?? '';
17 22 $parsed_url['scheme'] = $parsed_url['scheme'] ?? '';
18 - $parsed_url['host'] = $parsed_url['host'] ?? '';
23 + $parsed_url['host'] = $parsed_url['host'] ?? $curr_host;
19 24 $parsed_url['path'] = $parsed_url['path'] ?? '';
20 25
26 + // wp_send_json($parsed_url);
21 27 if (
22 28 $check_alloed_host &&
23 29 ! in_array(
24 30 $parsed_url['host'],
@@ -24,9 +30,9 @@
24 30 $parsed_url['host'],
25 31 array_merge(
26 32 apply_filters( 'allowed_redirect_hosts', [] ),
27 33 [
28 - wp_parse_url( home_url( '/' ), PHP_URL_HOST )
34 + $curr_host
29 35 ]
30 36 ),
31 37 true
32 38 )