the_title();
        ?>
</h3>
                                            <p>Спектакль</p>
                                        </div>
                                    </div>
                                </a>
						    </div>

						    <div class="event-block-content">
						<?php 
        $countrows = $wpdb->get_row("SELECT count(*) as countevent FROM {$wpdb->postmeta} WHERE 1 AND post_id = '{$eventId}' AND meta_key LIKE 'event_date_%'");
        if (intval($countrows->countevent) > 0) {
            for ($counter = 0; $counter < intval($countrows->countevent); $counter++) {
                echo '<div class="col-xs-6 col-sm-6 col-md-6 col-lg-6 date">';
                echo '<span><strong>' . get_post_meta($eventId, 'event_date_' . $counter, true) . '</strong>&nbsp;' . the_russian_time(monthName(get_post_meta($eventId, 'event_month_' . $counter, true))) . '&nbsp;' . get_post_meta($eventId, 'evnt_time_start_hours_0', true) . ':' . get_post_meta($eventId, 'evnt_time_start_minutes_0', true) . '&nbsp;' . get_post_meta($eventId, 'event_start_time_0', true) . '</span>';
                echo '</div>';
            }
        }
        ?>
        						<div class="clearfix"></div>
						        <p><?php 
        the_excerpt();
        ?>
</p>
						    </div>
							<div class="bg-expire-3 text-center">
                            	
                                <?php 
        if ($numbusinessDays > 0) {
            ?>
Exemple #2
0
function formatDate($date, $short = 0)
{
    $year = substr($date, 0, 4);
    $month = substr($date, 5, 2);
    $day = substr($date, 8, 2);
    $day = sprintf('%d', $day);
    if ($date) {
        return $day . '&nbsp;' . monthName(intval($month), $short) . '&nbsp;' . $year;
    }
}
Exemple #3
0
    /**
     * Get USER AGE
     * return Age;
     */
    public function getAge($show = "")
    {
        $this->setRquery("SELECT pDOBD,pDOBM,pDOBY  FROM amistiPersonal WHERE userID=?", array($this->UID));
        $res = $this->getRquery();
        $id = $this->UID;
        if (!$res[0]['pDOBD'] == NULL) {
            $age = getUserAge($res[0]['pDOBD'], $res[0]['pDOBM'], $res[0]['pDOBY']);
            $age .= " years";
            $birthD .= addZero($res[0]['pDOBD']) . " " . numberToMonth($res[0]['pDOBM']);
            $ageInfo = $this->UID == UID ? "Your age information:" : $this->uName . " age information:";
            ?>
				<div class="pProfileICHeader"> Age Information:</div>
				<?php 
            if ($this->UID == UID) {
                //check if it same as cur user
                ?>
				<div class="pProfileMenuShow">...</div>
				<!--- menu -->
				<div class="pProfileMenu">
				<li id="ageEdit">Edit</li>
				<li id="ageDelete">Delete</li>
				</div>
				<?php 
            }
            ?>
				<div class="pProfileItem">
                <table> 
                <tr><td>Date of Birth </td><td>: <?php 
            echo $birthD;
            ?>
</td></tr>
				<tr><td> Age </td><td>: <?php 
            echo $age;
            ?>
 </td></tr>
               </table>
               
                </div>

				<?php 
        } else {
            if ($this->UID == UID) {
                if ($show == true) {
                    ?>
				<div class="pProfileICHeader"> Age:</div>
				<div class="pProfileItem pProfileBack">
                         
                          <table>
                          <tr><td> Day </td><td><?php 
                    echo monthDay();
                    ?>
</td></tr>
                          
						  <tr><td>Month</td><td><?php 
                    echo monthName();
                    ?>
</td></tr>
                          <tr><td>Year</td><td><?php 
                    echo ageYear();
                    ?>
</td></tr>
                          <tr><td colspan="2">
                               <input type="submit" id="ageClear" value="Cancel"> 
                          	   <input type="submit" id="ageSave" value="Save">
                               </td></tr>
                          </table>
                </div>
				
				<?php 
                } else {
                    ?>
						   <div class="pProfileICHeader"> Age:</div>  
                           <div class="pProfileItem pGender">
                           <div class="addProfile" id="ageAdd"> Add Date of Birth</div>
                           </div>
                             <?php 
                }
            } else {
                ?>
				<div class="pProfileICHeader"> Age Information:</div>
				<div class="pProfileItem pProfileItemNon">
                <?php 
                echo $this->fName . " " . $this->sName . " has not updated age information.";
                ?>
                </div>
				
						
						<?php 
            }
        }
    }
Exemple #4
0
 }
 $req = Sql_Query($item['query']);
 $ls = new WebblerListing('');
 $chartData = array();
 $collation = 0;
 while ($row = Sql_Fetch_Assoc($req)) {
     if (!isset($chartData[$row['year']]) || !is_array($chartData[$row['year']])) {
         $chartData[$row['year']] = array();
     }
     if ($item['collate']) {
         $collation = $collation + $row['num'];
         $row['num'] = $collation;
     }
     if ($item['range'] != 'year') {
         $ls->addElement($row['year'] . ' ' . monthName($row['month']));
         $ls->addColumn($row['year'] . ' ' . monthName($row['month']), '#', $row['num']);
         $chartData[$row['year']][$row['month']] = $row['num'];
     } else {
         $ls->addElement($row['year']);
         $ls->addColumn($row['year'], '#', $row['num']);
         $chartData[$row['year']][''] = $row['num'];
     }
     if (!empty($row['year']) && !empty($row['month']) && !empty($row['num'])) {
         cl_output($item['name'] . '|' . $row['year'] . '|' . $row['month'] . '|' . $row['num']);
     }
 }
 unset($chartData['2000']);
 unset($chartData['2001']);
 unset($chartData['2002']);
 unset($chartData['2003']);
 unset($chartData['2004']);
Exemple #5
0
function _addMonth($year, $month)
{
    return array(($month > 9 ? '' : '0') . $month . $year, monthName($month) . ' ' . $year);
}
Exemple #6
0
                  </div>
                  <div class="widget-body">
                              <form action="reports.php" method="post">
                                <label for="month" class="width_fix">মাস সিলেক্ট করুন</label>
                                <select name="month" id="month">
                                  <?php 
include "monthName.php";
echo "<option value=\"" . date('m') . "\" selected=\"selected\">" . monthName(date('m')) . "</option>";
for ($month = 1; $month <= 12; $month++) {
    $datestring = $month;
    if ($month < 10) {
        $month_string = '0' . $month;
        echo "<option value=\"" . $month_string . "\">" . monthName($month_string) . "</option>";
    } else {
        $month_string = $month;
        echo "<option value=\"" . $month_string . "\">" . monthName($month_string) . "</option>";
    }
}
?>
                                </select>
                                <input type="submit" class="btn-info btn" value="দেখুন">
                              </form>          
                      <table class="table table-condensed table-striped table-hover table-bordered" >
                        
                        <thead>
                          <tr>
                            <th>তারিখ</th>
                            <th>বিক্রি </th>
                            <th>তাগাদা</th>
                            <th>ব্যাংক জমা</th>
                            <th>স্টাফ খরচ</th>
                <!-- <p><?php 
        //echo get_excerpt();
        ?>
</p> -->
                <p class="location text-left"><?php 
        echo mb_strimwidth($evLocation['address'], 0, 60, '...');
        ?>
, OR</p>
              </div>
			  
              <div class="bg-primary">
				<?php 
        $countrows = $wpdb->get_row("SELECT count(*) as countevent FROM {$wpdb->postmeta} WHERE 1 AND post_id = '{$eventId}' AND meta_key LIKE 'event_date_%'");
        if (intval($countrows->countevent) > 0) {
            for ($counter = 0; $counter < intval($countrows->countevent); $counter++) {
                echo '<strong class="data">' . get_post_meta($eventId, 'event_date_' . $counter, true) . '&nbsp;' . the_russian_time(monthName(get_post_meta($eventId, 'event_month_' . $counter, true))) . '&nbsp;' . date("Y") . '</strong>&nbsp;';
            }
        }
        ?>
			  </div>
			  
              <p class="bg-primary">
			  	<span>
					<?php 
        $terms = get_the_terms($eventId, 'event_cat');
        if ($terms) {
            $out = array();
            foreach ($terms as $term) {
                $out[] = $term->name;
            }
            echo join(', ', $out);
// Start a new list to print the TRENDING EVENTS
foreach ($xml_rush->Showing as $showing) {
    // Save the SELECTED attributes for each EVENT, in PHP variables
    $originalName = $showing->Name;
    if (strlen($originalName) > $nameLength) {
        $Name = substr($originalName, 0, $nameLength) . "...";
    } else {
        $Name = $originalName;
    }
    $TabletLink = $showing->TabletLink;
    $StartDate = $showing->StartDate;
    $VenueName = $showing->VenueName;
    // Separate date and time
    $dateTime = dateTimeToArray($StartDate);
    // Convert the date and time in MM/DD HH:MM (12-hour) format
    $month = monthName($dateTime[1]);
    $day = $dateTime[2];
    $hour = $dateTime[3];
    if ($hour < 12) {
        $ampm = "AM";
    } else {
        if ($hour > 12) {
            $ampm = "PM";
            $hour = $hour - 12;
        } else {
            if ($hour == 12) {
                $ampm = "PM";
            }
        }
    }
    $min = $dateTime[4];
function todaysdate_en($givendate)
{
    //echo date('Y-m-d');
    $parts = @explode("-", $givendate);
    //echo BanglaNum($parts[2]."/".$parts[1]."/".$parts[0])." &#2468;&#2494;&#2480;&#2495;&#2454; ";
    echo monthName($parts[1]) . " " . $parts[2] . ", " . $parts[0];
}
Exemple #10
0
                        }
                    }
                }
            }
            foreach ($listed_categ as $index => $categ) {
                if ($purchase_memos['factory_name'] == $categ) {
                    $categ_exp_count++;
                    $categ_exp[$index] = $categ_exp[$index] + $purchase_memos['paid'];
                }
            }
        }
    }
    $bikri = $bikri - $bank_joma;
    //reducing the bank joma from general sells
    if ($bikri != 0 || $tagada != 0 || $staff_exp != 0 || $categ_exp_count) {
        $monthName = monthName($month);
        echo "<tr>\n                                          <td>{$monthName}</td>\n                                          <td>{$bikri}</td>\n                                          <td>{$tagada}</td>\n                                          <td>{$bank_joma}</td>\n                                          <td>{$staff_exp}</td>";
        //make room for marked items
        foreach ($listed_categ as $index => $categ) {
            echo "<td>{$categ_exp[$index]}</td>";
        }
        echo "<td>{$other_exp}</td>\n                                        </tr>";
    }
}
?>
                        </tbody>
                      </table>
                  </div>
                </div>
              </div>
              
Exemple #11
0
<?php
$list = '<div id="content" class="corners"><h2>Senaste träningarna!</h2>'; if(isset($pages)) { echo $pages; }

foreach($events as $event) {
	$splitdate = splitDate($event['date']);
	$list .= '
		<div class="event">
			<h3>Av '.$event['uname'].'</h3>
			<p class="calendar">'.$splitdate['day'].'<em>'.monthName($splitdate['month']).'</em></p>
			<p>Träningstid: '.$event['time'].'min.</p>
			<p>Träningstyp: '.$event['ename'].'</p>
			<p>Egen Kommentar: '.$event['comment'].'</p>';
	if($event['uid'] == $_SESSION['id'] ) {
		$list .= '<p>
			<a href="event/edit/'.$event['id'].'"><button class="button buttonsmall" >Ändra</button></a>
			<a href="event/delete/'.$event['id'].'"><button class="button clickable buttonsmall" >Ta bort</button></a>
			</p>';
	}
	$list .= '</div>
				<br /><hr style="float:left;" width="100%" size="3" /><br />';
}
echo $list;
if(isset($pages)) { echo $pages; }
echo '</div>';
Exemple #12
0
function formatDateComplete($a, $dayFormat = 1, $monthFormat = 1, $sep = '/')
{
    $vr['date'] = $a;
    if ($a == '0000-00-00' || $a == '0000-00-00 00:00:00') {
        return $vr['date'] = '';
    }
    if (!is_validDbDate($a)) {
        return $vr;
    }
    $e = explode(' ', $a);
    $vr['time'] = isset($e[1]) ? $e[1] : '';
    $r = list($y, $m, $d) = explode('-', $a);
    $a = mktime(0, 0, 0, $m, $d, $y);
    $human_month = monthName();
    $human_month_s = monthNameS();
    $settimana = weekDays();
    $settimana_s = weekDaysS();
    $intday = date('w', $a);
    if ($dayFormat == 1) {
        $wday = $settimana_s[$intday];
    } else {
        $wday = $settimana[$intday];
    }
    $day = date('d', $a);
    $intmonth = date('n', $a);
    if ($monthFormat == 1) {
        $month = $human_month[$intmonth];
    } else {
        $month = $human_month_s[$intmonth];
    }
    $year = date('Y', $a);
    //if($day<10) $day="0".$day;
    if ($intmonth < 10) {
        $intmonth = "0" . $intmonth;
    }
    $vr['date'] = $day . $sep . $intmonth . $sep . $year;
    $vr['stringdate'] = $wday . " " . $day . " " . $month . " " . $year;
    return $vr;
}
Exemple #13
0
            $numberOfDaysPerMonth = "30";
            break;
        case "02":
            leapYear($year) ? $numberOfDaysPerMonth = "29" : ($numberOfDaysPerMonth = "28");
            break;
    }
    return $numberOfDaysPerMonth;
}
$fecha = $_POST['fecha'];
$fecha = explode("/", $fecha);
$day = $fecha[0];
$month = $fecha[1];
$year = $fecha[2];
$maxDays = daysPerMonth($month, $year);
if ($day > $maxDays) {
    echo "La fecha es incorrecta, " . monthName($month) . " tiene " . $maxDays . " d&iacuteas";
} elseif ($day <= 0) {
    echo "La fecha es incorrecta, los meses tienen d&iacuteas";
} else {
    $actual = getdate();
    $today = $actual['mday'];
    $thisMonth = $actual['mon'];
    $thisYear = $actual['year'];
    $edad = $thisYear - $year;
    $birthday = false;
    if ($year > $thisYear) {
        echo "Todav&iacutea no has nacido?Vuelve a probar...";
    } else {
        if ($month > $thisMonth) {
            $edad = $edad - 1;
        } elseif ($month == $thisMonth && $day > $today) {