daily gadgets, computers, and electronic news
21/04
2005

CA-Weekday

Sponsored Links

My second simple plugin :) I decided to remove the weekday function from CA-Weton and made it as individual plugin called CA-Weekday. Since today I just learn how to add an option page for plugin, this one support weekday name modification through Option page :D

Automatic Installation
CA-Weekday supports automatic installation through WP Plugin Manager. Click here for more info.

Manual Installation

  • Download the plugin from here or copy the code directly from the next page and save it as ca_weekday.php.
  • Extract the file and upload ca_weekday.php into your WordPress’ plugins directory (../wp-contents/plugins)
  • Activate the plugin from Admin’s Plugin page
  • A new sub-option is now available on your Admin’s Option page. Go there to customized the weekday name.
  • Modify your theme pages with the syntax below to display custom weekday.

Usage Syntax

  • function ca_weekday($before, $after, $tipe, $print, $current)
    • Purpose: Display custom weekday name
    • Parameter:
      • $before: Text displayed before weekday name
      • $after: Text displayed after weekday name
      • $tipe: Type of input date. Default is 0 (0 = current date | 1 = post date | 2 = comment date)
      • $print: Boolean (true/false). If true, output will be print directly to screen. If false, output is returned and must be print manually. Default is TRUE.
      • $current: Specific date input in UNIX time-stamp format. You can use mktime function to create one.
        Example: $cur = mktime(0,0,0,2,16,2005);
        Default is NULL (you don’t need to input anything, plugin will handle it automatically based on $tipe parameter)
    • Usage:
      Display weekday name for current date
      [php]< ?php ca_weekday('Today is ',''); ?>[/php]
      Display weekday name for post date (put inside The Loop)
      [php]< ?php ca_weekday('(',')',1); ?>[/php]

Version History

  • v0.2 (April 29th, 2005) : Now works with comments date
  • v0.1 (April 20th, 2005) : Initial release

To Do

  • Comment date support

See a working demo right on top of this page, under the post’s title :d

Pages: 1 2

AddThis Social Bookmark Button
 

2 Comments »

  1. 1
    WP Plugins DB » Blog Archive » CA-Weekday says:

    […] Visit […]

  2. 2
    [DGN] Our Best Picks - April 2005 | Funponsel Network says:

    […] other people’s plugins, I did create my own plugins as well. For example: CA-Weton, CA-Weekday, CA-Credits, and […]

Leave a comment

 
Additional information for CA-Weekday
Tags/Categories: Programming, WordPress , ,
Search Terms: php show weekday,dealova-once-lirik lagu,current weekday date php,lagu dealova-once,"lirik+DEALOVA",weekday php,php show weekday from a date,php display a weekday date,how to find week day name by date in php,free download lagu dealova-once,lirik dealova-once,date in php for weekday,unix: display weekday,lirik lagu fruit basket,CA-weekday,php weekday,php print weekday names,once lirik,lirik lagu dealova,php week day names,