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
| [ | |
| { | |
| "street": "84 Clover St", | |
| "city": "Gordon", | |
| "state": "AL", | |
| "state_full": "Alabama", | |
| "postcode": "36343", | |
| "phone": "5555555555", | |
| "phone_dial_code": "+1", | |
| "phone_international": "+15555555555", |
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
| # Universal project run function | |
| # Checks for a Runfile first, then auto-detects by project type. | |
| run() { | |
| # 1. Explicit Runfile | |
| if [[ -f "Runfile" ]]; then | |
| echo "▶ Running via Runfile" | |
| local cmd | |
| cmd=$(cat Runfile) | |
| eval "$cmd" | |
| return |
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 | |
| /* | |
| Trying to capture text that is wrapped in curly braces (e.g. {example}) | |
| Problem: [\S\ ]* would capture multiple tags that are on the same line. | |
| */ | |
| preg_match_all("(\{[\S\ ]*\})", $template, $tags); | |
| // $tags = "{field=first_name} - {field=last_name}" ] | |
| /* |
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 | |
| add_filter('facetwp_is_main_query', filter_facetwp_is_main_query, 10, 2 ); | |
| function filter_facetwp_is_main_query( $is_main_query, $query ) { | |
| if ( 'template' == $query->get('post_type') ) $is_main_query = FALSE; | |
| return $is_main_query; | |
| } |
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 | |
| add_filter('sanitize_user_meta_magic_login_token', 'filter_sanitize_user_meta_magic_login_token', 10, 1); | |
| function filter_sanitize_user_meta_magic_login_token( $meta_value ) { | |
| $redirect_to = $_POST['redirect_to'] ?? FALSE; | |
| if ( $redirect_to && strpos($redirect_to, '/investor-resources/') > -1 ) { | |
| $days = get_field('resource_token_ttl', 'options') ?? 3; | |
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
| var buttonChange = document.querySelector('#dns-content-nameservers button'); | |
| buttonChange.click(); | |
| setTimeout(function() { | |
| var radioCustom = document.querySelector('#nameserver-type-CUSTOM'), | |
| list = ['new nameserver #1', 'new nameserver #2', 'new nameserver #3', 'new nameserver #4']; | |
| radioCustom.click(); | |
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
| <IfModule mod_rewrite.c> | |
| RewriteEngine On | |
| RewriteCond %{REQUEST_FILENAME} !-f [NC] | |
| RewriteCond %{REQUEST_FILENAME} !-d [NC] | |
| RewriteCond %{REQUEST_URI} !^/wp-admin|wp-includes | |
| RewriteRule ^(.*\.(js|css|png|jpe?g|gif|ico)) https://example.com/$1 [QSA,L] | |
| </IfModule> |
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
| # Basic Settings | |
| # | |
| fontName = "Monaco" | |
| fontSize = 16 | |
| # Extra files to include | |
| # | |
| myExtraIncludes = ".tm_properties,.htaccess,.gitignore" | |
| fileBrowserGlob = "{*,$myExtraIncludes}" | |
| include = "{$include,$myExtraIncludes}" |
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
| function action_pmxi_saved_post( $id ) { | |
| $dir = wp_upload_dir(); | |
| $img_array = []; | |
| $media = get_attached_media('image', $id); | |
| $thepost = get_post($id); | |
| foreach($media as $media_id => $item) { | |
| $metadata = wp_get_attachment_metadata($item->ID, true); | |
| $directory = explode('/', $metadata['file']); | |
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
| <IfModule mod_rewrite.c> | |
| RewriteEngine On | |
| RewriteCond %{REQUEST_FILENAME} !-f [NC] | |
| RewriteRule ^(.*\.(js|css|png|jpe?g|gif|ico)) https://www.example.com/$1 [QSA,L,C] | |
| </IfModule> | |
| # BEGIN WordPress | |
| <IfModule mod_rewrite.c> | |
| RewriteEngine On | |
| RewriteBase / |
NewerOlder