SlideShare una empresa de Scribd logo
1 de 43
Keeping It Simple
      (but not stupid)



   Stephanie Leary, @sleary
        sillybean.net
Dashboard & Menus
Unclutter: Adminimize
Dashboard Commander
Prefer Code?
function remove_dashboard_widgets() {
    global $wp_meta_boxes;
    unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']);
// unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']);
// unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']);
// unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_drafts']);
    unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']);
    unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_plugins']);
    // WordPress Blog
    unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']);
    // Other WordPress News
    unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_secondary']);
}
add_action('wp_dashboard_setup', 'remove_dashboard_widgets' );



                  http://gist.github.com/2722692
CMS Dashboard
Full Comments On
    Dashboard
Dashboard Notepad
Widgets




http://core.trac.wordpress.org/ticket/18334
Widgets




http://core.trac.wordpress.org/ticket/18334
Organizing
Hierarchy
Simple Page Ordering
List Child Pages
// list child pages automatically on empty pages
function append_child_pages($content) {
   $children = '';
   if (is_page() && (empty($content))) {
      global $post;
      $children = '
<ul
class="childpages">'.wp_list_pages('echo=0&title_li=&child_of='.
$post->ID).'</ul>
';
   }
   return $content.$children;
}
add_filter('the_content','append_child_pages');
List Child Pages

// child page list shortcode: [children]
function child_pages_shortcode() {
   global $post;
   return '<ul class="childpages">'.
" " wp_list_pages('echo=0&depth=0&title_li=&child_of='.
" " $post->ID).'</ul>';
}
add_shortcode('children', 'child_pages_shortcode');
Writing
Shortcode Reference
Gallery Metabox
Post Container Warning
Post Container Warning
// Admin Notice on Posts Page
add_action('admin_head-post.php', 'postspage_error_notice');

function postspage_error_notice() {
    $postspage = get_option('page_for_posts');
    if (!empty($postspage))
        add_action('admin_notices', 'postspage_print_notices');
}

function postspage_print_notices() {
    $postspage = get_option('page_for_posts');

    // show this only if we're editing the posts page
    if (!empty($postspage) && isset($_GET['action']) &&
$_GET['action'] == 'edit' && $_GET['post'] == $postspage)
        echo '<div class="error"><p>This page is a container for
the most recent posts. It should always be empty, and you should
never edit this page. To add a news item, go to <a href="post-
new.php">Posts -- Add New</a>.<p></div>';
}

       http://gist.github.com/2515588
Removing Meta Boxes

add_action( 'add_meta_boxes', 'my_remove_post_meta_boxes' );


function my_remove_post_meta_boxes() {


"   /* Custom fields meta box. */
"   remove_meta_box( 'postcustom', 'post', 'normal' );
}




          justintadlock.com/?p=2898
Raw HTML Snippets
Notifications
Peter’s Collaboration
       Emails
Notifly
Collateral Condolences
For Visitors
Better 404s


• apologetic, personal language
• search for words in the bad URL
• show search box and sitemap


     http://gist.github.com/2723096
404.php (1)
"   <h2>I'm sorry. I couldn't find the page you requested.</h2>
"   <?php
"   $options = us2011_get_options();
"   if (!empty($options['problem_report']))
"   "   $report = 'If you still can't find it, <a
href="'.get_permalink($options['problem_report']).'">please let us
know what you were looking for,</a> and maybe we can find it for
you!';
"   if (!empty($options['sitemap']))
"   "   $sitemap = ' or looking for it in the <a href="/
sitemap">site map</a>';
"   ?>


"   <p>You can try searching for it<?php echo $sitemap; ?>.
"   <?php echo $report; ?></p>
"   <?php get_template_part( 'searchform' ); ?>
404.php (2)
"   <?php
"   global $wp_query;
"   $wp_query->query_vars['is_search'] = true;
"   $s = str_replace("-"," ",$wp_query->query_vars['name']);
"   $loop = new WP_Query('post_type=any&s='.$s);
"   ?>
"   <?php if ($loop->have_posts()) : ?>
"   "   <p>I'm searching for the name of the page you tried to
visit... was it one of these?</p>
"    "   <ol>
"    "   <?php while ($loop->have_posts()) : $loop->the_post(); ?>
"   "   "   <li><a href="<?php the_permalink(); ?>"><?php
the_title(); ?></a>
"    "   "   "   <?php the_excerpt(); ?>
"    "   "   </li>
"    "   <?php endwhile; ?>
"    "   </ol>
    "<?php endif; ?>
RSS?
“Report a problem”


• More likely to be used than “contact”
• Automatically fill in referring URL
• Link in theme footer
Gravity Forms example
How do you
keep it simple?
Thanks!
   @sleary
sillybean.net

Más contenido relacionado

La actualidad más candente

16. CodeIgniter stergerea inregistrarilor
16. CodeIgniter stergerea inregistrarilor16. CodeIgniter stergerea inregistrarilor
16. CodeIgniter stergerea inregistrarilorRazvan Raducanu, PhD
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applicationselliando dias
 
Bag Of Tricks From Iusethis
Bag Of Tricks From IusethisBag Of Tricks From Iusethis
Bag Of Tricks From IusethisMarcus Ramberg
 
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...allilevine
 
Gravity Forms Hooks & Filters
Gravity Forms Hooks & FiltersGravity Forms Hooks & Filters
Gravity Forms Hooks & Filtersiamdangavin
 
Add edit delete in Codeigniter in PHP
Add edit delete in Codeigniter in PHPAdd edit delete in Codeigniter in PHP
Add edit delete in Codeigniter in PHPVineet Kumar Saini
 
Country State City Dropdown in PHP
Country State City Dropdown in PHPCountry State City Dropdown in PHP
Country State City Dropdown in PHPVineet Kumar Saini
 
Let's write secure Drupal code!
Let's write secure Drupal code!Let's write secure Drupal code!
Let's write secure Drupal code!Balázs Tatár
 
Анатолий Поляков - Drupal.ajax framework from a to z
Анатолий Поляков - Drupal.ajax framework from a to zАнатолий Поляков - Drupal.ajax framework from a to z
Анатолий Поляков - Drupal.ajax framework from a to zLEDC 2016
 
Settings API - Oslo WordPress Meetup - November 22, 2011
Settings API - Oslo WordPress Meetup - November 22, 2011Settings API - Oslo WordPress Meetup - November 22, 2011
Settings API - Oslo WordPress Meetup - November 22, 2011WPOslo
 
17. CodeIgniter login simplu cu sesiuni
17. CodeIgniter login simplu cu sesiuni17. CodeIgniter login simplu cu sesiuni
17. CodeIgniter login simplu cu sesiuniRazvan Raducanu, PhD
 
WordPress overloading Gravityforms using hooks, filters and extending classes
WordPress overloading Gravityforms using hooks, filters and extending classes WordPress overloading Gravityforms using hooks, filters and extending classes
WordPress overloading Gravityforms using hooks, filters and extending classes Paul Bearne
 
Make your own wp cli command in 10min
Make your own wp cli command in 10minMake your own wp cli command in 10min
Make your own wp cli command in 10minIvelina Dimova
 
JavaScriptフレームワーク比較!
JavaScriptフレームワーク比較!JavaScriptフレームワーク比較!
JavaScriptフレームワーク比較!CASAREAL, Inc.
 
Sins Against Drupal 2
Sins Against Drupal 2Sins Against Drupal 2
Sins Against Drupal 2Aaron Crosman
 

La actualidad más candente (20)

16. CodeIgniter stergerea inregistrarilor
16. CodeIgniter stergerea inregistrarilor16. CodeIgniter stergerea inregistrarilor
16. CodeIgniter stergerea inregistrarilor
 
8. vederea inregistrarilor
8. vederea inregistrarilor8. vederea inregistrarilor
8. vederea inregistrarilor
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applications
 
Bag Of Tricks From Iusethis
Bag Of Tricks From IusethisBag Of Tricks From Iusethis
Bag Of Tricks From Iusethis
 
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...
WordCamp Montreal 2015: Combining Custom Post Types, Fields, and Meta Boxes t...
 
Pagination in PHP
Pagination in PHPPagination in PHP
Pagination in PHP
 
Gravity Forms Hooks & Filters
Gravity Forms Hooks & FiltersGravity Forms Hooks & Filters
Gravity Forms Hooks & Filters
 
Add edit delete in Codeigniter in PHP
Add edit delete in Codeigniter in PHPAdd edit delete in Codeigniter in PHP
Add edit delete in Codeigniter in PHP
 
Country State City Dropdown in PHP
Country State City Dropdown in PHPCountry State City Dropdown in PHP
Country State City Dropdown in PHP
 
Let's write secure Drupal code!
Let's write secure Drupal code!Let's write secure Drupal code!
Let's write secure Drupal code!
 
Анатолий Поляков - Drupal.ajax framework from a to z
Анатолий Поляков - Drupal.ajax framework from a to zАнатолий Поляков - Drupal.ajax framework from a to z
Анатолий Поляков - Drupal.ajax framework from a to z
 
Settings API - Oslo WordPress Meetup - November 22, 2011
Settings API - Oslo WordPress Meetup - November 22, 2011Settings API - Oslo WordPress Meetup - November 22, 2011
Settings API - Oslo WordPress Meetup - November 22, 2011
 
17. CodeIgniter login simplu cu sesiuni
17. CodeIgniter login simplu cu sesiuni17. CodeIgniter login simplu cu sesiuni
17. CodeIgniter login simplu cu sesiuni
 
$.Template
$.Template$.Template
$.Template
 
WordPress overloading Gravityforms using hooks, filters and extending classes
WordPress overloading Gravityforms using hooks, filters and extending classes WordPress overloading Gravityforms using hooks, filters and extending classes
WordPress overloading Gravityforms using hooks, filters and extending classes
 
Bacbkone js
Bacbkone jsBacbkone js
Bacbkone js
 
Codigo taller-plugins
Codigo taller-pluginsCodigo taller-plugins
Codigo taller-plugins
 
Make your own wp cli command in 10min
Make your own wp cli command in 10minMake your own wp cli command in 10min
Make your own wp cli command in 10min
 
JavaScriptフレームワーク比較!
JavaScriptフレームワーク比較!JavaScriptフレームワーク比較!
JavaScriptフレームワーク比較!
 
Sins Against Drupal 2
Sins Against Drupal 2Sins Against Drupal 2
Sins Against Drupal 2
 

Destacado

Strive for Inbox Zero and Unclutter Your Business Mind
Strive for Inbox Zero and Unclutter Your Business MindStrive for Inbox Zero and Unclutter Your Business Mind
Strive for Inbox Zero and Unclutter Your Business MindAffiliate Summit
 
It’s all too much! Unclutter your house in the New Year
It’s all too much!  Unclutter your house in the New Year It’s all too much!  Unclutter your house in the New Year
It’s all too much! Unclutter your house in the New Year Lisa Hooper
 
UpMSOfficeOrganize
UpMSOfficeOrganizeUpMSOfficeOrganize
UpMSOfficeOrganizefosterstac
 
Why Organizing Paper is a Challenge
Why Organizing Paper is a ChallengeWhy Organizing Paper is a Challenge
Why Organizing Paper is a ChallengeCatherine Anderson
 

Destacado (7)

Boost your happiness at work
Boost your happiness at workBoost your happiness at work
Boost your happiness at work
 
Strive for Inbox Zero and Unclutter Your Business Mind
Strive for Inbox Zero and Unclutter Your Business MindStrive for Inbox Zero and Unclutter Your Business Mind
Strive for Inbox Zero and Unclutter Your Business Mind
 
Unclutter
UnclutterUnclutter
Unclutter
 
Technology for Organizing
Technology for OrganizingTechnology for Organizing
Technology for Organizing
 
It’s all too much! Unclutter your house in the New Year
It’s all too much!  Unclutter your house in the New Year It’s all too much!  Unclutter your house in the New Year
It’s all too much! Unclutter your house in the New Year
 
UpMSOfficeOrganize
UpMSOfficeOrganizeUpMSOfficeOrganize
UpMSOfficeOrganize
 
Why Organizing Paper is a Challenge
Why Organizing Paper is a ChallengeWhy Organizing Paper is a Challenge
Why Organizing Paper is a Challenge
 

Similar a Keeping It Simple

Drupal Development (Part 2)
Drupal Development (Part 2)Drupal Development (Part 2)
Drupal Development (Part 2)Jeff Eaton
 
You Don't Know Query (WordCamp Netherlands 2012)
You Don't Know Query (WordCamp Netherlands 2012)You Don't Know Query (WordCamp Netherlands 2012)
You Don't Know Query (WordCamp Netherlands 2012)andrewnacin
 
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress WordCamp Kyiv
 
PHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4DevelopersPHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4DevelopersKacper Gunia
 
You Don't Know Query - WordCamp Portland 2011
You Don't Know Query - WordCamp Portland 2011You Don't Know Query - WordCamp Portland 2011
You Don't Know Query - WordCamp Portland 2011andrewnacin
 
Tidy Up Your Code
Tidy Up Your CodeTidy Up Your Code
Tidy Up Your CodeAbbas Ali
 
Unit testing with zend framework PHPBenelux
Unit testing with zend framework PHPBeneluxUnit testing with zend framework PHPBenelux
Unit testing with zend framework PHPBeneluxMichelangelo van Dam
 
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you need
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you needDutch PHP Conference - PHPSpec 2 - The only Design Tool you need
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you needKacper Gunia
 
Using Geeklog as a Web Application Framework
Using Geeklog as a Web Application FrameworkUsing Geeklog as a Web Application Framework
Using Geeklog as a Web Application FrameworkDirk Haun
 
WordPress REST API hacking
WordPress REST API hackingWordPress REST API hacking
WordPress REST API hackingJeroen van Dijk
 
Unit testing with zend framework tek11
Unit testing with zend framework tek11Unit testing with zend framework tek11
Unit testing with zend framework tek11Michelangelo van Dam
 
laravel tricks in 50minutes
laravel tricks in 50minuteslaravel tricks in 50minutes
laravel tricks in 50minutesBarang CK
 
50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 MinutesAzim Kurt
 

Similar a Keeping It Simple (20)

Drupal Development (Part 2)
Drupal Development (Part 2)Drupal Development (Part 2)
Drupal Development (Part 2)
 
Daily notes
Daily notesDaily notes
Daily notes
 
Wp query
Wp queryWp query
Wp query
 
You Don't Know Query (WordCamp Netherlands 2012)
You Don't Know Query (WordCamp Netherlands 2012)You Don't Know Query (WordCamp Netherlands 2012)
You Don't Know Query (WordCamp Netherlands 2012)
 
Add loop shortcode
Add loop shortcodeAdd loop shortcode
Add loop shortcode
 
Zero to SOLID
Zero to SOLIDZero to SOLID
Zero to SOLID
 
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress
WordPress Kitchen 2014 - Александр Стриха: Кеширование в WordPress
 
PHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4DevelopersPHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4Developers
 
You Don't Know Query - WordCamp Portland 2011
You Don't Know Query - WordCamp Portland 2011You Don't Know Query - WordCamp Portland 2011
You Don't Know Query - WordCamp Portland 2011
 
Min-Maxing Software Costs
Min-Maxing Software CostsMin-Maxing Software Costs
Min-Maxing Software Costs
 
Tidy Up Your Code
Tidy Up Your CodeTidy Up Your Code
Tidy Up Your Code
 
Php
PhpPhp
Php
 
Unit testing with zend framework PHPBenelux
Unit testing with zend framework PHPBeneluxUnit testing with zend framework PHPBenelux
Unit testing with zend framework PHPBenelux
 
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you need
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you needDutch PHP Conference - PHPSpec 2 - The only Design Tool you need
Dutch PHP Conference - PHPSpec 2 - The only Design Tool you need
 
Using Geeklog as a Web Application Framework
Using Geeklog as a Web Application FrameworkUsing Geeklog as a Web Application Framework
Using Geeklog as a Web Application Framework
 
logic321
logic321logic321
logic321
 
WordPress REST API hacking
WordPress REST API hackingWordPress REST API hacking
WordPress REST API hacking
 
Unit testing with zend framework tek11
Unit testing with zend framework tek11Unit testing with zend framework tek11
Unit testing with zend framework tek11
 
laravel tricks in 50minutes
laravel tricks in 50minuteslaravel tricks in 50minutes
laravel tricks in 50minutes
 
50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes
 

Más de Stephanie Leary

Writing for the Web in Government and Education
Writing for the Web in Government and EducationWriting for the Web in Government and Education
Writing for the Web in Government and EducationStephanie Leary
 
Content Strategy for WordPress: Case Study
Content Strategy for WordPress: Case StudyContent Strategy for WordPress: Case Study
Content Strategy for WordPress: Case StudyStephanie Leary
 
Content Strategy for WordPress
Content Strategy for WordPressContent Strategy for WordPress
Content Strategy for WordPressStephanie Leary
 
There's a Plugin for That
There's a Plugin for ThatThere's a Plugin for That
There's a Plugin for ThatStephanie Leary
 
The WordPress University 2012
The WordPress University 2012The WordPress University 2012
The WordPress University 2012Stephanie Leary
 
The WordPress University
The WordPress UniversityThe WordPress University
The WordPress UniversityStephanie Leary
 
WordPress Hidden Gems (July 2011)
WordPress Hidden Gems (July 2011)WordPress Hidden Gems (July 2011)
WordPress Hidden Gems (July 2011)Stephanie Leary
 
WordPress Tips and Tricks (DFW Meetup)
WordPress Tips and Tricks (DFW Meetup)WordPress Tips and Tricks (DFW Meetup)
WordPress Tips and Tricks (DFW Meetup)Stephanie Leary
 
What's New in WordPress 3.0 (for developers)
What's New in WordPress 3.0 (for developers)What's New in WordPress 3.0 (for developers)
What's New in WordPress 3.0 (for developers)Stephanie Leary
 
Social Media for Researchers
Social Media for ResearchersSocial Media for Researchers
Social Media for ResearchersStephanie Leary
 
WordPress as a CMS (short version)
WordPress as a CMS (short version)WordPress as a CMS (short version)
WordPress as a CMS (short version)Stephanie Leary
 

Más de Stephanie Leary (19)

WordPress for the 99%
WordPress for the 99%WordPress for the 99%
WordPress for the 99%
 
Content First in Action
Content First in ActionContent First in Action
Content First in Action
 
Writing for the Web in Government and Education
Writing for the Web in Government and EducationWriting for the Web in Government and Education
Writing for the Web in Government and Education
 
Getting to WordPress
Getting to WordPressGetting to WordPress
Getting to WordPress
 
Content Strategy for WordPress: Case Study
Content Strategy for WordPress: Case StudyContent Strategy for WordPress: Case Study
Content Strategy for WordPress: Case Study
 
Content Strategy for WordPress
Content Strategy for WordPressContent Strategy for WordPress
Content Strategy for WordPress
 
There's a Plugin for That
There's a Plugin for ThatThere's a Plugin for That
There's a Plugin for That
 
The WordPress University 2012
The WordPress University 2012The WordPress University 2012
The WordPress University 2012
 
The WordPress University
The WordPress UniversityThe WordPress University
The WordPress University
 
WordPress Hidden Gems (July 2011)
WordPress Hidden Gems (July 2011)WordPress Hidden Gems (July 2011)
WordPress Hidden Gems (July 2011)
 
WordPress Tips and Tricks (DFW Meetup)
WordPress Tips and Tricks (DFW Meetup)WordPress Tips and Tricks (DFW Meetup)
WordPress Tips and Tricks (DFW Meetup)
 
Tricky Migrations
Tricky MigrationsTricky Migrations
Tricky Migrations
 
Importing & Migrating
Importing & MigratingImporting & Migrating
Importing & Migrating
 
WordPress Hidden Gems
WordPress Hidden GemsWordPress Hidden Gems
WordPress Hidden Gems
 
What's New in WordPress 3.0 (for developers)
What's New in WordPress 3.0 (for developers)What's New in WordPress 3.0 (for developers)
What's New in WordPress 3.0 (for developers)
 
I'm with Stupid
I'm with StupidI'm with Stupid
I'm with Stupid
 
Social Media for Researchers
Social Media for ResearchersSocial Media for Researchers
Social Media for Researchers
 
WordPress as a CMS (short version)
WordPress as a CMS (short version)WordPress as a CMS (short version)
WordPress as a CMS (short version)
 
WordPress as a CMS
WordPress as a CMSWordPress as a CMS
WordPress as a CMS
 

Último

New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 

Último (20)

New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 

Keeping It Simple

  • 1. Keeping It Simple (but not stupid) Stephanie Leary, @sleary sillybean.net
  • 3.
  • 5.
  • 6.
  • 8. Prefer Code? function remove_dashboard_widgets() { global $wp_meta_boxes; unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']); // unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']); // unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']); // unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_drafts']); unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']); unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_plugins']); // WordPress Blog unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']); // Other WordPress News unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_secondary']); } add_action('wp_dashboard_setup', 'remove_dashboard_widgets' ); http://gist.github.com/2722692
  • 10.
  • 11. Full Comments On Dashboard
  • 17.
  • 19.
  • 20. List Child Pages // list child pages automatically on empty pages function append_child_pages($content) {    $children = '';    if (is_page() && (empty($content))) {       global $post;       $children = ' <ul class="childpages">'.wp_list_pages('echo=0&title_li=&child_of='. $post->ID).'</ul> ';    }    return $content.$children; } add_filter('the_content','append_child_pages');
  • 21. List Child Pages // child page list shortcode: [children] function child_pages_shortcode() {    global $post;    return '<ul class="childpages">'. " " wp_list_pages('echo=0&depth=0&title_li=&child_of='. " " $post->ID).'</ul>'; } add_shortcode('children', 'child_pages_shortcode');
  • 26. Post Container Warning // Admin Notice on Posts Page add_action('admin_head-post.php', 'postspage_error_notice'); function postspage_error_notice() {     $postspage = get_option('page_for_posts');     if (!empty($postspage))         add_action('admin_notices', 'postspage_print_notices'); } function postspage_print_notices() {     $postspage = get_option('page_for_posts');     // show this only if we're editing the posts page     if (!empty($postspage) && isset($_GET['action']) && $_GET['action'] == 'edit' && $_GET['post'] == $postspage)         echo '<div class="error"><p>This page is a container for the most recent posts. It should always be empty, and you should never edit this page. To add a news item, go to <a href="post- new.php">Posts -- Add New</a>.<p></div>'; } http://gist.github.com/2515588
  • 27. Removing Meta Boxes add_action( 'add_meta_boxes', 'my_remove_post_meta_boxes' ); function my_remove_post_meta_boxes() { " /* Custom fields meta box. */ " remove_meta_box( 'postcustom', 'post', 'normal' ); } justintadlock.com/?p=2898
  • 33.
  • 35. Better 404s • apologetic, personal language • search for words in the bad URL • show search box and sitemap http://gist.github.com/2723096
  • 36. 404.php (1) " <h2>I'm sorry. I couldn't find the page you requested.</h2> " <?php " $options = us2011_get_options(); " if (!empty($options['problem_report'])) " " $report = 'If you still can't find it, <a href="'.get_permalink($options['problem_report']).'">please let us know what you were looking for,</a> and maybe we can find it for you!'; " if (!empty($options['sitemap'])) " " $sitemap = ' or looking for it in the <a href="/ sitemap">site map</a>'; " ?> " <p>You can try searching for it<?php echo $sitemap; ?>. " <?php echo $report; ?></p> " <?php get_template_part( 'searchform' ); ?>
  • 37. 404.php (2) " <?php " global $wp_query; " $wp_query->query_vars['is_search'] = true; " $s = str_replace("-"," ",$wp_query->query_vars['name']); " $loop = new WP_Query('post_type=any&s='.$s); " ?> " <?php if ($loop->have_posts()) : ?> " " <p>I'm searching for the name of the page you tried to visit... was it one of these?</p> " " <ol> " " <?php while ($loop->have_posts()) : $loop->the_post(); ?> " " " <li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a> " " " " <?php the_excerpt(); ?> " " " </li> " " <?php endwhile; ?> " " </ol> "<?php endif; ?>
  • 38. RSS?
  • 39.
  • 40. “Report a problem” • More likely to be used than “contact” • Automatically fill in referring URL • Link in theme footer
  • 42. How do you keep it simple?
  • 43. Thanks! @sleary sillybean.net

Notas del editor

  1. First I&amp;#x2019;m going to talk about simplifying the admin screens for your users, and then I&amp;#x2019;ll talk about some things we can do to make life easier for our readers.\n
  2. \n
  3. The Dashboard: the first thing everyone sees when they log in, and the least useful screen there is. How many of us have gotten into the habit of skipping this -- of bookmarking the post or page edit screen instead? The Dashboard doesn&amp;#x2019;t have to suck, but we&amp;#x2019;re going to have to put a little effort into un-sucking it.\n
  4. \n
  5. Now we&amp;#x2019;re down to the things that are useful for everyone: comments and recent drafts. If you&amp;#x2019;ve disabled comments sitewide, blow that one away. If you&amp;#x2019;re not using Posts, QuickPress is useless, so get rid of that too!\n
  6. Adminimize has a TON of other options. Its settings screen is one of the longest I&amp;#x2019;ve ever seen.\n
  7. Dashboard Commander is a less intimidating plugin for accomplishing the same thing. Its settings are a little quirky, though: it asks you to set a minimum capability for each Dashboard widget.\n
  8. \n
  9. Now that we&amp;#x2019;ve gotten rid of the junk, let&amp;#x2019;s ADD something useful. The CMS Dashboard widget provides big, fat buttons to the most important admin screens. These should be easy to click if you&amp;#x2019;re trying to manage your site from a touch screen.\n
  10. Now we&amp;#x2019;re getting somewhere! But wait... that comment widget is still pretty useless. Even the starter comment is too long to be displayed in full.\n
  11. Scribu&amp;#x2019;s Full Comments on Dashboard plugin does exactly what it says. There are no settings. You just activate it, and the Dashboard plugin shows the full comment text.\n
  12. Lastly, I&amp;#x2019;m going to recommend one of my own plugins. Dashboard Notepad is a simple way to leave reminders for yourself or your users.\n
  13. The widget screen drives me nuts! Sites do more than just sidebars with widgets, and the stacked boxes on the widget screen don&amp;#x2019;t make sense to users. I started playing around with the admin CSS to see if I could override it and do something better. In 3.2, I couldn&amp;#x2019;t do much more than make them wider...\n
  14. But in 3.3, the sidebar boxes have unique IDs, which means you can hook into the admin CSS and move them around. Careful, though -- this requires absolute positioning, and the boxes start to overlap if you have too many widgets in a single sidebar. See the ticket for sample CSS file and hooks in the functions.php.\n
  15. \n
  16. Hierarchy is a somewhat new plugin. It gives you a menu item called Content right under the Dashboard, and the Content screen shows you a combined list of all your custom post types. On the settings page for the plugin, you can arrange the post types&amp;#x2019; order in the list and turn off their menu items.\n
  17. If they&amp;#x2019;re non-hierarchical, you&amp;#x2019;ll just see a link to the Edit screen for that post type.\n\nThe author of this plugin, Jonathan Christopher, also has a book called Client Oriented WordPress Development. It&amp;#x2019;s fairly good.\n\nWithin the pages, though, it&amp;#x2019;s still a pain to change their order! After all this time!\n
  18. Simple Page Ordering is the easiest way I&amp;#x2019;ve found to rearrange pages. The entire table row becomes grabbable, and you can drag the pages around. You can&amp;#x2019;t change their hierarchy, though -- you&amp;#x2019;ll still have to use Quick Edit to set the parent page.\n
  19. It even works in the media uploader!\n
  20. A big problem I always have with page-centric sites is that there&amp;#x2019;s usually more than one empty container page -- a page that&amp;#x2019;s just there to build the hierarchy. It doesn&amp;#x2019;t need to contain any content. It just needs to link to its child pages. So I&amp;#x2019;ve built a mini-plugin that I use on almost all my sites. It lists the child pages on any page without content, and it provides a shortcode so we can embed the list on other pages as needed. Here&amp;#x2019;s the filter for the empty pages...\n
  21. ... and here&amp;#x2019;s the shortcode.\n\nShortcodes themselves are problematic, though, and that leads me to the problems with the writing screens.\n
  22. Really, the writing screens are outstanding. It seems silly to quibble here, when I go around telling everyone that this is the best feature of WordPress. However...\n
  23. Once you start adding plugins, it&amp;#x2019;s easy to forget which shortcodes are available, or what they all do. The Shortcode Reference plugin adds a box that reminds you.\n
  24. A lot of my users have a hard time with the Gallery. They don&amp;#x2019;t realize that a post sometimes already has attachments, and they upload duplicates. Then they can&amp;#x2019;t remember how to get back to those files and insert them into the post. Bill&amp;#x2019;s Gallery Metabox plugin adds thumbnails of the uploaded images right on the editing screen. You can drag them into the post to insert them.\n
  25. Here&amp;#x2019;s another thing some of my users can&amp;#x2019;t ever remember, especially on sites that don&amp;#x2019;t use the posts much. When we&amp;#x2019;ve chosen a page to display the most recent posts, there&amp;#x2019;s this empty page floating around, and users forget that they can&amp;#x2019;t edit this page to add a new post! I&amp;#x2019;ve written a little function to warn them that they&amp;#x2019;re in the wrong place, and give them a link to the new post screen.\n
  26. The code isn&amp;#x2019;t complicated; it&amp;#x2019;s just long because there&amp;#x2019;s a whole paragraph of text in there. Grab the Gist if you want to use it.\n
  27. Now that we&amp;#x2019;ve added a bunch of stuff, let&amp;#x2019;s take some stuff away! As of 3.1, most of the meta boxes are hidden by default, and you have to go to Screen Options to turn them on. I love this. It&amp;#x2019;s made things so much simpler for my users. But every now and then, there&amp;#x2019;s a box I want to take away from them altogether -- like Custom Fields. I always want users to manage those using a custom meta box. Justin Tadlock has written a nice little tutorial on removing meta boxes. He gives you the names of all the built-in boxes, but here I&amp;#x2019;m just removing custom fields.\n
  28. \n
  29. A lot of the sites I manage have a need for reusable bits of code, and widgets aren&amp;#x2019;t always the right solution -- what if you need to embed the code in the middle of a post? There are two plugins I like to solve this problem, Post Snippets and Raw HTML Snippets. I think this one is a little easier to use. Enter your HTML, then use the shortcode to place it wherever you need it.\n
  30. Let&amp;#x2019;s talk about email! WordPress sends out a lot of notifications -- comments awaiting moderation, etc. -- but there&amp;#x2019;s one thing it doesn&amp;#x2019;t do, and it drives me bonkers. It doesn&amp;#x2019;t alert editors or administrators when a contributor&amp;#x2019;s post is pending review.\n
  31. This plugin lets you choose who should receive notifications about pending posts. There&amp;#x2019;s a companion plugin, Peter&amp;#x2019;s Post Notes, that will let you add remarks to the notifications, so if you&amp;#x2019;re rejecting a contributed post, you can mention why.\n
  32. Notifly is a great little plugin when you want a lot of users to subscribe to post AND comment notifications. Notifly sends out a message for everything that gets posted.\n
  33. This little plugin lets users know when they&amp;#x2019;ve fallen into your spam trap.\n
  34. What else can we do to make life better for visitors?\n
  35. \n
  36. A 404 error is the most frustrating thing for a visitor, and there&amp;#x2019;s a lot we can do besides showing them a joke or a game.\n
  37. \n
  38. \n
  39. How many of us are still putting up RSS icons without explaining what RSS is? And yet it&amp;#x2019;s still not widely adopted outside the tech industry.\n
  40. On this site, we linked the question to a long explanation that I wrote, but you could like to Wikipedia or any other site that describes how to subscribe to a feed.\n
  41. \n
  42. \n
  43. \n
  44. \n