Esempio n. 1
0
    /**
     * Index Function
     *
     * @return 	string
     */
    public function index()
    {
        // get most recent 10 entries from DB
        $this->_EE->db->select('entry_id, channel_id, name, comment_date');
        $this->_EE->db->from('comments');
        $this->_EE->db->order_by('comment_date DESC');
        $this->_EE->db->limit(10);
        $comments = $this->_EE->db->get();
        // generate table HTML
        $display = '';
        if ($comments->num_rows() > 0) {
            foreach ($comments->result() as $comment) {
                $display .= '
					<tr class="' . alternator('odd', 'even') . '">
						<td><a href="' . BASE . AMP . '">' . $comment->name . '</a></td>
						<td>' . date('m/d/Y', $comment->comment_date) . '</td>
					</tr>';
            }
        } else {
            $display = '<tr><td colspan="2"><center>No comments have been posted.</center></td></tr>';
        }
        return '
			<table>
				<thead><tr><th>Name</th><th>Comment Date</th></tr></thead>
				<tbody>' . $display . '</tbody>
			</table>
		';
    }
Esempio n. 2
0
    /**
     * Index Function
     *
     * @return 	string
     */
    public function index()
    {
        // get most recent 10 entries from DB
        $this->_EE->db->select('entry_id, channel_id, title, entry_date');
        $this->_EE->db->from('channel_titles');
        $this->_EE->db->order_by('entry_date DESC');
        $this->_EE->db->limit(10);
        $entries = $this->_EE->db->get();
        // generate table HTML
        $display = '';
        if ($entries->num_rows() > 0) {
            foreach ($entries->result() as $entry) {
                $display .= '
					<tr class="' . alternator('odd', 'even') . '">
						<td><a href="' . BASE . AMP . 'D=cp' . AMP . 'C=content_publish' . AMP . 'M=entry_form' . AMP . 'channel_id=' . $entry->channel_id . AMP . 'entry_id=' . $entry->entry_id . '">' . $entry->title . '</a></td>
						<td>' . date('m/d/Y', $entry->entry_date) . '</td>
					</tr>';
            }
        } else {
            $display = '<tr><td colspan="2"><center>No entries have been created.</center></td></tr>';
        }
        return '
			<table>
				<thead><tr><th>Title</th><th>Entry Date</th></tr></thead>
				<tbody>' . $display . '</tbody>
			</table>
		';
    }
Esempio n. 3
0
    /**
     * Index Function
     *
     * @return 	string
     */
    public function index()
    {
        // get most recent 10 members from DB
        $this->_EE->db->select('member_id, username, join_date');
        $this->_EE->db->from('members');
        $this->_EE->db->order_by('join_date DESC');
        $this->_EE->db->limit(10);
        $results = $this->_EE->db->get();
        // generate table HTML
        $display = '';
        if ($results->num_rows() > 0) {
            foreach ($results->result() as $row) {
                $display .= '
					<tr class="' . alternator('odd', 'even') . '">
						<td><a href="' . BASE . AMP . 'D=cp' . AMP . 'C=myaccount' . AMP . 'id=' . $row->member_id . '">' . $row->username . '</a></td>
						<td>' . date('n/j/Y', $row->join_date) . '</td>
					</tr>';
            }
        } else {
            $display = '<tr><td colspan="2"><center>No members have joined yet.</center></td></tr>';
        }
        return '
			<table>
				<thead><tr><th>Username</th><th>Join Date</th></tr></thead>
				<tbody>' . $display . '</tbody>
			</table>
		';
    }
Esempio n. 4
0
function foo($x, $k)
{
    foreach ($x as $j) {
        loop:
        echo "{$j}: ";
        echo $k;
        echo "\n";
        if (alternator()) {
            goto loop;
        }
        echo "ok\n";
    }
    echo "done\n";
}
Esempio n. 5
0
?>
		</li>
		<li class="<?php 
echo alternator('even', '');
?>
">
			<label for="captions">Captions</label>
			<?php 
echo form_dropdown('captions', array('true' => 'On', 'false' => 'Off'), $options['captions']);
?>
		</li>
		<li class="<?php 
echo alternator('even', '');
?>
">
			<label for="captions">Theme</label>
			<?php 
echo form_dropdown('theme', array('default' => 'Default', 'bar' => 'Bar', 'dark' => 'Dark', 'light' => 'Light'), $options['theme']);
?>
		</li>
		<li class="<?php 
echo alternator('even', '');
?>
">
			<label for="captions">Settings</label>
			<?php 
echo form_textarea('settings', $options['settings']);
?>
		</li>
	</fieldset>
</ul>
Esempio n. 6
0
			<li class="<?php 
echo alternator('even', '');
?>
">
				<label for="restricted_to[]"><?php 
echo lang('nav:restricted_to');
?>
</label>
				<?php 
echo form_multiselect('restricted_to[]', array(0 => lang('global:select-any')) + $group_options, strpos($link->restricted_to, ",") ? explode(",", $link->restricted_to) : $link->restricted_to, 'size="' . (($count = count($group_options)) > 1 ? $count : 2) . '"');
?>
			</li>
	
			<li class="<?php 
echo alternator('', 'even');
?>
">
				<label for="class"><?php 
echo lang('nav:class_label');
?>
</label>
				<?php 
echo form_input('class', $link->class);
?>
			</li>
		</ul>
	
		<div class="buttons float-left padding-top">
			<?php 
$this->load->view('admin/partials/buttons', array('buttons' => array('save', 'cancel')));
Esempio n. 7
0
			<th>
				<div align="center">
					Space
				</div>
			</th>
			<th>
				<div align="center">
					Actions
				</div>
			</th>
		</tr>
		<?php
		foreach($users->result() as $user)
		{
		?>
			<tr <?=alternator('class="odd"', 'class="even"')?>>
				<td>
					<div align="center">
						<input type="checkbox" id="check-<?php echo $user->id?>" name="users[]" value="<?php echo $user->id?>" />&nbsp;
						<?php echo $user->id?>
					</div>
				</td>
				<td><div align="center"><?php echo $user->id?></div></td>
				<td><div align="center"><?php echo $user->username?></div></td>
				<td><div align="center"><?php echo $user->email?></div></td>
				<td><div align="center"><?php echo $this->functions->getFilesizePrefix($this->files_db->getFilesUseageSpace($user->id))?></div></td>
				<td>
					<div align="center"> 
					    <?php
					    if($user->status == 0 and $user->id != 1)
					    {
Esempio n. 8
0
if ($panels['logs']) {
    ?>
		<div id="debug-log" class="top" style="display: none;">
			<h1>logs &amp; msgs</h1>
			<table cellspacing="0" cellpadding="0">
				<tr align="left">
					<th width="1%">#</th>
					<th width="200">time</th>
					<th width="100">level</th>
					<th>message</th>
				</tr>
				<?php 
    foreach ((array) $logs as $id => $log) {
        ?>
					<tr class="<?php 
        echo alternator('odd', 'even');
        ?>
">
						<td><?php 
        echo $id + 1;
        ?>
</td>
						<td><?php 
        echo $log[0];
        ?>
</td>
						<td><?php 
        echo $log[1];
        ?>
</td>
						<td><?php 
Esempio n. 9
0
                </td>
            </tr>
            <tr>
                <td colspan="2">
                    <table class="table-details" width="100%" border="0" cellpadding="0" cellspacing="0">
                        <thead>
                        <?php $thStyle = 'color: #35abee; font-weight: normal; background: #fbfbfb; border-bottom: 2px solid #d1d1d1; border-top: 2px solid #d1d1d1; text-align: left; padding: 20px; border-right: 1px solid #f0f0f0;'; ?>
                        <tr>
                            <th style="<?php echo $thStyle; ?>">Retailer</th>
                            <th style="<?php echo $thStyle; ?>">Price</th>
                            <th style="<?php echo $thStyle; ?>">+/-</th>
                        </tr>
                        </thead>
                        <tbody>
                        <?php foreach ($product['prices'] as $site => $priceDetails) : ?>
                            <?php $alt = alternator('odd', 'even'); ?>
                            <?php if ($site == 'average') : ?>
                                <?php $avgStyle = 'background: #fffbd2 !important; padding: 20px; border-right: 1px solid #f0f0f0; border-bottom: 1px solid #f0f0f0;'; ?>
                                <tr>
                                    <td style="<?php echo $avgStyle ?>"><?php echo ucfirst($site) ?></td>
                                    <td style="<?php echo $avgStyle ?> color: #00b2c2; font-weight: bold;"><?php echo $priceDetails['priceStr'] ?></td>
                                    <td style="<?php echo $avgStyle ?>"><?php echo $priceDetails['diffStr'] ?></td>
                                </tr>
                            <?php else : ?>


                                <tr>
                                    <?php $tdStyle = 'padding: 20px; border-right: 1px solid #f0f0f0; border-bottom: 1px solid #f0f0f0;'; ?>

                                    <?php
                                        if ($alt == 'even') {
</div>

<div class="BlueBox">
	<h2>Society email address</h2>
	<p><strong>Society email is not set up</strong></p>
	<p>
		If you have a society account with the university you can register it with The Yorker.
		This makes it easy to send emails from the soc email address and optionally allows you to
			see an unread email count on the [vip] homepage.
	</p>
	<p>Click register to set up your soc account.</p>
	<input type="button" class="button" value="Register" />
</div>

<div class="<?php 
echo alternator('blue', 'grey');
?>
_box">
	<form>
		<H2>Society email address</H2>
		<P><strong>Society email set up as &quot;The Yorker &lt;soc25@york.ac.uk&gt;&quot;</strong></P>
		<input type="button" class="button" value="Change" />
		<input type="button" class="button" value="Remove" />
		
		<P>
			Unread mail counter:
			<input type="radio" name="socUnreadCounter" value="enabled" checked="checked" /> Enabled
			<input type="radio" name="socUnreadCounter" value="disabled" /> Disabled
		</P>
		<P>The unread mail counter allows you to see how many unread emails are in your soc email inbox from the [vip] homepage</P>
		<input type="button" class="button" value="Save" />
Esempio n. 11
0
<h2><?php echo lang('themes.theme_label') . ' ' . lang('themes.options'); ?></h2>
<?php if ($options_array): ?>

	<div class="padding-top">
		<?php echo form_open('admin/themes/options/' . $slug, 'class="crud options-form"');?>
		
			<?php echo form_hidden('slug', $slug); ?>
		
			<ol>
			<?php foreach($options_array as $option): ?>
				<li id="<?php echo $option->slug; ?>" class="<?php echo alternator('even', ''); ?>">
					<label for="<?php echo $option->slug; ?>"><?php echo $option->title; ?></label>
					<div class="width-40 <?php echo 'type-' . $option->type; ?>">
						<?php echo $controller->form_control($option); ?><br/>
						<div class="clear-both text-small1" style="margin-left: 160px;"><?php echo $option->description; ?></div>
					</div>
					<br class="clear-both" />
				</li>
			<?php endforeach; ?>
			</ol>
			
			<div class="buttons float-left padding-top">
				<?php $this->load->view('admin/partials/buttons', array('buttons' => array('re-index') )); ?>
			</div>
			
			<div class="buttons float-right padding-top">
				<?php $this->load->view('admin/partials/buttons', array('buttons' => array('save', 'cancel') )); ?>
			</div>
			
		<?php echo form_close(); ?>
	</div>
Esempio n. 12
0
<!-- Available Widgets Area -->
<table>
	<tbody style="border-bottom: none">
		<tr>
			<!-- Available Widgets -->
			<td valign="top" width="50%">
				<span class="widget-instructions float-right spacer-right"><?php echo lang('widgets.instructions')?></span>
			
				<h3><?php echo lang('widgets.available_title')?></h3>
			
				<?php if ($available_widgets): ?>
					<!-- Available Widget List -->
					<ul id="available-widgets">
					<?php foreach($available_widgets as $widget): ?>
						<li id="widget-<?php echo $widget->slug; ?>" class="widget-box" style="<?php echo alternator('clear:both;', '', '', ''); ?>">
							
							<h3><?php echo $widget->title; ?></h3>
							
							<div class="widget-box-body">
								<p class="description"><?php echo $widget->description; ?></p>
								<p class="author"><?php echo lang('widgets.widget_author').': '.($widget->website ? anchor($widget->website, $widget->author, array('target'=>'_blank')) : $widget->author); ?>
							</div>
						</li>
					<?php endforeach; ?>
					</ul>
				<?php else: ?>
					<p><?php echo lang('widgets.no_available_widgets'); ?></p>
				<?php endif; ?>
			</td>
			
Esempio n. 13
0
 function excel($division = 5)
 {
     /** Include PHPExcel */
     require_once 'PHPExcel.php';
     $divisionname = $this->_divisionname($division);
     //		$cellval = trim(iconv("UTF-8","ISO-8859-1",$cell->getValue())," \t\n\r\0\x0B\xA0");
     $this->load->helper('date');
     $locale = 'da';
     date_default_timezone_set('Europe/London');
     $now = Date("H:i d-m-Y");
     // Create a workbook
     $objPHPExcel = new PHPExcel();
     PHPExcel_CachedObjectStorageFactory::cache_in_memory_gzip;
     $objPHPExcel->getProperties()->setCreator("KBHFF Medlemssystem");
     $objPHPExcel->getProperties()->setLastModifiedBy("KBHFF Medlemssystem {$now}");
     $objPHPExcel->getProperties()->setTitle(utf8_decode($divisionname) . ' medlemsliste');
     $objPHPExcel->getProperties()->setSubject("Medlemsliste");
     $objPHPExcel->getProperties()->setDescription('KBHFF ' . $divisionname . "medlemsliste udskrevet {$now}");
     $objPHPExcel->getProperties()->setKeywords("KBHFF medlemsliste");
     $objPHPExcel->getProperties()->setCategory("medlemsliste");
     $objPHPExcel->getSheet(0);
     $objPHPExcel->getActiveSheet()->getPageSetup()->setFitToWidth(1);
     $objPHPExcel->getActiveSheet()->getPageSetup()->setFitToHeight(0);
     // Rename worksheet
     $objPHPExcel->getActiveSheet()->setTitle(substr($divisionname . ' ' . Date("H.i d-m-Y"), 0, 31));
     // Set active sheet index to the first sheet, so Excel opens this as the first sheet
     $objPHPExcel->setActiveSheetIndex(0);
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $objWorksheet->getTabColor()->setRGB('33cc66');
     // Creating a title
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $objWorksheet->getStyle('A1:I1')->getFont()->setSize(13)->getColor()->setARGB(PHPExcel_Style_Color::COLOR_DARKGREEN);
     $objWorksheet->setCellValueByColumnAndRow(0, 1, 'Medlem #');
     $objWorksheet->setCellValueByColumnAndRow(1, 1, 'Fornavn');
     $objWorksheet->setCellValueByColumnAndRow(2, 1, 'Mellemnavn');
     $objWorksheet->setCellValueByColumnAndRow(3, 1, 'Efternavn');
     $objWorksheet->setCellValueByColumnAndRow(4, 1, 'Email');
     $objWorksheet->setCellValueByColumnAndRow(5, 1, 'Telefon');
     $objWorksheet->setCellValueByColumnAndRow(6, 1, 'Oprettet');
     $objWorksheet->setCellValueByColumnAndRow(7, 1, 'Aktiv');
     $objWorksheet->setCellValueByColumnAndRow(8, 1, 'Note');
     // Autoset widths
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $objWorksheet->getColumnDimension('A')->setAutoSize(true);
     $objWorksheet->getColumnDimension('B')->setAutoSize(true);
     $objWorksheet->getColumnDimension('C')->setAutoSize(true);
     $objWorksheet->getColumnDimension('D')->setAutoSize(true);
     $objWorksheet->getColumnDimension('E')->setAutoSize(true);
     $objWorksheet->getColumnDimension('F')->setAutoSize(true);
     $objWorksheet->getColumnDimension('G')->setAutoSize(true);
     $objWorksheet->getColumnDimension('H')->setAutoSize(true);
     $objWorksheet->getColumnDimension('I')->setAutoSize(true);
     if ($division > 0) {
         $select = ', ff_division_members where ff_division_members.member = ff_persons.uid AND ff_division_members.division = ' . (int) $division;
     }
     $query = $this->db->query('SELECT uid,firstname, middlename, lastname, email, tel, created, active, remark FROM (ff_persons) left join ff_persons_info on (ff_persons.uid = ff_persons_info.puid) ' . $select . ' order by firstname');
     $rowformat1 = array('font' => array('bold' => false), 'fill' => array('type' => PHPExcel_Style_Fill::FILL_SOLID, 'color' => array('rgb' => 'd9ffe2')));
     $rowformat2 = array('font' => array('bold' => false));
     $currentrow = 2;
     foreach ($query->result() as $row) {
         $objPHPExcel->setActiveSheetIndex(0)->setCellValueByColumnAndRow(0, $currentrow, "{$row->uid}")->setCellValueByColumnAndRow(1, $currentrow, "{$row->firstname}")->setCellValueByColumnAndRow(2, $currentrow, "{$row->middlename}")->setCellValueByColumnAndRow(3, $currentrow, "{$row->lastname}")->setCellValueByColumnAndRow(4, $currentrow, "{$row->email}")->setCellValueByColumnAndRow(5, $currentrow, "{$row->tel}")->setCellValueByColumnAndRow(6, $currentrow, "{$row->created}")->setCellValueByColumnAndRow(7, $currentrow, "{$row->active}")->setCellValueByColumnAndRow(8, $currentrow, "{$row->remark}");
         $dynformat = alternator('rowformat1', 'rowformat2');
         $format = ${$dynformat};
         $objPHPExcel->getActiveSheet()->getStyle('A' . $currentrow . ':I' . $currentrow)->applyFromArray($format);
         $currentrow++;
     }
     // Align
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $highestRow = $objWorksheet->getHighestRow();
     $objPHPExcel->getActiveSheet()->getStyle('F1:F' . $highestRow)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);
     $objPHPExcel->getActiveSheet()->getStyle('A1:A' . $highestRow)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);
     // Set repeated headers
     $objPHPExcel->getActiveSheet()->getPageSetup()->setRowsToRepeatAtTopByStartAndEnd(1, 1);
     // Specify printing area
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $highestRow = $objWorksheet->getHighestRow();
     $highestColumn = $objWorksheet->getHighestColumn();
     $objPHPExcel->getActiveSheet()->getPageSetup()->setPrintArea('A1:' . $highestColumn . $highestRow);
     // Redirect output to a clients web browser (Excel5)
     header('Content-Type: application/vnd.ms-excel');
     header('Content-Disposition: attachment;filename="KBHFF medlemsliste ' . $divisionname . ' ' . $now . '.xls"');
     header('Cache-Control: max-age=0');
     // If you're serving to IE 9, then the following may be needed
     header('Cache-Control: max-age=1');
     // If you're serving to IE over SSL, then the following may be needed
     header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
     // Date in the past
     header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
     // always modified
     header('Cache-Control: cache, must-revalidate');
     // HTTP/1.1
     header('Pragma: public');
     // HTTP/1.0
     $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');
     $objWriter->save('php://output');
 }
Esempio n. 14
0
 public function string_helper()
 {
     $this->load->helper('string');
     $this->htmlp(random_string('alnum', 16));
     $this->htmlp(increment_string('file', '_'));
     // "file_1"
     $this->htmlp(increment_string('file', '-', 2));
     // "file-2"
     $this->htmlp(increment_string('file_4'));
     // "file_5"
     for ($i = 0; $i < 10; $i++) {
         $this->htmlp(alternator('one', 'two', 'three', 'four', 'five'));
     }
     $string = "|repeat";
     $this->htmlp(repeater($string, 30));
     // DEPRECATED
     $string = "http://example.com//index.php";
     $this->htmlp(reduce_double_slashes($string));
     // results in "http://example.com/index.php"
     $string = "/this/that/theother/";
     $this->htmlp(trim_slashes($string));
     // results in this/that/theother
     $string = "Fred, Bill,, Joe, Jimmy";
     $string = reduce_multiples($string, ",");
     //results in "Fred, Bill, Joe, Jimmy"
     $this->htmlp($string);
     $string = ",Fred, Bill,, Joe, Jimmy,";
     $string = reduce_multiples($string, ", ", TRUE);
     //results in "Fred, Bill, Joe, Jimmy"
     $this->htmlp($string);
     $string = "Joe's \"dinner\"";
     $string = quotes_to_entities($string);
     //results in "Joe&#39;s &quot;dinner&quot;"
     $this->htmlp($string);
     $string = "Joe's \"dinner\"";
     $string = strip_quotes($string);
     //results in "Joes dinner"
     $this->htmlp($string);
 }
Esempio n. 15
0
						<?php if ( $gallery_images !== FALSE ): ?>
						<?php foreach ( $gallery_images as $image ): ?>
						<li>
							<a href="<?php echo site_url() . 'admin/files/edit/' . $image->file_id; ?>" class="modal">
								<?php echo img(array('src' => site_url() . 'files/thumb/' . $image->file_id, 'alt' => $image->name, 'title' => 'Title: ' . $image->name . ' -- Caption: ' . $image->description)); ?>
								<?php echo form_hidden('action_to[]', $image->id); ?>
							</a>
						</li>
						<?php endforeach; ?>
						<?php endif; ?>
					</ul>
					<div class="clear-both"></div>
				</li>
				<?php endif; ?>
				
				<li style="display: none;" class="images-placeholder <?php echo alternator('', 'even'); ?>">
					<label for="gallery_images"><?php echo lang('galleries.preview_label'); ?></label>
					<div class="clear-both"></div>
					<ul id="gallery_images_list">

					</ul>
					<div class="clear-both"></div>
				</li>

			</ol>

		</div>

		<!-- Design tab -->
		<div id="gallery-design">
Esempio n. 16
0
<table border="0" style="width:95%" id="file_list_table">
	<tr>
		<th style="width:20px"><div style="text-align:center"><input type="checkbox" id="switch_box" onchange="switchCheckboxes(this.checked)" /></div></th>
		<th><?php echo $this->lang->line('files_manage_table_1') ?></th>
		<th><?php echo $this->lang->line('files_manage_table_2') ?></th>
		<th><?php echo $this->lang->line('files_manage_table_2_1'); ?></th>
		<th style="width:80px"><?php echo $this->lang->line('files_manage_table_3') ?></th>
	</tr>
	<?php 
		$i=0;
	foreach($files->result() as $file)
	{
		$id = $file->id;
		$link = $this->files_db->getLinks($file->secid);
	?>
	<tr id="<?php echo $file->file_id?>" <?php echo alternator('class="odd"', 'class="even"')?>>
		<td>
			<div align="center">
				<input type="checkbox" id="check-<?php echo $file->id?>" onchange="manageCheckboxes()" name="files[]" value="<?php echo $file->file_id?>" />
			</div>
		</td>
		<td>
			<a href='<?php echo $link['down']?>' rel="external">
				<img src="<?php echo base_url().'img/files/'.$this->functions->getFileTypeIcon($file->type);?>" class="nb" alt="" />
				<?php echo $this->functions->elipsis($file->o_filename, 10)?>
			</a>
		</td>
		<td>
			<?php echo $this->functions->getFilesizePrefix($file->size)?>
		</td>
		<td>
Esempio n. 17
0
				<th><?php 
    echo lang('wm_watermark');
    ?>
</th>
				<th id="toggle_all"><?php 
    echo form_checkbox('select_all', 'true', FALSE, 'class="toggle_all"');
    ?>
</th>
			</tr>
		</thead>
		<tbody>
		<?php 
    foreach ($sizes as $data) {
        ?>
			<tr class="<?php 
        echo alternator('even', 'odd');
        ?>
">
				<td><?php 
        echo $data['title'];
        ?>
</td>
				<td><?php 
        echo $data['resize_type'];
        ?>
</td>
				<td><?php 
        echo $data['width'];
        ?>
</td>
				<td><?php 
Esempio n. 18
0
            $lead_list[$since_reset][$tgmt_offset_now] = $lead_list[$since_reset][$tgmt_offset_now] + $counttlist;
            $lead_list[$since_reset . '_count'] = $lead_list[$since_reset . '_count'] + $counttlist;
            #If opposite side is not set, it may not in the future so give it a value of zero
            if (!isset($lead_list[$since_resetX][$tgmt_offset_now])) {
                $lead_list[$since_resetX][$tgmt_offset_now] = 0;
            }
        }
        while (list($tzone, ) = each($lead_list[$since_reset])) {
            $LOCALzone = 3600 * $tzone;
            $LOCALdate = gmdate("D M Y H:i", time() + $LOCALzone);
            if ($tzone >= 0) {
                $DISPtzone = "{$plus}{$tzone}";
            } else {
                $DISPtzone = "{$tzone}";
            }
            $allstats .= "<tr align=left class=tr" . alternator('1', '2') . ">";
            $allstats .= "<td>&nbsp; &nbsp;" . $DISPtzone . " &nbsp; &nbsp; (" . $LOCALdate . ")</td>";
            $allstats .= "<td align=\"center\">" . $lead_list['Y'][$tzone] . "</td>";
            $allstats .= "<td align=\"center\">" . $lead_list['N'][$tzone] . "</td>";
            $allstats .= "</tr>";
        }
        $allstats .= "<tr class=\"tr2\"><td><b>SUBTOTALS<b></td><td align=\"center\"><b> <font color=\"green\"> " . $lead_list[Y_count] . "</font></td><td align=\"center\"><b><font color=\"green\">" . $lead_list[N_count] . "</font></td></tr>";
        $allstats .= "<tr class=\"tr1\"><td align=left><b>TOTAL</td><td colspan=2 align=center><font color=\"blue\"><b>" . $lead_list[count] . "</font></td></tr>";
        $allstats .= "</table>";
    }
    echo $exferconf_a_number . '--' . $elistid . '--' . $elistname . '--' . $ecampaign_id . '--' . $eactive . '--' . $elist_description . '--' . $elist_changedate . '--' . $elist_lastcalldate . '--' . $ereset_time . '--' . $eagent_script_override . '--' . $ecampaign_cid_override . '--' . $eam_message_exten_override . '--' . $edrop_inbound_group_override . '--' . $exferconf_a_number . '--' . $exferconf_b_number . '--' . $exferconf_c_number . '--' . $exferconf_d_number . '--' . $exferconf_e_number . '--' . $eweb_form_address . '--' . $eweb_form_address_twoi . '##' . $allstats;
}
if ($action == "customedit") {
    $fieldid = $this->input->post('fieldid');
    $listid = $this->input->post('list_id');
    $customlistvalues = $this->golist->customeditfield($fieldid, $listid);
Esempio n. 19
0
	<p class="notice"><?php 
    echo lang('unable_to_find_templates');
    ?>
</p>

<?php 
} else {
    ?>

	<ul class="menu_list">
	<?php 
    foreach ($specialty_email_templates_summary->result() as $template) {
        ?>
		<li<?php 
        echo alternator(' class="odd"', '');
        ?>
>
			<a href="<?php 
        echo BASE . AMP . 'C=design' . AMP . 'M=edit_email_notification' . AMP . 'template=' . $template->template_name;
        ?>
">
				<?php 
        echo lang($template->template_name);
        ?>
			</a>
		</li>
	<?php 
    }
    ?>
	</ul>
Esempio n. 20
0
				<div id="navigation-uri" style="<?php echo @$navigation_link->link_type == 'uri' ? '' : 'display:none'; ?>">
					<label for="uri"><?php echo lang('nav_uri_label');?></label>
					<input type="text" id="uri" name="uri" value="<?php echo $navigation_link->uri; ?>" />
				</div>
	
				<div id="navigation-page" style="<?php echo @$navigation_link->link_type == 'page' ? '' : 'display:none'; ?>">
					<label for="page_id"><?php echo lang('nav_page_label');?></label>
					<select name="page_id">
						<option value=""><?php echo lang('nav_link_page_select_default');?></option>
						<?php echo $tree_select; ?>
					</select>
				</div>
			</li>
	
			<li class="<?php echo alternator('', 'even'); ?>">
				<label for="target"><?php echo lang('nav_target_label'); ?></label>
				<?php echo form_dropdown('target', array(''=> lang('nav_link_target_self'), '_blank' => lang('nav_link_target_blank')), $navigation_link->target); ?>
			</li>
	
			<li class="<?php echo alternator('', 'even'); ?>">
				<label for="class"><?php echo lang('nav_class_label'); ?></label>
				<?php echo form_input('class', $navigation_link->class); ?>
			</li>
		</ul>
	
		<div class="buttons float-left padding-top">
			<?php $this->load->view('admin/partials/buttons', array('buttons' => array('save', 'cancel') )); ?>
		</div>
	
	<?php echo form_close(); ?>
</div>
?>

<div id="RightColumn">
	<h2 class="first">Page Information</h2>
	<div class="Entry">
		<?php 
RenderMenu($Menu);
?>
	</div>
</div>

<div id="MainColumn">
	<div class="BlueBox">
	<?php 
echo '<h2>' . xml_escape($Title) . '</h2>';
// Reset the alternator
alternator();
// Render notices
foreach ($Notices as $notice) {
    echo '
		<h3>' . xml_escape($notice['subject']) . '</h3>
		<p>Posted <b>' . $notice['post_time'] . '</b> by <a href="' . xml_escape($notice['from_link']) . '">' . xml_escape($notice['from_name']) . '</a></p>
		' . $notice['body'];
    if ($notice['delete_link'] !== NULL) {
        echo '<p><a href="' . $notice['delete_link'] . '">delete notice</a></p>';
    }
}
?>
	</div>
</div>
Esempio n. 22
0
					</li>
				</ul>
			</div>
			<?php  if ($current_folder->items): ?>
			<table class="table-list" border="0">
				<thead>
					<tr>
						<th><?php echo lang('files.actions_label'); ?></th>
						<th><?php echo lang('files.name_label') . '/' . lang('files.description_label'); ?></th>
						<th><?php echo lang('files.file_name') . '/' . lang('file_folders.created_label'); ?></th>
						<th><?php echo lang('wysiwyg.meta.mime'); ?></th>
					</tr>
				</thead>
				<tbody>
					<?php foreach ($current_folder->items as $file): ?>
					<tr class="<?php echo alternator('', 'alt'); ?>">
						<td class="image">
							<button onclick="javascript:insertFile('<?php echo $file->id; ?>', '<?php echo htmlentities($file->name); ?>');">
								Insert
							</button>
						</td>
						<td class="name-description">
							<p><?php echo $file->name; ?><p>
							<p><?php echo $file->description; ?></p>
						</td>
						<td class="filename">
							<p><?php echo $file->filename; ?></p>
							<p><?php echo format_date($file->date_added); ?></p>
						</td>
						<td class="meta width"><?php echo $file->mimetype; ?></td>
					</tr>
Esempio n. 23
0
    function medlemordreliste($divisionday = 0)
    {
        $time_start = microtime(true);
        apache_setenv('KeepAliveTimeout', 300);
        apache_setenv('Timeout', 300);
        apache_setenv('no-gzip', 0);
        ini_set('zlib.output_compression', 1);
        error_reporting(E_ALL);
        ini_set('display_errors', 'On');
        ini_set('error_log', '/var/log/php.log');
        #linux
        set_time_limit(300);
        ini_set('max_execution_time', 300);
        /** Include PHPExcel */
        require_once 'PHPExcel.php';
        //		$cellval = trim(iconv("UTF-8","ISO-8859-1",$cell->getValue())," \t\n\r\0\x0B\xA0");
        $this->load->helper('date');
        $locale = 'da';
        date_default_timezone_set('Europe/London');
        $now = Date("H:i d-m-Y");
        if ($this->uri->segment(3) > 0) {
            $division = $this->uri->segment(3);
        } else {
            $divisionday = $this->input->post('divisionday');
            $division = $this->_division($divisionday);
        }
        $divisionname = $this->_divisionname($division);
        // Create a workbook
        $objPHPExcel = new PHPExcel();
        PHPExcel_CachedObjectStorageFactory::cache_in_memory_gzip;
        $objPHPExcel->getProperties()->setCreator("KBHFF Medlemssystem");
        $objPHPExcel->getProperties()->setLastModifiedBy("KBHFF Medlemssystem {$now}");
        $objPHPExcel->getProperties()->setTitle(utf8_decode($divisionname) . ' medlemsliste');
        $objPHPExcel->getProperties()->setSubject("Ordreliste");
        $objPHPExcel->getProperties()->setDescription('KBHFF ' . utf8_decode($divisionname) . " ordrer udskrevet {$now}");
        $objPHPExcel->getProperties()->setKeywords("KBHFF ordreliste");
        $objPHPExcel->getProperties()->setCategory("ordreliste");
        $objPHPExcel->getSheet(0);
        $objPHPExcel->getActiveSheet()->getPageSetup()->setFitToWidth(1);
        $objPHPExcel->getActiveSheet()->getPageSetup()->setFitToHeight(0);
        // Rename worksheet
        $objPHPExcel->getActiveSheet()->setTitle(substr($divisionname . ' ' . Date("H.i d-m-Y"), 0, 31));
        // Set active sheet index to the first sheet, so Excel opens this as the first sheet
        $objPHPExcel->setActiveSheetIndex(0);
        $objWorksheet = $objPHPExcel->getActiveSheet();
        $objWorksheet->getTabColor()->setRGB('33cc66');
        $query = $this->db->query('SELECT uid, firstname, middlename, lastname 
		FROM ff_persons, ff_division_members
		WHERE ff_persons.uid = ff_division_members.member
		AND ff_division_members.division = ' . (int) $division . ' ORDER BY ff_persons.firstname');
        $rowformat1 = array('font' => array('bold' => false), 'fill' => array('type' => PHPExcel_Style_Fill::FILL_SOLID, 'color' => array('rgb' => 'd9ffe2')));
        $rowformat2 = array('font' => array('bold' => false));
        $datequery = $this->db->query('SELECT uid, pickupdate FROM ff_pickupdates WHERE division = ' . (int) $division . ' and datediff(now(),pickupdate) < 100  ORDER BY pickupdate ');
        $ordercolstart = 2;
        $count = 0;
        foreach ($datequery->result() as $pickupdate) {
            // set col names
            $objPHPExcel->setActiveSheetIndex(0)->setCellValueByColumnAndRow($ordercolstart + $count, 1, $pickupdate->pickupdate);
            $count++;
        }
        $highestColumm = $objPHPExcel->setActiveSheetIndex(0)->getHighestColumn();
        $currentrow = 2;
        foreach ($query->result() as $row) {
            if ($row->middlename > '') {
                $name = $row->firstname . ' ' . $row->middlename . ' ' . $row->lastname;
            } else {
                $name = $row->firstname . ' ' . $row->lastname;
            }
            $objPHPExcel->setActiveSheetIndex(0)->setCellValueByColumnAndRow(0, $currentrow, "{$row->uid}")->setCellValueByColumnAndRow(1, $currentrow, $name);
            $count = 0;
            $datequery = $this->db->query('SELECT uid, pickupdate FROM ff_pickupdates WHERE division = ' . (int) $division . ' and datediff(now(),pickupdate) < 100  ORDER BY pickupdate ');
            foreach ($datequery->result() as $pickupdate) {
                $order = $this->_get_member_dateorder($row->uid, $pickupdate->uid);
                if ($order > 0) {
                    $objPHPExcel->setActiveSheetIndex(0)->setCellValueByColumnAndRow($ordercolstart + $count, $currentrow, $order);
                } else {
                    $objPHPExcel->setActiveSheetIndex(0)->setCellValueByColumnAndRow($ordercolstart + $count, $currentrow, '');
                }
                $count++;
            }
            $dynformat = alternator('rowformat1', 'rowformat2');
            $format = ${$dynformat};
            $objPHPExcel->getActiveSheet()->getStyle('A' . $currentrow . ':' . $highestColumm . $currentrow)->applyFromArray($format);
            $currentrow++;
        }
        $highestRow = $objPHPExcel->setActiveSheetIndex(0)->getHighestRow();
        // Creating a title
        $objWorksheet = $objPHPExcel->getActiveSheet();
        $objWorksheet->getStyle('A1:' . $highestColumm . '1')->getFont()->setSize(13)->getColor()->setARGB(PHPExcel_Style_Color::COLOR_DARKGREEN);
        $objWorksheet->setCellValueByColumnAndRow(0, 1, 'Medlem');
        $objWorksheet->setCellValueByColumnAndRow(1, 1, 'Navn');
        // Autoset widths
        foreach (range('A', $highestColumm) as $columnID) {
            $objPHPExcel->getActiveSheet()->getColumnDimension($columnID)->setAutoSize(true);
        }
        // Align
        // Numberformat
        // Set repeated headers
        $objPHPExcel->getActiveSheet()->getPageSetup()->setRowsToRepeatAtTopByStartAndEnd(1, 1);
        // Specify printing area
        $objWorksheet = $objPHPExcel->getActiveSheet();
        $highestRow = $objWorksheet->getHighestRow();
        $highestColumn = $objWorksheet->getHighestColumn();
        $objPHPExcel->getActiveSheet()->getPageSetup()->setPrintArea('A1:' . $highestColumn . $highestRow);
        // Redirect output to a clients web browser (Excel5)
        header('Content-Type: application/vnd.ms-excel');
        header('Content-Disposition: attachment;filename="KBHFF ' . $divisionname . ' alle ordrer ' . $now . '.xls"');
        header('Cache-Control: max-age=0');
        // If you're serving to IE 9, then the following may be needed
        header('Cache-Control: max-age=1');
        // If you're serving to IE over SSL, then the following may be needed
        header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
        // Date in the past
        header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
        // always modified
        header('Cache-Control: cache, must-revalidate');
        // HTTP/1.1
        header('Pragma: public');
        // HTTP/1.0
        $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');
        $objWriter->save('php://output');
    }
Esempio n. 24
0
					</tr>
			</table>
			<div class="tableFooter"></div>
		</div>

		<?php
			elseif ($menu_value !== '----'):
		?>
			<div class="overview">
				<div class="heading"><h2><?=lang('nav_'.$menu_key)?></h2></div>
				<table class="mainTable" cellspacing="0" cellpadding="0" border="0">
					<?php
						foreach($menu_value as $item_key=>$item_value):
							if ($item_value !== '----' AND ! is_array($item_value)):
					?>
						<tr class="<?=alternator('even', 'odd')?>">
						<?php if ($this->input->get('C') == 'content' && $menu_key == 'publish'):?>
							<td class="overviewItemName"><a href="<?=$item_value?>"><?=lang($item_key)?></a></td>
							<td class="overviewItemDesc">&nbsp;</td>
							<td class="overviewItemHelp"><a rel="external" href="<?=$this->cp->masked_url($this->menu->generate_help_link($controller, $item_key, $controller))?>"><img src="<?=$cp_theme_url?>images/external_link.png"/></a></td>
						<?php else:?>
							<td class="overviewItemName"><a href="<?=$item_value?>"><?=lang('nav_'.$item_key)?></a></td>
							<td class="overviewItemDesc"><?=lang('nav_'.$item_key.'_short_desc')?></td>
							<td class="overviewItemHelp"><a rel="external" href="<?=$this->cp->masked_url($this->menu->generate_help_link($controller, $item_key, $controller))?>"><img src="<?=$cp_theme_url?>images/external_link.png"/></a></td>							
						<?php endif;?>
						</tr>
					<?php 
							endif;
						endforeach;
					?>
				</table>
Esempio n. 25
0
echo ucwords(str_replace('_', ' ', $name));
?>
 Config</h3>
	<table width="500" border="0">
		<?php 
$this->load->helper('string');
if ($num_rows <= 0) {
    ?>
<span class="alert">No Config Settings for this plugin.</span><?
		}
		else
		foreach($configs->result() as $config)
		{
			?>
			<tr <?php 
    echo alternator('class="odd"', 'class="even"');
    ?>
>
				<td width="150"><?php 
    echo $config->description1;
    ?>
</td>
				<td width="350">
					<?php 
    if ($config->type == 'text') {
        ?>
						<input type="text" name="<?php 
        echo $config->name;
        ?>
" id="<?php 
        echo $config->name;
Esempio n. 26
0
         if ($sf < 1) {
             // $field_HTML .= "\n";
             //$field_HTML .= "<HTML><head><title>NON-AGENT API</title>\n";
             //$field_HTML .= "<a href=\"javascript:close_file();\"><font size=1 face=\"Arial,Helvetica\">close frame</font></a>\n";
             $field_HTML .= "<table id=\"audiolisttable\" class=\"tablesorter\" border=0 cellpadding=1 cellspacing=2 width=100% bgcolor=white ><thead>\n";
             $field_HTML .= "<tr align=\"left\" class=\"nowrap\">";
             $field_HTML .= "<th class=\"thheader\" align=\"center\">No</td>\n";
             $field_HTML .= "<th class=\"thheader\" align=\"center\"><b>FILENAME</b></th>\n";
             $field_HTML .= "<th class=\"thheader\" align=\"center\"><b>DATE</b></th>\n";
             $field_HTML .= "<th class=\"thheader\" align=\"center\"><b>SIZE</b></th>\n";
             $field_HTML .= "<th class=\"\" align=\"center\"><b>PLAY</b></th>\n";
             $field_HTML .= "</tr></thead>\n";
         }
         $sf++;
         $field_HTML .= "<tbody>";
         $field_HTML .= "<tr align=left class=tr" . alternator('1', '2') . ">";
         $field_HTML .= "<td align=\"center\">{$sf}</td>\n";
         $field_HTML .= "<td align=\"left\">{$file_names[$m]}</td>\n";
         $field_HTML .= "<td align=\"center\">{$file_dates[$m]}</td>\n";
         $field_HTML .= "<td align=\"center\">{$file_sizes[$m]}</td>\n";
         $field_HTML .= "<td align=\"center\"><a href=\"{$sound_file}\" target=\"_blank\"><img src={$base}/img/play.png></a></td>\n";
         /*
                                                          $field_HTML .= "<audio id=\"audio1\" src=\"$admDIR/$sounds_web_directory/$file_names[$m]\" controls preload=\"auto\" autobuffer></audio> </td></tr>\n";*/
         $mislo .= "{$file_dates[$m]}";
         $filenames .= "{$file_names[$m]}<br>";
         $filesdates .= "{$file_dates[$m]}<br>";
         $filessizes .= "{$file_sizes[$m]}<br>";
         //$itemsumitexplode = explode('.', $file_names[$m]);
         //$soundfiles .= "<option value=$itemsumitexplode[0]> $itemsumitexplode[0] </option>";
     }
 }
Esempio n. 27
0
 
				  <?php 
echo form_dropdown('groups', get_option('id', 'name', 'groups'), @$_GET['groups'], 'class="group_ddl"', 'ทุกกลุ่มงาน');
?>
                  <input type="submit" class="btn_search2" value="ค้นหา" />
				  </p>
				</form>
                
			<?php 
echo $mediafiles_list->pagination();
?>
			<?php 
foreach ($mediafiles_list as $mediafile) {
    ?>
              <div class="box <?php 
    echo alternator('', 'alt');
    ?>
"> 
              <a class="thumb" href="mediafiles/view/<?php 
    echo $mediafile->id;
    ?>
"><img width="77" height="64" class="photo" src="<?php 
    echo is_file('uploads/mediafiles/' . $mediafile->image) ? 'uploads/mediafiles/' . $mediafile->image : 'themes/gcdnew/photo/nophoto.gif';
    ?>
"></a>
                    <div class="box_info">
                    <span><?php 
    echo $mediafile->created;
    ?>
 - view:<?php 
    echo $mediafile->counter;
Esempio n. 28
0
    return;
}
?>

<div class="tableWrapper">
<table width="100%" border="0" cellpadding="2" cellspacing="0">
<tr>
	<th width="40%">Pricefile Group Name</th>
  <th width="40%">File</th>
  <th width="20%">Action</th>
</tr>
<?php 
foreach ($pricelist as $item) {
    ?>
    <tr class="<?php 
    echo alternator('', '');
    ?>
">
   	<td><b><?php 
    echo $item['pricefile_group_name'];
    ?>
</b></td>
   	<td><a href="price/download/<?php 
    echo $item['pricefile_group_id'];
    ?>
"><?php 
    echo $item['pricefile_name'];
    ?>
</a></td>
	<td><a href="price/edit/<?php 
    echo $item['pricefile_group_id'];
</p>
				<?php 
}
?>
				<p><?php 
echo lang('choose_translation_file');
?>
</p>

				<ul class="menu_list">
				<?php 
foreach ($language_files as $file) {
    ?>

					<li<?php 
    echo alternator('', ' class="odd"');
    ?>
><a href="<?php 
    echo BASE . AMP . 'C=tools_utilities' . AMP . 'M=translate' . AMP . 'language_file=' . $file;
    ?>
"><?php 
    echo $file;
    ?>
</a></li>

				<?php 
}
?>
				</ul>		
			</div>
Esempio n. 30
0
						</th>
					</tr>
					</thead>
					<tbody>
					<?php 
if ($permissions->list_read == "N") {
    echo "<tr class='tr2'><td colspan='9'>" . lang('go_Youdonthavepermissiontoviewthisrecords') . "</td></tr>";
    $countthis = 0;
    $justpermission = true;
}
if ($countthis > 0) {
    foreach ($lists as $listsInfo) {
        ?>
   		         	
							 <tr align="left" class="tr<?php 
        echo alternator('1', '2');
        ?>
">
								 <td align="left" style="padding-bottom:-1px;">&nbsp;
								 <!--<div class="rightdiv toolTip" title="MODIFY <?php 
        echo $listsInfo->list_id;
        ?>
">-->
								<!-- <a id="listidlink" class="activator"  onClick="postval('<?php 
        echo $listsInfo->list_id;
        ?>
');"><?php 
        echo $listsInfo->list_id;
        ?>
</a>-->
								<a id="listidlink" class="leftDiv toolTip" style="cursor:pointer;"  title="<?php