Skip to content

Instantly share code, notes, and snippets.

Avatar

Árpád Lehel Mátyus lehelmatyus

  • Urban Insight Inc.
  • Los Angeles
View GitHub Profile
View page-meta.php
<?php
// Instructions here https://www.lehelmatyus.com/965/salient-theme-header-custom-post-type
// original file from here https://pt.textbin.net/TWf0cspMrE provided by Diongo. Thanks!
add_action('add_meta_boxes_page', 'LHL_nectar_metabox_salient_headers_page');
function LHL_nectar_metabox_salient_headers_page() {
@lehelmatyus
lehelmatyus / LhL_uikit_walker.php
Last active Jan 11, 2020
WordPress Menu Walker to generate Uikit Navbar and Nav components from simple menu
View LhL_uikit_walker.php
<?php
class LhL_uikit_walker extends Walker_Nav_Menu {
private $menu_type;
function __construct($type) {
$this->menu_type = $type;
}
View price-script.html
<script type='text/javascript' src='https://dataviz.usc.edu/javascripts/api/viz_v1.js'></script><div class='tableauPlaceholder' style='width: 760px; height: 347px;'><object class='tableauViz' width='760' height='347' style='display:none;'><param name='host_url' value='https%3A%2F%2Fdataviz.usc.edu%2F' /> <param name='embed_code_version' value='3' /> <param name='site_root' value='/t/SolPrice' /><param name='name' value='MHA/MHACompletionRetentionforWeb' /><param name='tabs' value='no' /><param name='toolbar' value='yes' /><param name='showAppBanner' value='false' /><param name='filter' value='iframeSizedToWindow=true' /></object></div>
<iframe src="https://player.vimeo.com/video/346779221" width="640" height="360" frameborder="0" allow="autoplay; fullscreen" allowfullscreen></iframe>
View 61327.html
CASE A:
------------------------------
<li> Subject to the
<a role="button" tabindex="0" class="glossary-popover" title="" data-original-title="density"> <!-- LINK -->
density
</a>
<div class="hidden popover-content"> <!-- CONTENT -->
<p>A measure of the amount of <strong>information</strong>on a storage medium (tape or disk). For magnetic tape it is the amount of information recorded per unit length of tape (bits per inch or millimeter); for a disk, a fixed number of bits per sector, sectors per track, and tracks per disk</p>
</div> restriction of 2 units per acre, R-2 allows single-unit living in a detached house with a minimum lot size of 20,000 square feet.
View theme.php
<?php
function logichub_preprocess_views_view_field(array &$variables){
$id = $variables['field']->realField;
if ($id == 'field_blog_authors_target_id') {// || $id==’field_image_target_id’
$terms = $variables['field']->getValue($variables['row']);
$tids = array();
View page-meta.php
<?php
add_action('add_meta_boxes', 'YOURTHEME_metabox_page');
function YOURTHEME_metabox_page(){
$options = get_nectar_theme_options();
if(!empty($options['transparent-header']) && $options['transparent-header'] == '1') {
$disable_transparent_header = array(
'name' => __('Disable Transparency From Navigation', NECTAR_THEME_NAME),
'desc' => __('You can use this option to force your navigation header to stay a solid color even if it qualifies to trigger the <a target="_blank" href="'. admin_url('?page=redux_options&tab=4#header-padding') .'"> transparent effect</a> you have activated in the Salient options panel.', NECTAR_THEME_NAME),
'id' => '_disable_transparent_header',
@lehelmatyus
lehelmatyus / wp-config.php
Created Mar 17, 2017
Default w-config.php for local development.
View wp-config.php
<?php
/**
* The base configuration for WordPress
*
* The wp-config.php creation script uses this file during the
* installation. You don't have to use the web site, you can
* copy this file to "wp-config.php" and fill in the values.
*
* This file contains the following configurations:
*
@lehelmatyus
lehelmatyus / .gitignore
Last active Dec 16, 2019
Special gitignore for WP Engine Workflow
View .gitignore
*~
.DS_Store
.svn
.cvs
.git
.sql
.gitattributes
.listing
*.bak
*.swp
View wp-config.php
if (isset($_SERVER['PANTHEON_ENVIRONMENT']) &&
$_SERVER['PANTHEON_ENVIRONMENT'] === 'live') {
if ($_SERVER['HTTP_HOST'] == 'lehelmatyus.com' ||
$_SERVER['HTTP_HOST'] == 'live-lehelmatyus.gotpantheon.com') {
header('HTTP/1.0 301 Moved Permanently');
header('Location: http://www.lehelmatyus.com'. $_SERVER['REQUEST_URI']);
exit();
}
}
You can’t perform that action at this time.