Login   Register  
PHP Classes
elePHPant
Icontem

File: test.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Edwin F. Sturt  >  Fiscal Year Date Check  >  test.php  >  Download  
File: test.php
Role: Example script
Content type: text/plain
Description: Demo
Class: Fiscal Year Date Check
Check if a date is in the same year of another
Author: By
Last change: function Correction
Date: 2 years ago
Size: 1,283 bytes
 

Contents

Class file image Download
<?php
/**********************************************************************
    Copyright (C) Sturt Community.
    Released under the terms of the GNU General Public License, GPL, 
    as published by the Free Software Foundation, either version 3 
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
    See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
***********************************************************************/
$PATH_TO_FILE="./";

include 
$PATH_TO_FILE."date.inc";

    
// example dates
    
            
$date1="2013-01-02"$date2="2010-01-02";
            
            
$begin="2011-04-01";  $end="2012-03-31"

$date_functions = new date_function_inc();

    
$result1$date_functions->check_fiscal_year($date1,$begin);
    
$result2$date_functions->check_fiscal_year($end,$date2);
    
    if( 
$result1 == || $result2 == )
    {
      
$date_functions->java_alert('Your Condition Here');
    } else {
      
$date_functions->java_alert('date is Ok');
    }

// if Any Queries email me edwinsturt@live.com    


?>