Commit 2f60c81d authored by Simon's avatar Simon

GTM fix

parent 41761b09
...@@ -5,3 +5,4 @@ wordpress/ ...@@ -5,3 +5,4 @@ wordpress/
node_modules/ node_modules/
logs/nginx/*.log logs/nginx/*.log
yarn.lock yarn.lock
wp-content/uploads/additional/
...@@ -20,9 +20,9 @@ ...@@ -20,9 +20,9 @@
## Production ## Production
- build CSS & JS assets - `C:\web\dev.biuro\ npm run build` - build CSS & JS assets - `C:\web\dev.biuro\ npm run build`
- build new image `docker build -t biuro/web:1.4.4 .` (update version number) - build new image `docker build -t biuro/web:1.4.5 .` (update version number)
- login to biuro docker account `docker login --username=biuro --password=9Ndtjd2vKsLvGuFOeFq1KdJs` - login to biuro docker account `docker login --username=biuro --password=9Ndtjd2vKsLvGuFOeFq1KdJs`
- push image to docker repository - `docker push biuro/web:1.4.4` - push image to docker repository - `docker push biuro/web:1.4.5`
## Production ## Production
- update biuro/web image version in .env file (staging or www) - update biuro/web image version in .env file (staging or www)
......
{ {
"name": "biuro", "name": "biuro",
"version": "1.4.4", "version": "1.4.5",
"description": "Biuro WP theme", "description": "Biuro WP theme",
"scripts": { "scripts": {
"dev": "gulp --require @babel/register --gulpfile tasks", "dev": "gulp --require @babel/register --gulpfile tasks",
......
...@@ -360,7 +360,7 @@ class Biuro_Contacts_Public { ...@@ -360,7 +360,7 @@ class Biuro_Contacts_Public {
// Get the type of the uploaded file. This is returned as "type/extension" // Get the type of the uploaded file. This is returned as "type/extension"
$arr_file_type = wp_check_filetype( basename( $file['name'] ) ); $arr_file_type = wp_check_filetype( basename( $file['name'] ) );
$uploaded_file_type = $arr_file_type['type']; $uploaded_file_type = $arr_file_type['type'];
if( ! in_array( $uploaded_file_type, $allowed_file_types ) ) { if( $file['name'] && !in_array( $uploaded_file_type, $allowed_file_types ) ) {
wp_redirect( $referer ); wp_redirect( $referer );
exit; exit;
} }
...@@ -394,7 +394,7 @@ class Biuro_Contacts_Public { ...@@ -394,7 +394,7 @@ class Biuro_Contacts_Public {
$_SESSION['employees--s'] = 2; $_SESSION['employees--s'] = 2;
endif; endif;
$hash = ($_SESSION['employees--name-status'] != 'error' && $_SESSION['employees--phone-status'] != 'error' && $_SESSION['employees--agree-status'] == 'error') ? '?#agree' : '?#action'; $hash = ($_SESSION['employees--name-status'] != 'error' && $_SESSION['employees--phone-status'] != 'error' && $_SESSION['employees--agree-status'] == 'error') ? '#agree' : '#action';
if ($_POST['s'] == "1"): if ($_POST['s'] == "1"):
wp_redirect( $referer . $hash ); wp_redirect( $referer . $hash );
...@@ -516,7 +516,7 @@ class Biuro_Contacts_Public { ...@@ -516,7 +516,7 @@ class Biuro_Contacts_Public {
endif; endif;
$hash = ($_SESSION['employers--name-status'] != 'error' && $_SESSION['employers--phone-status'] != 'error' && $_SESSION['employers--agree-status'] == 'error') ? '?#agree' : '?#action'; $hash = ($_SESSION['employers--name-status'] != 'error' && $_SESSION['employers--phone-status'] != 'error' && $_SESSION['employers--agree-status'] == 'error') ? '#agree' : '#action';
if ($_POST['s'] == "1"): if ($_POST['s'] == "1"):
wp_redirect( $referer . $hash ); wp_redirect( $referer . $hash );
...@@ -699,7 +699,7 @@ class Biuro_Contacts_Public { ...@@ -699,7 +699,7 @@ class Biuro_Contacts_Public {
$_SESSION['position--step'] = 2; $_SESSION['position--step'] = 2;
$_SESSION['position--s'] = 1; $_SESSION['position--s'] = 1;
$hash = '?#agree'; $hash = '#agree';
elseif ($_POST['s'] == "2"): elseif ($_POST['s'] == "2"):
...@@ -731,7 +731,7 @@ class Biuro_Contacts_Public { ...@@ -731,7 +731,7 @@ class Biuro_Contacts_Public {
$_SESSION[$str . '--' . $key . '-message'] = $validation['message']; $_SESSION[$str . '--' . $key . '-message'] = $validation['message'];
} }
$hash = ($_SESSION['position--name-status'] != 'error' && $_SESSION['position--phone-status'] != 'error' && $_SESSION['position--agree-status'] == 'error') ? '?#agree' : '?#action'; $hash = ($_SESSION['position--name-status'] != 'error' && $_SESSION['position--phone-status'] != 'error' && $_SESSION['position--agree-status'] == 'error') ? '#agree' : '#action';
if ($canSubmit): if ($canSubmit):
...@@ -743,7 +743,7 @@ class Biuro_Contacts_Public { ...@@ -743,7 +743,7 @@ class Biuro_Contacts_Public {
// Get the type of the uploaded file. This is returned as "type/extension" // Get the type of the uploaded file. This is returned as "type/extension"
$arr_file_type = wp_check_filetype( basename( $file['name'] ) ); $arr_file_type = wp_check_filetype( basename( $file['name'] ) );
$uploaded_file_type = $arr_file_type['type']; $uploaded_file_type = $arr_file_type['type'];
if( ! in_array( $uploaded_file_type, $allowed_file_types ) ) { if( $file['name'] && !in_array( $uploaded_file_type, $allowed_file_types ) ) {
wp_redirect( $referer ); wp_redirect( $referer );
exit; exit;
} }
......
...@@ -29,7 +29,7 @@ if ( ! defined( 'WPINC' ) ) die; ...@@ -29,7 +29,7 @@ if ( ! defined( 'WPINC' ) ) die;
<div class="c-form--row"> <div class="c-form--row">
<label class="c-form--label" for="form-message"><?php _e('Message', 'biuro-contacts'); ?></label> <label class="c-form--label" for="form-message"><?php _e('Message', 'biuro-contacts'); ?></label>
<div class="c-form--textarea-wrap"> <div class="c-form--textarea-wrap">
<textarea name="message" id="form-message" cols="30" rows="3" class="c-form--textarea"></textarea> <textarea name="message" id="form-message" cols="30" rows="10" class="c-form--textarea"></textarea>
</div> </div>
</div><!-- .c-form--row --> </div><!-- .c-form--row -->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment