Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dev.biuro
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Biuro
dev.biuro
Commits
aad0f896
Commit
aad0f896
authored
Apr 12, 2019
by
Simonas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
in progress
parent
80f2e007
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
285 additions
and
69 deletions
+285
-69
README.md
README.md
+3
-1
docker-compose.yml
docker-compose.yml
+33
-2
class-biuro-contacts-loader.php
...s/biuro-contacts/includes/class-biuro-contacts-loader.php
+25
-0
class-biuro-contacts.php
.../plugins/biuro-contacts/includes/class-biuro-contacts.php
+23
-6
class-biuro-contacts-public.php
...ins/biuro-contacts/public/class-biuro-contacts-public.php
+94
-46
biuro-contacts-public--employees-quick.php
...ublic/partials/biuro-contacts-public--employees-quick.php
+12
-2
biuro-contacts-public--employees.php
...acts/public/partials/biuro-contacts-public--employees.php
+9
-0
biuro-contacts-public--employers-quick.php
...ublic/partials/biuro-contacts-public--employers-quick.php
+9
-0
biuro-contacts-public--employers.php
...acts/public/partials/biuro-contacts-public--employers.php
+9
-0
biuro-contacts-public--position.php
...tacts/public/partials/biuro-contacts-public--position.php
+9
-0
functions.php
wp-content/themes/biuro/functions.php
+59
-12
No files found.
README.md
View file @
aad0f896
...
...
@@ -65,6 +65,8 @@ ERROR: for mysql Cannot start service mysql: error while creating mount source
Restart docker (sometimes PC restart may be required)
<!-- - https://tomssl.com/2018/01/11/sharing-your-c-drive-with-docker-for-windows-when-using-azure-active-directory-azuread-aad/ -->
## Other (Commands)
-
docker-compose up -d
-
docker-compose start
...
...
@@ -103,7 +105,7 @@ Restart docker (sometimes PC restart may be required)
-
docker load --input ourdemo.tar
-
docker build -t biuro/web:0.0.
7
.
-
docker build -t biuro/web:0.0.
8
.
-
docker login --username=biuro --password=9Ndtjd2vKsLvGuFOeFq1KdJs
-
sudo docker login --username=biuro --password=9Ndtjd2vKsLvGuFOeFq1KdJs
-
docker push biuro/web:0.0.7
...
...
docker-compose.yml
View file @
aad0f896
...
...
@@ -136,8 +136,39 @@ services:
-
./wordpress:/var/www/html
-
'
./wp-init.sh:/usr/local/bin/wp-init.sh'
command
:
-
wp-init.sh
# command:
# - wp-init.sh
command
:
>
/bin/sh -c '
sleep 45;
echo "WP CLI init";
wp core update --force;
wp core update-db --network;
wp option update permalink_structure "/%postname%/" --skip-themes --skip-plugins;
wp option update timezone_string "Manual Offsets/UTC+2";
wp option update date_format "Y-m-d";
wp option update time_format "H:i";
wp plugin install permalink-manager --force --activate-network;
wp plugin install pods --activate-network;
wp plugin install polylang --activate-network;
wp plugin install wordpress-seo --activate-network;
wp plugin update --all;
wp plugin activate akismet --network;
wp plugin activate biuro-contacts --network;
wp plugin activate biuro-feedbacks --network;
wp plugin activate biuro-html --network;
wp plugin activate biuro-sections --network;
wp plugin activate biuro-services --network;
wp plugin activate biuro-values --network;
wp plugin activate cookies-warning --network;
wp plugin activate data-controller --network;
wp theme update --all;
wp theme activate biuro;
wp language core update;
wp language theme update --all;
wp language plugin update --all;
echo "WP CLI done. Ready to use.";
'
networks
:
front
:
...
...
wp-content/plugins/biuro-contacts/includes/class-biuro-contacts-loader.php
View file @
aad0f896
...
...
@@ -41,6 +41,15 @@ class Biuro_Contacts_Loader {
*/
protected
$filters
;
/**
* The array of shortcodes registered with WordPress.
*
* @since 1.0.0
* @access protected
* @var array $shortcodes The shortcodes registered with WordPress to fire when the plugin loads.
*/
protected
$shortcodes
;
/**
* Initialize the collections used to maintain the actions and filters.
*
...
...
@@ -50,6 +59,7 @@ class Biuro_Contacts_Loader {
$this
->
actions
=
array
();
$this
->
filters
=
array
();
$this
->
shortcodes
=
array
();
}
...
...
@@ -81,6 +91,18 @@ class Biuro_Contacts_Loader {
$this
->
filters
=
$this
->
add
(
$this
->
filters
,
$hook
,
$component
,
$callback
,
$priority
,
$accepted_args
);
}
/**
* Add a new shortcode to the collection to be registered with WordPress
*
* @since 1.0.0
* @param string $tag The name of the new shortcode.
* @param object $component A reference to the instance of the object on which the shortcode is defined.
* @param string $callback The name of the function that defines the shortcode.
*/
public
function
add_shortcode
(
$tag
,
$component
,
$callback
,
$priority
=
10
,
$accepted_args
=
2
)
{
$this
->
shortcodes
=
$this
->
add
(
$this
->
shortcodes
,
$tag
,
$component
,
$callback
,
$priority
,
$accepted_args
);
}
/**
* A utility function that is used to register the actions and hooks into a single
* collection.
...
...
@@ -124,6 +146,9 @@ class Biuro_Contacts_Loader {
add_action
(
$hook
[
'hook'
],
array
(
$hook
[
'component'
],
$hook
[
'callback'
]
),
$hook
[
'priority'
],
$hook
[
'accepted_args'
]
);
}
foreach
(
$this
->
shortcodes
as
$hook
)
{
add_shortcode
(
$hook
[
'hook'
],
array
(
$hook
[
'component'
],
$hook
[
'callback'
]
),
$hook
[
'priority'
],
$hook
[
'accepted_args'
]
);
}
}
}
wp-content/plugins/biuro-contacts/includes/class-biuro-contacts.php
View file @
aad0f896
...
...
@@ -156,7 +156,6 @@ class Biuro_Contacts {
$this
->
loader
->
add_action
(
'admin_enqueue_scripts'
,
$plugin_admin
,
'enqueue_styles'
);
$this
->
loader
->
add_action
(
'admin_enqueue_scripts'
,
$plugin_admin
,
'enqueue_scripts'
);
}
/**
...
...
@@ -173,12 +172,30 @@ class Biuro_Contacts {
$this
->
loader
->
add_action
(
'wp_enqueue_scripts'
,
$plugin_public
,
'enqueue_styles'
);
$this
->
loader
->
add_action
(
'wp_enqueue_scripts'
,
$plugin_public
,
'enqueue_scripts'
);
$this
->
loader
->
add_action
(
'init'
,
$plugin_public
,
'register_shortcodes'
);
$this
->
loader
->
add_action
(
'admin_post_nopriv_employees_quick'
,
$plugin_public
,
'employeesQuickSubmit'
);
$this
->
loader
->
add_action
(
'admin_post_employees_quick'
,
$plugin_public
,
'employeesQuickSubmit'
);
$this
->
loader
->
add_action
(
'admin_post_nopriv_employers_quick'
,
$plugin_public
,
'employersQuickSubmit'
);
$this
->
loader
->
add_action
(
'admin_post_employers_quick'
,
$plugin_public
,
'employersQuickSubmit'
);
$this
->
loader
->
add_action
(
'admin_post_employees_quick_post'
,
$plugin_public
,
'employees_quick_post'
);
$this
->
loader
->
add_action
(
'admin_post_nopriv_employees_quick_post'
,
$plugin_public
,
'employees_quick_post'
);
$this
->
loader
->
add_action
(
'admin_post_employers_quick_post'
,
$plugin_public
,
'employers_quick_post'
);
$this
->
loader
->
add_action
(
'admin_post_nopriv_employers_quick_post'
,
$plugin_public
,
'employers_quick_post'
);
// $this->loader->add_action( 'init', $plugin_public, 'register_shortcodes' );
/**
* Register shortcode via loader
*
* Use: [short-code-name args]
*
* @link https://github.com/DevinVinson/WordPress-Plugin-Boilerplate/issues/262
*/
$this
->
loader
->
add_shortcode
(
"biuro-contacts--employees-quick"
,
$plugin_public
,
"employees_quick_form"
,
$priority
=
10
,
$accepted_args
=
2
);
$this
->
loader
->
add_shortcode
(
"biuro-contacts--employers-quick"
,
$plugin_public
,
"employers_quick_form"
,
$priority
=
10
,
$accepted_args
=
2
);
// add_shortcode( 'biuro-contacts--employees-quick', array( $this, 'employees_quick_form' ) );
// add_shortcode( 'biuro-contacts--employers-quick', array( $this, 'employers_quick_form' ) );
// add_shortcode( 'biuro-contacts--employees', array( $this, 'employees_form' ) );
// add_shortcode( 'biuro-contacts--employers', array( $this, 'employers_form' ) );
// add_shortcode( 'biuro-contacts--position', array( $this, 'position_form' ) );
}
/**
...
...
wp-content/plugins/biuro-contacts/public/class-biuro-contacts-public.php
View file @
aad0f896
...
...
@@ -108,7 +108,7 @@ class Biuro_Contacts_Public {
*
* @return mixed $output Output of the buffer
*/
public
function
employees_form
(
$att
r
=
array
()
)
{
public
function
employees_form
(
$att
s
)
{
$response
=
false
;
ob_start
();
...
...
@@ -133,7 +133,16 @@ class Biuro_Contacts_Public {
*
* @return mixed $output Output of the buffer
*/
public
function
employees_quick_form
(
$attr
=
array
()
)
{
public
function
employers_quick_form
(
$attr
=
array
()
)
{
// $args = shortcode_atts(
// array(
// 'arg1' => 'arg1',
// 'arg2' => 'arg2',
// ),
// $atts
// );
$response
=
false
;
ob_start
();
...
...
@@ -142,7 +151,7 @@ class Biuro_Contacts_Public {
$response
=
true
;
endif
;
include
'partials/biuro-contacts-public--employe
e
s-quick.php'
;
include
'partials/biuro-contacts-public--employe
r
s-quick.php'
;
$output
=
ob_get_contents
();
...
...
@@ -151,40 +160,40 @@ class Biuro_Contacts_Public {
return
$output
;
}
// employees_form()
/**
* Processes shortcode biuro-contacts--employe
e
s
* Processes shortcode biuro-contacts--employe
r
s
*
* @param array $attr The attributes from the shortcode
*
* @return mixed $output Output of the buffer
*/
public
function
employers_
quick_
form
(
$attr
=
array
()
)
{
public
function
employers_form
(
$attr
=
array
()
)
{
$response
=
false
;
ob_start
();
if
(
isset
(
$_POST
[
'submit'
]
)
)
:
if
(
isset
(
$_POST
[
'
action-
submit'
]
)
)
:
$response
=
true
;
endif
;
include
'partials/biuro-contacts-public--employers
-quick
.php'
;
include
'partials/biuro-contacts-public--employers.php'
;
$output
=
ob_get_contents
();
ob_end_clean
();
return
$output
;
}
// employees_form()
}
// employers_form()
/**
* Processes shortcode biuro-contacts--
employers
* Processes shortcode biuro-contacts--
position
*
* @param array $attr The attributes from the shortcode
*
* @return mixed $output Output of the buffer
*/
public
function
employers
_form
(
$attr
=
array
()
)
{
public
function
position
_form
(
$attr
=
array
()
)
{
$response
=
false
;
ob_start
();
...
...
@@ -193,48 +202,106 @@ class Biuro_Contacts_Public {
$response
=
true
;
endif
;
include
'partials/biuro-contacts-public--
employers
.php'
;
include
'partials/biuro-contacts-public--
position
.php'
;
$output
=
ob_get_contents
();
ob_end_clean
();
return
$output
;
}
// employers_form()
}
// position_form()
/**
* Processes shortcode biuro-contacts--position
* May override the default upload path.
* /wp-content/uploads/{folder}/
*
* @param array $dir
* @return array
*/
function
change_upload_dir
(
$dir
)
{
return
array
(
'path'
=>
$dir
[
'basedir'
]
.
'/{folder}'
,
'url'
=>
$dir
[
'baseurl'
]
.
'/{folder}'
,
'subdir'
=>
'/{folder}'
,
)
+
$dir
;
}
/**
* Processes shortcode biuro-contacts--employees
*
* @param array $attr The attributes from the shortcode
*
* @return mixed $output Output of the buffer
*/
public
function
position_form
(
$attr
=
array
()
)
{
$response
=
false
;
public
function
employees_quick_form
(
$attr
=
array
()
)
{
// $args = shortcode_atts(
// array(
// 'arg1' => 'arg1',
// 'arg2' => 'arg2',
// ),
// $atts
// );
// $response = false;
ob_start
();
if
(
isset
(
$_POST
[
'action-
submit'
]
)
)
:
$response
=
true
;
endif
;
// if ( isset( $_POST['
submit'] ) ) :
//
$response = true;
//
endif;
include
'partials/biuro-contacts-public--
position
.php'
;
include
'partials/biuro-contacts-public--
employees-quick
.php'
;
$output
=
ob_get_contents
();
ob_end_clean
();
return
$output
;
}
//
position
_form()
}
//
employees
_form()
public
function
employees_quick_post
()
{
// debug($_POST); //$_POST variables should be accessible now
$nonce
=
$_POST
[
'_wpnonce'
];
$referer
=
$_POST
[
'_wp_http_referer'
];
public
function
employersQuickSubmit
()
{
debug
(
$_POST
);
//$_POST variables should be accessible now
//Optional: Now you can redirect the user to your confirmation page using wp_redirect()
if
(
!
isset
(
$nonce
)
||
!
wp_verify_nonce
(
$nonce
,
'employees_quick_post_nonce'
)
)
{
// Nonce not match
// Diplay some error
wp_redirect
(
$referer
);
exit
;
}
/*
* May prehandle file upload
*/
// Set an array containing a list of acceptable formats
// $allowed_file_types = array('image/jpg','image/jpeg','image/gif','image/png');
// $allowed_file_types = array('doc','docx','pdf', 'rtf', 'jpg', 'jpeg', 'gif', 'png');
// $allowed_file_types = array('doc','docx','pdf');
$allowed_file_types
=
array
(
'application/pdf'
,
'application/msword'
,
'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
);
// Check file types
foreach
(
$_FILES
as
$file
)
{
// Get the type of the uploaded file. This is returned as "type/extension"
$arr_file_type
=
wp_check_filetype
(
basename
(
$file
[
'name'
]
)
);
$uploaded_file_type
=
$arr_file_type
[
'type'
];
if
(
!
in_array
(
$uploaded_file_type
,
$allowed_file_types
)
)
{
// Diplay some error
wp_redirect
(
$referer
);
exit
;
}
}
// delog($nonce, 'nonce');
// Optional: Now you can redirect the user to your confirmation page using wp_redirect()
// ob_start();
// wp_redirect($_POST['_wp_http_referer']
);
wp_redirect
(
$referer
);
exit
;
// wp_redirect(admin_url('admin.php?page=' . $_POST['_wp_http_referer']));
...
...
@@ -242,8 +309,8 @@ class Biuro_Contacts_Public {
//apparently when finished, die(); is required.
}
public
function
employe
esQuickSubmi
t
()
{
debug
(
$_POST
);
//$_POST variables should be accessible now
public
function
employe
rs_quick_pos
t
()
{
//
debug($_POST); //$_POST variables should be accessible now
//Optional: Now you can redirect the user to your confirmation page using wp_redirect()
// ob_start();
...
...
@@ -254,23 +321,4 @@ class Biuro_Contacts_Public {
// die();
//apparently when finished, die(); is required.
}
/**
* Registers all shortcodes at once
*
* @return [type] [description]
*/
public
function
register_shortcodes
()
{
add_shortcode
(
'biuro-contacts--employees-quick'
,
array
(
$this
,
'employees_quick_form'
)
);
add_shortcode
(
'biuro-contacts--employers-quick'
,
array
(
$this
,
'employers_quick_form'
)
);
add_shortcode
(
'biuro-contacts--employees'
,
array
(
$this
,
'employees_form'
)
);
add_shortcode
(
'biuro-contacts--employers'
,
array
(
$this
,
'employers_form'
)
);
add_shortcode
(
'biuro-contacts--position'
,
array
(
$this
,
'position_form'
)
);
}
// register_shortcodes()
}
wp-content/plugins/biuro-contacts/public/partials/biuro-contacts-public--employees-quick.php
View file @
aad0f896
...
...
@@ -11,6 +11,15 @@
* @package Biuro_Contacts
* @subpackage Biuro_Contacts/public/partials
*/
/**
* @link https://codex.wordpress.org/Creating_Options_Pages
* @link https://www.smashingmagazine.com/2016/04/three-approaches-to-adding-configurable-fields-to-your-plugin/
*/
// If this file is called directly, abort.
if
(
!
defined
(
'WPINC'
)
)
die
;
// Generate a custom nonce value.
$_nonce
=
wp_create_nonce
(
'my_post_form_nonce'
);
?>
<form
action=
"
<?php
echo
esc_url
(
admin_url
(
'admin-post.php'
)
);
?>
"
method=
"post"
enctype=
"multipart/form-data"
class=
"c-form"
>
...
...
@@ -69,6 +78,7 @@
<?php
endif
;
?>
</div>
<!-- .c-form--row -->
<input
type=
"hidden"
name=
"action"
value=
"employees_quick"
>
<?php
wp_nonce_field
(
'employees_quick_nonce'
,
'employees_quick_nonce'
);
?>
<input
type=
"hidden"
name=
"action"
value=
"employees_quick_post"
>
<!-- <input type="hidden" name="_nonce" value="
<?php
echo
$_nonce
;
?>
" /> -->
<?php
wp_nonce_field
(
'employees_quick_post_nonce'
);
?>
</form>
wp-content/plugins/biuro-contacts/public/partials/biuro-contacts-public--employees.php
View file @
aad0f896
...
...
@@ -11,6 +11,15 @@
* @package Biuro_Contacts
* @subpackage Biuro_Contacts/public/partials
*/
/**
* @link https://codex.wordpress.org/Creating_Options_Pages
* @link https://www.smashingmagazine.com/2016/04/three-approaches-to-adding-configurable-fields-to-your-plugin/
*/
// If this file is called directly, abort.
if
(
!
defined
(
'WPINC'
)
)
die
;
// Generate a custom nonce value.
$_nonce
=
wp_create_nonce
(
'my_post_form_nonce'
);
?>
<form
id=
"ContactFormEmployee_ContactFormEmployee"
action=
"
<?php
echo
$_SERVER
[
"REQUEST_URI"
];
?>
"
method=
"post"
enctype=
"multipart/form-data"
class=
"contact-form"
>
...
...
wp-content/plugins/biuro-contacts/public/partials/biuro-contacts-public--employers-quick.php
View file @
aad0f896
...
...
@@ -11,6 +11,15 @@
* @package Biuro_Contacts
* @subpackage Biuro_Contacts/public/partials
*/
/**
* @link https://codex.wordpress.org/Creating_Options_Pages
* @link https://www.smashingmagazine.com/2016/04/three-approaches-to-adding-configurable-fields-to-your-plugin/
*/
// If this file is called directly, abort.
if
(
!
defined
(
'WPINC'
)
)
die
;
// Generate a custom nonce value.
$_nonce
=
wp_create_nonce
(
'my_post_form_nonce'
);
?>
<form
action=
"
<?php
echo
esc_url
(
admin_url
(
'admin-post.php'
)
);
?>
"
method=
"post"
enctype=
"multipart/form-data"
class=
"c-form"
>
...
...
wp-content/plugins/biuro-contacts/public/partials/biuro-contacts-public--employers.php
View file @
aad0f896
...
...
@@ -11,6 +11,15 @@
* @package Biuro_Contacts
* @subpackage Biuro_Contacts/public/partials
*/
/**
* @link https://codex.wordpress.org/Creating_Options_Pages
* @link https://www.smashingmagazine.com/2016/04/three-approaches-to-adding-configurable-fields-to-your-plugin/
*/
// If this file is called directly, abort.
if
(
!
defined
(
'WPINC'
)
)
die
;
// Generate a custom nonce value.
$_nonce
=
wp_create_nonce
(
'my_post_form_nonce'
);
?>
<form
id=
"ContactForm_ContactForm"
action=
"
<?php
echo
$_SERVER
[
"REQUEST_URI"
];
?>
"
method=
"post"
enctype=
"application/x-www-form-urlencoded"
class=
"contact-form"
>
...
...
wp-content/plugins/biuro-contacts/public/partials/biuro-contacts-public--position.php
View file @
aad0f896
...
...
@@ -11,6 +11,15 @@
* @package Biuro_Contacts
* @subpackage Biuro_Contacts/public/partials
*/
/**
* @link https://codex.wordpress.org/Creating_Options_Pages
* @link https://www.smashingmagazine.com/2016/04/three-approaches-to-adding-configurable-fields-to-your-plugin/
*/
// If this file is called directly, abort.
if
(
!
defined
(
'WPINC'
)
)
die
;
// Generate a custom nonce value.
$_nonce
=
wp_create_nonce
(
'my_post_form_nonce'
);
?>
<form
id=
"CVForm_CVForm"
action=
"
<?php
echo
$_SERVER
[
"REQUEST_URI"
];
?>
"
method=
"post"
enctype=
"multipart/form-data"
class=
"contact-form"
>
...
...
wp-content/themes/biuro/functions.php
View file @
aad0f896
<?php
function
debug
(
$arr
)
{
echo
'<pre>'
;
print_r
(
$arr
);
echo
'</pre>'
;
}
function
delog
(
$str
,
$label
=
'Label'
)
{
echo
'<h1 style="white-space: nowrap;">'
.
$label
.
': '
.
$str
.
'</h1>'
;
}
function
cc_mime_types
(
$mimes
)
{
$mimes
[
'svg'
]
=
'image/svg+xml'
;
return
$mimes
;
...
...
@@ -412,6 +400,48 @@ add_action('init', 'df_disable_comments_admin_bar');
// require_once 'includes/disable_discussion';
function
getContacts
(
$request
)
{
$res
=
array
();
array_push
(
$res
,
array
(
'id'
=>
1
,
'date'
=>
'2019-03-15 19:05:44'
,
'name'
=>
'Vardenis'
,
'surname'
=>
'Pavardenis'
,
'phone'
=>
'+37060000000'
,
'email'
=>
'email@example.com'
,
'city'
=>
''
,
'comment'
=>
''
,
'cv'
=>
''
)
);
array_push
(
$res
,
array
(
'id'
=>
2
,
'date'
=>
'2019-04-01 08:08:17'
,
'name'
=>
'Jonas'
,
'surname'
=>
'Jonaitis Kazlauskaitis'
,
'phone'
=>
''
,
'email'
=>
'jonas@example.com'
,
'city'
=>
'Vilnius'
,
'comment'
=>
'Lorem ipsum dolor sit amet, consectetur adipisicing elit. Est ducimus iusto modi a, iure. Provident.'
,
'cv'
=>
'/path/to/000000000000000.pdf'
)
);
array_push
(
$res
,
array
(
'id'
=>
3
,
'date'
=>
'2019-04-10 07:43:02'
,
'name'
=>
'Eglė'
,
'surname'
=>
'Pavardenytė'
,
'phone'
=>
''
,
'email'
=>
'egle@example.com'
,
'city'
=>
'Kaunas'
,
'comment'
=>
''
,
'cv'
=>
''
)
);
return
new
WP_REST_Response
(
$res
,
200
);
}
function
getDivisions
(
$request
)
{
$res
=
array
();
$params
=
$request
->
get_params
();
...
...
@@ -466,4 +496,21 @@ add_action( 'rest_api_init', function () {
)
));
register_rest_route
(
'api/v1'
,
'/contacts'
,
array
(
'methods'
=>
WP_REST_Server
::
READABLE
,
'callback'
=>
'getContacts'
));
});
function
debug
(
$arr
)
{
echo
'<pre>'
;
print_r
(
$arr
);
echo
'</pre>'
;
}
function
delog
(
$str
,
$label
=
'Label'
)
{
echo
'<h1 style="white-space: nowrap;">'
.
$label
.
': '
.
$str
.
'</h1>'
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment