This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
register_sidebar( array( | |
'name' => esc_html__( 'My Sidebar', 'text-domain' ), | |
'id' => 'my-sidebar', | |
'description' => esc_html__( 'Add sidebar widgets here.', 'text-domain' ), | |
'before_widget' => '<section id="%1$s" class="widget %2$s">', | |
'after_widget' => '</section>', | |
'before_title' => '<h2 class="widget-title">', | |
'after_title' => '</h2>', | |
) ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Enable Compression | |
<IfModule mod_deflate.c> | |
AddOutputFilterByType DEFLATE application/javascript | |
AddOutputFilterByType DEFLATE application/rss+xml | |
AddOutputFilterByType DEFLATE application/vnd.ms-fontobject | |
AddOutputFilterByType DEFLATE application/x-font | |
AddOutputFilterByType DEFLATE application/x-font-opentype | |
AddOutputFilterByType DEFLATE application/x-font-otf | |
AddOutputFilterByType DEFLATE application/x-font-truetype | |
AddOutputFilterByType DEFLATE application/x-font-ttf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'wp_footer', 'bsd_cf7_redirect_wp_footer' ); | |
function bsd_cf7_redirect_wp_footer() { | |
?> | |
<script type="text/javascript"> | |
document.addEventListener( 'wpcf7mailsent', function( event ) { | |
// here 4423 is the id of the form, replace it with your form id | |
if ( '4423' == event.detail.contactFormId ) { | |
location = 'https://secova.com/thank-you-demo'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Crate method | |
* Change Product to your desired model name, dont' forget to import the Model and Str classname. | |
* Change whereSlug to where_(your_slug_field_name) with CamelCase | |
*/ | |
public function store(Request $request) { | |
$unique_slug = Str::slug($request->title); | |
$unique_next = 2; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$year = date('y'); | |
$study_year = $year . ($year + 1); | |
$dept_code = 123; | |
$year_code = $study_year . $dept_code; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'pre_get_document_title', function( $title ){ | |
if(is_page('shop')){ | |
return "This is my shop, believe it or not! hahaha.... | " . get_bloginfo('description'); | |
} else { | |
return $title; | |
} | |
}, 999, 1 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$options[] = array( | |
'name' => 'header_options', | |
'title' => 'Header options', | |
'icon' => 'fa fa-plus-circle', | |
'sections' => array( | |
array( | |
'name' => 'logo_options', | |
'title' => 'Logo', | |
'icon' => 'fa fa-check', | |
'fields' => array( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function industry_rrfonline_custom_css(){ | |
$body_font = cs_get_option('body_font'); | |
$diffrent_heading_font = cs_get_option('diffrent_heading_font'); | |
$heading_font = cs_get_option('heading_font'); | |
if(!empty($body_font)){ | |
$body_font_family = $body_font['family']; | |
}else{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$my_name = "Muhammad Asadullah Al Galib"; | |
$my_age = 24; | |
$my_location = "Mirpur 2"; | |
echo 'My name is ' . $my_name . '<br />'; |