Skip to content

Instantly share code, notes, and snippets.

Asif asifsomy

Block or report user

Report or block asifsomy

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View get_social_links()
asifsomy / .htaccess
Created Apr 4, 2017
Wordpress: Pull remote images while working in localhost
View .htaccess
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{HTTP_HOST} ^127\.0\.0\.1$
RewriteRule ^wp-content/uploads/(.*)$$1 [NC,L]
asifsomy / addCats.php
Last active Jan 28, 2016
Create Bulk Magento Categories
View addCats.php
$cats = array(
'Name' => 'Description.',
define('MAGENTO', realpath(dirname(__FILE__)));
require_once MAGENTO . '/app/Mage.php';
asifsomy / functions.php
Last active Jan 6, 2016
Remove Unwanted Archive URLs
View functions.php
function cd_remove_unwanted_archives(){
if( is_search() || is_category() || is_tag() || is_date() || is_author() ) {
global $wp_query;
add_action('template_redirect', 'cd_remove_unwanted_archives');
asifsomy / WrapDivs.php
Last active Jan 6, 2016
Wrap n number of divs into a parent div
View WrapDivs.php
$wrap_count = 4; // you can change this no of divs to wrap
foreach ($categories as $category)
echo '<div class="row">';
<div class="col-lg-3 col-md-3">.....</div>
asifsomy / functions.php
Last active Aug 29, 2015 — forked from redesigned/functions.php
Wordpress Magento Cross Integration
View functions.php
/* ===================================== */
/* Add This to Wordpress's /wp-content/yourtheme/functions.php file */
define('MAGENTO_ROOT', '/Volumes/Storage/www/heartandsun/store/');
define('MAGENTO_LOADER', MAGENTO_ROOT.'app/Mage.php');
if (!class_exists('Mage')) {
/* ===================================== */
asifsomy / wpcf-form-triggers.css
Last active Feb 10, 2018
Contact from 7 On Submit, Invalid, Spam, MailSent, Mail Failed JS triggers
View wpcf-form-triggers.css
div.wpcf7 img.ajax-loader{display:none; margin:5px auto 0;}
You can’t perform that action at this time.