Nodes
-
see what is accessing disk / force unmount disk
Submitted by orgnsm on Sun, 12/24/2023 - 14:08 -
Find which file a function is defined in
Submitted by orgnsm on Mon, 12/26/2016 - 10:42 -
Custom Post Types
Submitted by orgnsm on Sun, 12/25/2016 - 13:03Adds custom post type called "Reviews"
<?php function create_post_type(){ register_post_type('review', array( 'labels'=>array( 'name'=>__('Reviews'), 'singular_name'=>__('Review') ), 'public'=>true, 'has_archive'=>true, 'capabilities'=>array( 'edit_post'=>'edit_review', 'edit_posts'=>'edit_reviews', 'publish_posts'=>'publish_review', 'read_post'=>'read_review', ), ) ); } add_action('init','create_post_type'); ?>
Add abilities to "Reviews" post type
<?php function add_theme_caps(){ $subscribers=get_role('subscriber'); $subscribers->add_cap('edit_review'); $subscribers->add_cap('edit_reviews'); $subscribers->add_cap('publish_review'); $subscribers->add_cap('read_review'); $admins=get_role('administrator'); $admins->add_cap('edit_review'); $admins->add_cap('edit_reviews'); $admins->add_cap('publish_review'); $admins->add_cap('read_review'); } add_action('admin_init','add_theme_caps'); ?>
Add custom fields to "Reviews" post type
<?php add_action('admin_init','add_review_metas'); function add_review_metas(){ add_meta_box('review_rating-meta','Rating','review_rating','review','normal','low'); } function review_rating(){ global $post; $custom=get_post_custom($post->ID); $review_rating=$custom['review_rating'][0]; for($x=1;$x<6;$x++){ echo('<input'); if($x==$review_rating) echo(' checked="checked"'); echo(' type="radio" name="review_rating" id="review_rating_'.$x.'" value="'.$x.'"/><label for="review_rating_'.$x.'">'.$x.'</label>'."\n"); } } add_action('save_post','save_details'); function save_details(){ global $post; update_post_meta($post->ID,'review_rating',$_POST["review_rating"]); } ?>
-
In the Weeds
Submitted by orgnsm on Tue, 12/06/2016 - 17:03Subtitle:Restaurant Management ToolContext:Connection:Attribute Type:TypesInstallation URL:http://stage.orgnsm.org/in-the-weedsImages: -
Post referencing setup
Submitted by orgnsm on Thu, 12/01/2016 - 16:46Subtitle:Assign multiple disciplines to a project<?php // Adds custom post type for Projects and Services function create_post_type(){ register_post_type('project', array( 'labels' => array( 'name' => __('Projects'), 'singular_name' => __('Project') ), 'taxonomies' => array('category'), 'public' => true, 'has_archive' => true, 'capabilities' => array( 'edit_post' => 'edit_project', 'edit_posts' => 'edit_projects', 'publish_posts' => 'publish_project', 'read_post' => 'read_project', ), 'supports' => array( 'title','editor','thumbnail' ), ) ); register_post_type('service', array( 'labels' => array( 'name' => __('Services'), 'singular_name' => __('Service') ), 'public' => true, 'has_archive' => true, 'capabilities' => array( 'edit_post' => 'edit_service', 'edit_posts' => 'edit_services', 'publish_posts' => 'publish_service', 'read_post' => 'read_service', ), 'supports' => array( 'title','editor','thumbnail' ), ) ); } add_action('init','create_post_type'); function add_theme_caps(){ $subscribers = get_role( 'subscriber' ); //$subscribers->add_cap( 'edit_project' ); //$subscribers->add_cap( 'edit_projects' ); //$subscribers->add_cap( 'publish_project' ); $subscribers->add_cap( 'read_project' ); $subscribers->add_cap( 'read_service' ); $admins = get_role( 'administrator' ); $admins->add_cap( 'edit_project' ); $admins->add_cap( 'edit_projects' ); $admins->add_cap( 'publish_project' ); $admins->add_cap( 'read_project' ); $admins->add_cap( 'edit_service' ); $admins->add_cap( 'edit_services' ); $admins->add_cap( 'publish_service' ); $admins->add_cap( 'read_service' ); } add_action('init','add_theme_caps'); // Adds custom field to the PROJECT custom post type function add_project_metas(){ add_meta_box( 'project_service-meta', 'Service', 'project_service', 'project', 'normal', 'low' ); } add_action('admin_init','add_project_metas'); function project_service(){ global $post; $custom=get_post_custom($post->ID); $project_services=$custom['project_service'][0]; $project_services=unserialize($project_services); $args=array( 'post_type'=>'service', 'posts_per_page'=>'200', 'orderby'=>'title', 'order'=>'ASC' ); $loop=new WP_Query($args); while($loop->have_posts()):$loop->the_post(); echo('<div><input type="checkbox" name="project_services[]" value="'.get_the_ID().'" id="project_service_'.get_the_ID().'"'); if(is_array($project_services)&&in_array(get_the_ID(),$project_services)) echo(' checked="checked"'); //checked($project_services,get_the_ID()); echo('><label for="project_service_'.get_the_ID().'">'.get_the_title(get_the_ID()).'</label></div>'); endwhile; } function save_details(){ global $post; update_post_meta($post->ID,'project_service',$_POST["project_services"]); } add_action('save_post','save_details'); ?>
-
Covidien Portal
Submitted by orgnsm on Thu, 11/03/2016 - 14:38Subtitle:A resource and tool for physiciansContext:Connection:Attribute Type:TypesInstallation URL:http://covidien.orgnsm.orgImages: -
Foster Care Training
Submitted by orgnsm on Tue, 10/25/2016 - 10:58Subtitle:Education Service PromotionContext:Connection:Attribute Type:TypesInstallation URL:http://fostercaretraining.orgImages: -
AG & Associates
Submitted by orgnsm on Tue, 10/25/2016 - 10:57Subtitle:Construction Portfolio & PromotionContext:Connection:Attribute Type:TypesInstallation URL:http://agassociatesinc.comImages: -
Calvin Associates
Submitted by orgnsm on Tue, 10/25/2016 - 10:57Subtitle:Lawyer Firm PromotionalContext:Connection:Attribute Type:TypesInstallation URL:http://calvin-associates.comImages: -
Ferber Law
Submitted by orgnsm on Tue, 10/25/2016 - 10:41Subtitle:Lawyer Firm PromotionalContext:Connection:Attribute Type:TypesInstallation URL:http://danvillelaw.comImages: -
Oakland Police
Submitted by orgnsm on Tue, 10/25/2016 - 10:41Subtitle:Charity Information & DonationContext:Connection:Attribute Type:TypesInstallation URL:http://oaklandpolicefoundation.orgImages: -
Orgnsm (ROOT)
Submitted by orgnsm on Mon, 08/15/2016 - 22:54Subtitle:Community Outreach Divisions CatalogContext:Connection:Attribute Type:TypesInstallation URL:http://orgnsm.orgImages:Process Imagery: -
Tru frame
Submitted by orgnsm on Sat, 01/16/2016 - 12:16Subtitle:Product promotionContext:Connection:Attribute Type:TypesImages: -
Lotto-rithm
Submitted by orgnsm on Sat, 01/16/2016 - 12:16Subtitle:Algorithm knowledge promotionContext:Connection:Attribute Type:TypesImages: -
Rate Your Customer / Rate My Contractor
Submitted by orgnsm on Fri, 12/25/2015 - 12:46Context:Connection:Attribute Type:TypesImages: -
IXIAS
Submitted by orgnsm on Thu, 08/20/2015 - 15:21Subtitle:my homepageContext:Connection:Attribute Type:TypesInstallation URL:http://ixias.orgnsm.orgImages: -
NeuroGenesix
Submitted by orgnsm on Wed, 07/29/2015 - 01:55Subtitle:Dance Music Event InformationContext:Connection:Attribute Type:TypesInstallation URL:http://neurogenesix.melanieblau.orgImages:Process Imagery: -
Font-embed Rundown
Submitted by orgnsm on Sun, 09/28/2014 - 10:08Context:Connection:Attribute Type:TypesTTF - Works in most browsers except IE and iPhone EOT - IE only WOFF - Compressed, emerging standard SVG - iPhone/iPad
-
Using jQuery flexslider with animated captions callback
Submitted by orgnsm on Thu, 09/04/2014 - 17:45jQuery(window).load(function(){ jQuery('.flexslider').flexslider( { pauseOnHover: true, controlsContainer: ".flex-container", slideshowSpeed: 8000, before: function(slider){ var currentSlide = slider.slides.eq(slider.currentSlide); jQuery(currentSlide).find('.flex-caption').animate({'opacity':'0','right':'30px'},700); }, after: function(slider){ var currentSlide = slider.slides.eq(slider.currentSlide); jQuery(currentSlide).find('.flex-caption').animate({'opacity':'1','right':'0'},700); }, start: function(slider){ var currentSlide = slider.slides.eq(slider.currentSlide); jQuery(currentSlide).find('.flex-caption').animate({'opacity':'1','right':'0'},700); }, } ); } );
.flex-container .flexslider ul.slides li a p.flex-caption{ background-color: rgba(255,255,255,.9); color: rgba(55,55,55,.98); font-size: 20px; position: absolute; bottom: 0; right: 0; right: 30px; left: auto; z-index: 1; padding: 15px; width: 33.3%; font-style: italic; margin: 0; opacity: 0; }
-
Removes fields pending for deletion to uninstall a stuck module
Submitted by orgnsm on Sun, 07/13/2014 - 19:37