Plugin Directory

Changeset 1210908


Ignore:
Timestamp:
08/01/2015 10:24:02 AM (11 years ago)
Author:
dimitrov.adrian
Message:

Fix code snippet in readme.txt

File:
1 edited

Legend:

Unmodified
Added
Removed
  • scifi-task-manager/trunk/readme.txt

    r1210903 r1210908  
    3131
    3232*Simple example*
    33 `add_filter('scifi-task-manager-priorities', function($priorities) {
    34 `
    35 `
    36 `  // Add custom priority.
    37 `  $priorities[99] = array(
    38 `
    39 `    // Label of the priority
    40 `    'label' => 'Very very critical',
    41 `
    42 `    // Color code
    43 `    'color' => '#ff0000',
    44 `  );
    45 `
    46 `
    47 `  // Remove status.
    48 `  unset($priorities[75]);
    49 `
    50 `  return $priorities;
    51 `});
     33<?php
     34add_filter('scifi-task-manager-priorities', function($priorities) {
     35
     36  // Add custom priority.
     37  $priorities[99] = array(
     38
     39    // Label of the priority
     40    'label' => 'Very very critical',
     41
     42    // Color code
     43    'color' => '#ff0000',
     44  );
     45
     46
     47  // Remove status.
     48  unset($priorities[75]);
     49
     50  return $priorities;
     51});
     52?>
    5253
    5354
     
    5859
    5960*Simple example*
    60 ```
     61<?php
    6162add_filter('scifi-task-manager-statuses', function($statuses) {
    6263
     
    8182  return $statuses;
    8283});
    83 ```
     84?>
    8485
    8586Please be carefull with statuses because some of the task could became *invisible* if you remove status that contain tasks.
Note: See TracChangeset for help on using the changeset viewer.