Skip to content

Instantly share code, notes, and snippets.

View justadityaraj's full-sized avatar
🎯
Focusing

Aditya Raj Singh justadityaraj

🎯
Focusing
View GitHub Profile
@justadityaraj
justadityaraj / css-layout-hack.js
Last active August 1, 2022 11:18 — forked from vcastroi/css-layout-hack.js
#Minified - Create a bookmark and paste this code as a URL to toggle the CSS on/off.
javascript:!function(){for(var c=document.body.getElementsByTagName("*"),b=[],a=0;a<c.length;a++)-1!=c[a].innerHTML.indexOf("* { background:#000!important;color:#0f0!important;outline:solid #f00 1px!important; background-color: rgba(255,0,0,.2) !important; }")&&b.push(c[a]);if(b.length>0)for(var a=0;a<b.length;a++)b[a].innerHTML="";else document.body.innerHTML+="<style>* { background:#000!important;color:#0f0!important;outline:solid #f00 1px!important; background-color: rgba(255,0,0,.2) !important; } * * { background-color: rgba(0,255,0,.2) !important; } * * * { background-color: rgba(0,0,255,.2) !important; } * * * * { background-color: rgba(255,0,255,.2) !important; } * * * * * { background-color: rgba(0,255,255,.2) !important; } * * * * * * { background-color: rgba(255,255,0,.2) !important; } * * * * * * * { background-color: rgba(255,0,0,.2) !important; } * * * * * * * * { background-color: rgba(0,255,0,.2) !important; }
//FTC Disclaimer besides post meta -single post
add_filter('astra_post_comments', 'function_to_add_post_comment_icon');
function function_to_add_post_comment_icon($output)
{
if (!empty($output)) {
$output = $output . '<span><a href='#disclaimerbtn' class='manual_trigger_5966'>FTC Disclaimer</a></span>';
}
return $output;
@justadityaraj
justadityaraj / css-toggle-bookmark.js
Last active August 1, 2022 11:17
Create a bookmark and paste this code as a URL to toggle the CSS on/off.
javascript:!function(){for(var c=document.body.getElementsByTagName("*"),b=[],a=0;a<c.length;a++)-1!=c[a].innerHTML.indexOf("* { background:#000!important;color:#0f0!important;outline:solid #f00 1px!important; background-color: rgba(255,0,0,.2) !important; }")&&b.push(c[a]);if(b.length>0)for(var a=0;a<b.length;a++)b[a].innerHTML="";else document.body.innerHTML+="<style>* { background:#000!important;color:#0f0!important;outline:solid #f00 1px!important; background-color: rgba(255,0,0,.2) !important; } * * { background-color: rgba(0,255,0,.2) !important; } * * * { background-color: rgba(0,0,255,.2) !important; } * * * * { background-color: rgba(255,0,255,.2) !important; } * * * * * { background-color: rgba(0,255,255,.2) !important; } * * * * * * { background-color: rgba(255,255,0,.2) !important; } * * * * * * * { background-color: rgba(255,0,0,.2) !important; } * * * * * * * * { background-color: rgba(0,255,0,.2) !important; }
@justadityaraj
justadityaraj / featured-after-title.php
Last active August 22, 2019 20:58
Genesis Framework: Display featured image after the title
<?php
//table of nine <9> with explanation
$table=9; //starting int value
$num=1; //num
while ($table<=90){ //until num
echo "9 × ".$num." is equal to ".$table."." . "\n"; //output format
$table+=9; //value to be addded in each interval
$num++; //num value add for chronological order
}
.sidebar .enews-widget input#subbutton:hover {
background-color: rgba(235, 83, 82);
}
.ab-block-post-grid .ab-block-post-grid-more-link {
color: white;
border-radius: 10px;
background: #0095D0;
padding: 5px;
}
.entry-content .search-form-submit {
font-family: Muli;
font-size: 13px
}
<?php
//* REMOVE THE <?php ABOVE BEFORE PASTING INTO functions.php
//* Customize Entry Meta Filed Under and Tagged Under
add_filter( 'genesis_post_meta', 'ig_entry_meta_footer' );
function ig_entry_meta_footer( $post_meta ) {
$post_meta = '[post_categories before="Category: "] [post_tags before="Tags: "]';
return $post_meta;
}