Skip to content

Instantly share code, notes, and snippets.

View ikamal7's full-sized avatar
💻
Tea & Code

Kamal Hosen ikamal7

💻
Tea & Code
View GitHub Profile
@ikamal7
ikamal7 / create_wp_user.php
Last active July 28, 2018 14:54
Create wp new user by Functions.php
<?php
$username = "username";
$password = "password1234";
$email = "[email protected]";
$create_user = new WP_user(wp_create_user($username, $password, $email) );
<?php
if (!defined('ABSPATH')) die('-1');
// Class started
class stockVCExtendAddonClass {
function __construct() {
// We safely integrate with VC with this hook
add_action( 'init', array( $this, 'stockIntegrateWithVC' ) );
<?php
/*
Plugin name: Seo Toolkit
*/
if( !defined('ABSPATH')){
exit;
}
<?php
function seo_slide_shortcode($atts){
extract(shortcode_atts(array(
'count' => 3,
'loop' => 'true',
'autoplay' => 'false',
'autoplayTimeout' => '3000',
'nav' => 'true',
'dots' => 'true',
<?php
vc_map( array(
"name" => esc_html__( "Slider", "seo-codervalley" ),
"base" => "seo_slider",
"category" => esc_html__( "SEO", "seo-codervalley"),
"params" => array(
array(
"type" => "textfield",
"heading" => esc_html__( "Count", "seo-codervalley" ),
/*
* ----------------------------------------------------------------------------------------
* STICKY JS
* ----------------------------------------------------------------------------------------
*/
$(window).on('scroll',function() {
var scroll = $(window).scrollTop();
if (scroll < 30) {
$(".header-area").removeClass("scroll-header");
}else{
jQuery(".main-menu ul ul").parent("li").children("a").append(' <i class="fa fa-angle-down"></i>')
.col-xs-offset-right-12 {
margin-right: 100%;
}
.col-xs-offset-right-11 {
margin-right: 91.66666667%;
}
.col-xs-offset-right-10 {
margin-right: 83.33333333%;
}
.col-xs-offset-right-9 {
// Add smooth scrolling to all links
$('a[href^="#"]').on('click', function(e) {
e.preventDefault();
var target = this.hash,
$target = $(target);
$('html, body').stop().animate({
'scrollTop': $target.offset().top
<?php
if ( ! function_exists( 'name_fonts_url' ) ) :
/**
* Register Google fonts for Your theme
*
* Create your own name_fonts_url() function to override in a child theme.