Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

LOOR Lab loorlab

🎯
Focusing
Block or report user

Report or block loorlab

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
@loorlab
loorlab / create_function_PHP.php
Created Jul 30, 2019
create_function() PHP 5.6 VS 7.2
View create_function_PHP.php
<?php
// PHP 5.6 Filters the options.php to add the minimum user capabilities.
add_filter( 'option_page_capability_' . ot_options_id(), create_function( '$caps', "return '$caps';" ), 999 );
// FIX
// PHP 7.X
add_filter(
'option_page_capability_' . ot_options_id(),
function() use ( $caps ) {
@loorlab
loorlab / readme.md
Created Jul 3, 2019 — forked from vicainelli/readme.md
Translate Mailchimp messages
View readme.md

Translate Mailchimp messages

@loorlab
loorlab / disable_auto_update_WP.md
Created Jul 2, 2019
Disable WordPress Auto-Update Feature
View disable_auto_update_WP.md

wp-config.php

define( 'WP_AUTO_UPDATE_CORE', false );

Allow only minor WordPress updates

define( 'WP_AUTO_UPDATE_CORE', minor );

View JIT_compilation_failed_PHP73_WP.md

PHP 7.3

Fix: If you're running #Composer @MacHomebrew and get this error "JIT compilation failed: no more memory" you need to:

  1. Create/edit /usr/local/etc/php/7.3/php.ini
  2. Disable PHP PCRE JIT compilation by changing ;pcre.jit=1 to pcre.jit=0
@loorlab
loorlab / add-script-handle.php
Created Jun 24, 2019 — forked from cameronjonesweb/add-script-handle.php
Display Handle Name JS WordPress - Add the script handle to enqueued script tags
View add-script-handle.php
<?php
add_filter( 'script_loader_tag', 'cameronjonesweb_add_script_handle', 10, 3 );
function cameronjonesweb_add_script_handle( $tag, $handle, $src ) {
return str_replace( '<script', sprintf(
'<script data-handle="%1$s"',
esc_attr( $handle )
), $tag );
}
@loorlab
loorlab / aws_ec2_ftp_credentials_AP.md
Created Jun 21, 2019
WordPress on EC2 Requires FTP Credentials to Install Plugins - AWS
View aws_ec2_ftp_credentials_AP.md

sudo chown -R apache:apache /var/www/html/blog/

@loorlab
loorlab / template_WP.md
Last active Jul 26, 2019
Templates WordPress 2019
View template_WP.md

COMPILATION :Templates WordPress 2019

THEME >>>>>>>>>>>>>>>>>-- Reference

https://themify.me/themes/ultra --> https://roboy.org/

                                 https://themeforest.net/item/bro-ultimate-agency-and-freelancer-theme/20391047
                                 
                                 https://wpkoi.com/asura-wpkoi-wordpress-theme/
View closeSkype.bat
taskkill /f /im skypeapp.exe
taskkill /f /im skypehost.exe
taskkill /f /im SkypeBridge.exe
taskkill /f /im SkypeBackgroundHost.exe
taskkill /f /im SkypeApp.exe
@loorlab
loorlab / index.php
Last active Apr 28, 2019
Solution : The script encountered an error while running an AJAX request. search/replace WordPress
View index.php
https://github.com/interconnectit/Search-Replace-DB/issues/217#issuecomment-421833420
@loorlab
loorlab / even_odd_display_repeater_acf_WP.php
Created Mar 30, 2019
Even / Odd Display with Repeater ACF Field - WordPress
View even_odd_display_repeater_acf_WP.php
<div class="level customers level-wrapper">
<ul class="categories">
<?php if( have_rows('items_page_block') ): ?>
<?php while( have_rows('items_page_block') ): the_row();
// vars
$image_item_block = get_sub_field('image_item');
$title_item_block = get_sub_field('title_item');
$text_item_block = get_sub_field('text_item');
if( get_row_index() % 2 == 0 ){ ?>
You can’t perform that action at this time.