Skip to content

Instantly share code, notes, and snippets.

Emili Castells Dinamiko

Block or report user

Report or block Dinamiko

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
@Dinamiko
Dinamiko / docu_before_index_content.php
Created Jan 22, 2015
adds a text before content in docu-index.php template
View docu_before_index_content.php
function custom_docu_before_index_content() {
echo '<h1>Before content</h1>';
}
add_action( 'docu_before_index_content', 'custom_docu_before_index_content' );
@Dinamiko
Dinamiko / docu_doc_post_type_args.php
Last active Aug 29, 2015
This example changes the default slug doc to document
View docu_doc_post_type_args.php
function custom_docu_doc_post_type_args( $docu_args ) {
$docu_args['rewrite'] = array('slug' => 'document');
return $docu_args;
}
add_filter( 'docu_doc_post_type_args', 'custom_docu_doc_post_type_args' );
@Dinamiko
Dinamiko / docu_doc_post_type_labels.php
Last active Aug 29, 2015
changes default menu_name to Documents in the admin
View docu_doc_post_type_labels.php
function custom_docu_doc_post_type_labels( $docu_labels ) {
$docu_labels['menu_name'] = __('Documents', 'my-text-domain');
return $docu_labels;
}
add_filter( 'docu_doc_post_type_labels', 'custom_docu_doc_post_type_labels' );
View style.css
.docu-item.tf-custom-item {
width:100%;
padding-left: 5%;
padding-right: 5%;
padding-top: 0;
padding-bottom: 0;
background:#3070d1;
color:#FFF;
}
@Dinamiko
Dinamiko / docu_before_sidebar_widget.php
Last active Aug 29, 2015
adds a text before docu sidebar widget
View docu_before_sidebar_widget.php
function custom_docu_before_sidebar_widget() {
echo '<h3>Before Docu Sidebar Widget</h3>';
}
add_action( 'docu_before_sidebar_widget', 'custom_docu_before_sidebar_widget' );
@Dinamiko
Dinamiko / docu_after_index_content.php
Created Jan 22, 2015
adds a text after content in docu-index.php template
View docu_after_index_content.php
function custom_docu_after_index_content() {
echo '<h1>After content</h1>';
}
add_action( 'docu_after_index_content', 'custom_docu_after_index_content' );
View docu-item.php
<div class="docu-item <?php echo $col;?>">
View style.css
/*
Theme Name: Twenty Fifteen Child
Theme URI: http://example.com/twenty-fifteen-child/
Description: Twenty Fifteen Child Theme
Author: John Doe
Author URI: http://example.com
Template: twentyfifteen
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
@Dinamiko
Dinamiko / ocu_after_sidebar_widget.php
Last active Aug 29, 2015
adds a text before docu sidebar widget
View ocu_after_sidebar_widget.php
function custom_docu_after_sidebar_widget() {
echo '<h3>After Docu Sidebar Widget</h3>';
}
add_action( 'docu_after_sidebar_widget', 'custom_docu_after_sidebar_widget' );
You can’t perform that action at this time.