Skip to content

Commit

Permalink
Merge pull request #218 from BoldGrid/pro-issue-144
Browse files Browse the repository at this point in the history
fixes pro #144
  • Loading branch information
avonville authored Mar 7, 2024
2 parents 398d595 + f1b6ecf commit ea86fc5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion includes/class-notification.php
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ public function get_merge_value( $tag ) {
break;

case 'url_referer':
return isset( $_SERVER['HTTP_REFERER'] ) ? sanitize_text_field( wp_unslash( $_SERVER['HTTP_REFERER'] ) ) : '';
return isset( $_SERVER['HTTP_REFERER'] ) ? sanitize_url( wp_unslash( $_SERVER['HTTP_REFERER'] ) ) : '';
break;

case 'url_login':
Expand Down
2 changes: 1 addition & 1 deletion includes/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ function weforms_insert_entry( $args, $fields = [] ) {
'user_id' => get_current_user_id(),
'user_ip' => ip2long( weforms_get_client_ip() ),
'user_device' => $browser['name'] . '/' . $browser['platform'],
'referer' => isset( $_SERVER['HTTP_REFERER'] ) ? sanitize_text_field( wp_unslash( $_SERVER['HTTP_REFERER'] ) ) : '',
'referer' => isset( $_SERVER['HTTP_REFERER'] ) ? sanitize_url( wp_unslash( $_SERVER['HTTP_REFERER'] ) ) : '',
'created_at' => current_time( 'mysql' )
];

Expand Down

0 comments on commit ea86fc5

Please sign in to comment.