{"id":9342,"date":"2010-06-06T17:56:12","date_gmt":"2010-06-06T17:56:12","guid":{"rendered":"https:\/\/wordpress.org\/plugins-wp\/simple-timed-plugin\/"},"modified":"2017-11-20T16:22:16","modified_gmt":"2017-11-20T16:22:16","slug":"simple-timed-plugin","status":"closed","type":"plugin","link":"https:\/\/wordpress.org\/plugins\/simple-timed-plugin\/","author":307954,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.2.5","stable_tag":"1.2.5","tested":"4.9.29","requires":"4.6","requires_php":"5.3","requires_plugins":"","header_name":"Timed Content","header_author":"David Artiss","header_description":"","assets_banners_color":"b5b9ac","last_updated":"2017-11-20 16:22:16","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/wordpress.org\/plugins\/simple-timed-plugin\/","header_author_uri":"https:\/\/artiss.blog","rating":5,"author_block_rating":0,"active_installs":100,"downloads":9582,"num_ratings":0,"support_threads":1,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","changelog","faq"],"tags":[],"upgrade_notice":{"1.2.5":"<ul>\n<li>A number of maintenance changes<\/li>\n<\/ul>"},"ratings":{"1":0,"2":0,"3":0,"4":0,"5":"4"},"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":"1645638","resolution":"128x128","location":"assets"},"icon-256x256.png":{"filename":"icon-256x256.png","revision":"1645640","resolution":"256x256","location":"assets"}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":"1645637","resolution":"1544x500","location":"assets"},"banner-772x250.png":{"filename":"banner-772x250.png","revision":"1645636","resolution":"772x250","location":"assets"}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.0","1.1","1.1.1","1.2","1.2.1","1.2.2","1.2.3","1.2.4","1.2.5"],"block_files":[],"assets_screenshots":[],"screenshots":[]},"plugin_section":[],"plugin_tags":[529,1358,9501,955,24108],"plugin_category":[],"plugin_contributors":[78579],"plugin_business_model":[],"class_list":["post-9342","plugin","type-plugin","status-closed","hentry","plugin_tags-content","plugin_tags-date","plugin_tags-expire","plugin_tags-start","plugin_tags-timed","plugin_contributors-dartiss","plugin_committers-codedart","plugin_committers-dartiss"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/s.w.org\/plugins\/geopattern-icon\/simple-timed-plugin_b5b9ac.svg","icon_2x":false,"generated":true},"screenshots":[],"raw_content":"<!--section=description-->\n<p>Adds a shortcode and function allowing you to force the contents of a post or page to appear or expire after a specific date, day and\/or time.<\/p>\n\n<p>Technical specifications include...<\/p>\n\n<ul>\n<li>Licensed under <a href=\"http:\/\/wordpress.org\/about\/gpl\/\" title=\"GNU General Public License\">GPLv2 (or later)<\/a><\/li>\n<li>Designed for both single and multi-site installations<\/li>\n<li>PHP7 compatible<\/li>\n<li>Fully internationalized, ready for translations. <strong>If you would like to add a translation to this plugin then please head to the <a href=\"https:\/\/translate.wordpress.org\/projects\/wp-plugins\/simple-timed-plugin\" title=\"Translating WordPress\">Translating WordPress<\/a> page<\/strong><\/li>\n<li>WCAG 2.0 Compliant at AA level<\/li>\n<\/ul>\n\n<p>Please visit the <a href=\"https:\/\/github.com\/dartiss\/timed-content\" title=\"Github\">Github page<\/a> for the latest code development, planned enhancements and known issues.<\/p>\n\n<h3>How to Use<\/h3>\n\n<p>After installation use the shortcode <code>[timed]<\/code> around any post or page contents that you wish to appear or expire on a specific date and\/or time.<\/p>\n\n<p>Six parameters can be used - <code>ondate<\/code>, <code>offdate<\/code>, <code>ontime<\/code>, <code>offtime<\/code>, <code>onday<\/code> and <code>offday<\/code>.<\/p>\n\n<p><strong>ondate<\/strong> : Date after which you wish the content to appear, in format YYYYMMDD.<\/p>\n\n<p><strong>offdate<\/strong> : Date after which you wish the content to expire, in format YYYYMMDD.<\/p>\n\n<p><strong>ontime<\/strong> : Time after which you wish the content to appear, in format HHMM.<\/p>\n\n<p><strong>offtime<\/strong> : Time after which you wish the content to expire, in format HHMM.<\/p>\n\n<p><strong>onday<\/strong> : Day on which you wish the content to appear - 1 (for Monday) through 7 (for Sunday)<\/p>\n\n<p><strong>offday<\/strong> : Day on which you wish the content to expire - 1 (for Monday) through 7 (for Sunday)<\/p>\n\n<p>If any of these aren't specified then a logical alternative is found - e.g. not specifying <code>ondate<\/code> or <code>ontime<\/code> means the text will appear immediately (until the conditions of any expiry date\/time is met).<\/p>\n\n<p>Here's some examples of use..<\/p>\n\n<pre><code>[timed offdate=\"20122412\"]It's nearly Christmas![\/timed]\n<\/code><\/pre>\n\n<p>This will cause the message to disappear after the 24th December 2012.<\/p>\n\n<pre><code>[timed ondate=\"20120101\" offdate=\"20121231\"]It's 2012[\/timed]\n<\/code><\/pre>\n\n<p>This will cause the message to only appear during the year 2012.<\/p>\n\n<pre><code>[timed ondate=\"20120101\" offdate=\"20121231\" ontime=\"0800\" offtime=\"1200\"]It's between 8am and midday[\/timed]\n<\/code><\/pre>\n\n<p>This will cause the message to appear between 8am and midday during the year 2012.<\/p>\n\n<pre><code>[timed onday=\"1\" offday=\"3\"]It's Monday to Wednesday[\/timed]\n<\/code><\/pre>\n\n<p>This will cause the message to only appear Monday, Tuesday and Wednesday.<\/p>\n\n<h3>Function Call<\/h3>\n\n<p>If you wish to use this facility elsewhere in your theme - e.g. your sidebar - then you can do by calling a PHP function.<\/p>\n\n<p>It uses the same parameters as above, each separated by an ampersand.<\/p>\n\n<p>For example...<\/p>\n\n<pre><code>timed_content(ondate=20120101&amp;offdate=20121231);\n<\/code><\/pre>\n\n<p>This will return either TRUE or FALSE depending on whether the content should be displayed or not. So, a full example may be...<\/p>\n\n<pre><code>&lt;?php if ( function_exists( 'timed_content' ) ) : ?&gt;\n&lt;?php if ( timed_content( 'ondate=20120101&amp;offdate=20121231' ) ) : ?&gt;\nSome content goes here\n&lt;?php endif; ?&gt;\n&lt;?php endif; ?&gt;\n<\/code><\/pre>\n\n<p>This will only display the content if it's any date during the year 2012.<\/p>\n\n<h3>Acknowledgements<\/h3>\n\n<p>Thanks to Jeff Kereakoglow for the <code>onday<\/code> and <code>offday<\/code> suggestions, as well as pointing out the bug with the time.<\/p>\n\n<!--section=installation-->\n<p>Timed Content can be found and installed via the Plugin menu within WordPress administration (Plugins -&gt; Add New). Alternatively, it can be downloaded from WordPress.org and installed manually...<\/p>\n\n<ol>\n<li>Upload the entire <code>simple-timed-plugin<\/code> folder to your <code>wp-content\/plugins\/<\/code> directory.<\/li>\n<li>Activate the plugin through the 'Plugins' menu in WordPress administration.<\/li>\n<\/ol>\n\n<p>Voila! It's ready to go.<\/p>\n\n<!--section=changelog-->\n<p><a href=\"https:\/\/artiss.blog\/2016\/09\/wordpress-plugin-versioning\/\" title=\"WordPress Plugin Versioning\">Learn more about my version numbering methodology<\/a><\/p>\n\n<h4>1.2.5<\/h4>\n\n<ul>\n<li>Maintenance: Corrected links to my site<\/li>\n<li>Maintenance: Changes to README file to reflect the new plugin directory format<\/li>\n<li>Enhancement: Minimum WordPress level is now 4.6. This means that I can remove a lot of the internationalization options, which are now automated<\/li>\n<li>Enhancement: Now using Yoda conditions throughout the code<\/li>\n<\/ul>\n\n<h4>1.2.4<\/h4>\n\n<ul>\n<li>Enhancement: Who forgot to add code to actually load the translations? Yes, that was me. Sorry. Now done.<\/li>\n<li>Maintenance: Added a text domain and domain path.<\/li>\n<\/ul>\n\n<h4>1.2.3<\/h4>\n\n<ul>\n<li>Maintenance: Tiny, tiny change but one with big impact. Some users were getting prompts to update to a totally different plugin - same name, different author, not as good. That's now sorted.<\/li>\n<\/ul>\n\n<h4>1.2.2<\/h4>\n\n<ul>\n<li>Enhancement: Added internationalisation<\/li>\n<\/ul>\n\n<h4>1.2.1<\/h4>\n\n<ul>\n<li>Maintenance: Corrected support forum link<\/li>\n<\/ul>\n\n<h4>1.2<\/h4>\n\n<ul>\n<li>Maintenance: Brought code quality up-to-date<\/li>\n<li>Maintenance: README updated<\/li>\n<li>Enhancement: Allow a shortcode to be used with the content<\/li>\n<li>Enhancement: Added meta links to plugin screen entry<\/li>\n<\/ul>\n\n<h4>1.1.1<\/h4>\n\n<ul>\n<li>Fixed bug causing timings to not operate correctly<\/li>\n<\/ul>\n\n<h4>1.1<\/h4>\n\n<ul>\n<li>Use local time rather than server time<\/li>\n<li>Add <code>onday<\/code> and <code>offday<\/code> parameters<\/li>\n<li>Added function call to allow timed content in other areas of theme<\/li>\n<li>Re-written (and simplified) logic that decides if content should be shown or not<\/li>\n<li>Minor changes and enhancements<\/li>\n<\/ul>\n\n<h4>1.0<\/h4>\n\n<ul>\n<li>Initial release<\/li>\n<\/ul>\n\n<!--section=faq-->\n<dl>\n<dt>Installation Instructions<\/dt>\n<dd><p>Timed Content can be found and installed via the Plugin menu within WordPress administration (Plugins -&gt; Add New). Alternatively, it can be downloaded from WordPress.org and installed manually...<\/p>\n\n<ol>\n<li>Upload the entire <code>simple-timed-plugin<\/code> folder to your <code>wp-content\/plugins\/<\/code> directory.<\/li>\n<li>Activate the plugin through the 'Plugins' menu in WordPress administration.<\/li>\n<\/ol>\n\n<p>Voila! It's ready to go.<\/p><\/dd>\n\n<\/dl>","raw_excerpt":"Force post or page content to appear or expire.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/9342","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=9342"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/dartiss"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=9342"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=9342"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=9342"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=9342"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=9342"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=9342"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}