Example #1
0
<?php 
    return;
}
$intInvoiceId = getRequest('id', FALSE);
$boolRefund = getRequest('refund', FALSE);
$strFunc = getRequest('func', '');
$strList = getRequest('list', '');
if ($intInvoiceId) {
    if ($boolRefund) {
        $strQuery = 'UPDATE {prefix}invoice ' . 'SET state_id = 4 ' . 'WHERE {prefix}invoice.id = ?';
        mysqli_param_query($strQuery, [$intInvoiceId]);
    }
    $strQuery = 'SELECT * ' . 'FROM {prefix}invoice ' . 'WHERE {prefix}invoice.id = ?';
    $intRes = mysqli_param_query($strQuery, [$intInvoiceId]);
    if (!($invoiceData = mysqli_fetch_assoc($intRes))) {
        echo htmlPageStart(_PAGE_TITLE_, getSetting('session_keepalive') ? ['js/keepalive.js'] : null);
        ?>
<body>
	<div class="ui-widget">
		<div class="form_container ui-widget-content">
      <?php 
        echo $GLOBALS['locRecordNotFound'] . "\n";
        ?>
    </div>
	</div>
</body>
</html>
<?php 
        return;
    }
    $paymentDays = getPaymentDays($invoiceData['company_id']);
    protected function showEmailForm($submitted)
    {
        $senderData = $this->senderData;
        $recipientData = $this->recipientData;
        echo htmlPageStart(_PAGE_TITLE_ . ' - ' . $GLOBALS['locSendEmail']);
        ?>
<body>
	<div class="pagewrapper ui-widget ui-widget-content">

		<div id="email_form_container" class="form_container">
			<h1><?php 
        echo $GLOBALS['locSendEmail'];
        ?>
</h1>
<?php 
        if ($submitted) {
            echo '<div class="ui-state-error-text">' . $GLOBALS['locEmailFillRequiredFields'] . "<br><br></div>\n";
        }
        ?>
  <form method="POST" id="email_form">
				<input type="hidden" name="id"
					value="<?php 
        echo htmlspecialchars(getRequest('id', ''));
        ?>
"> <input
					type="hidden" name="template"
					value="<?php 
        echo htmlspecialchars(getRequest('template', ''));
        ?>
">
				<input type="hidden" name="email_send" value="1"> <input
					type="hidden" name="func"
					value="<?php 
        echo htmlspecialchars(getRequest('func', ''));
        ?>
">
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailFrom'];
        ?>
</div>
				<div class="field">
					<input type="text" id="email_from" name="email_from" class="medium"
						value="<?php 
        echo htmlspecialchars($this->emailFrom);
        ?>
">
				</div>
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailTo'];
        ?>
</div>
				<div class="field">
					<input type="text" id="email_to" name="email_to" class="medium"
						value="<?php 
        echo htmlspecialchars($this->emailTo);
        ?>
">
				</div>
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailCC'];
        ?>
</div>
				<div class="field">
					<input type="text" id="email_cc" name="email_cc" class="medium"
						value="<?php 
        echo htmlspecialchars($this->emailCC);
        ?>
">
				</div>
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailBCC'];
        ?>
</div>
				<div class="field">
					<input type="text" id="email_bcc" name="email_bcc" class="medium"
						value="<?php 
        echo htmlspecialchars($this->emailBCC);
        ?>
">
				</div>
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailSubject'];
        ?>
</div>
				<div class="field">
					<input type="text" id="email_subject" name="email_subject"
						class="medium"
						value="<?php 
        echo htmlspecialchars($this->emailSubject);
        ?>
">
				</div>
				<div class="medium_label"><?php 
        echo $GLOBALS['locEmailBody'];
        ?>
</div>
				<div class="field">
					<textarea id="emailBody" name="email_body" class="email_body"
						cols="80" rows="24"><?php 
        echo htmlspecialchars($this->emailBody);
        ?>
</textarea>
				</div>
				<div class="form_buttons" style="clear: both">
					<a class="actionlink"
						onclick="document.getElementById('email_form').submit(); return false;"
						href="#"><?php 
        echo $GLOBALS['locSend'];
        ?>
</a> <a
						class="actionlink"
						onclick="if (window.opener) window.close(); else history.back(); return false;"
						href="#"><?php 
        echo $GLOBALS['locCancel'];
        ?>
</a>
				</div>
			</form>
		</div>
	</div>
</body>
</html>
<?php 
    }
Example #3
0
PkLasku : web-pohjainen laskutusohjelmisto.
Copyright (C) 2004-2008 Samu Reinikainen

Tämä ohjelma on vapaa. Lue oheinen LICENSE.

*******************************************************************************/
// buffered, so we can redirect later if necessary
ini_set('implicit_flush', 'Off');
ob_start();
require_once 'htmlfuncs.php';
require_once 'sqlfuncs.php';
require_once 'sessionfuncs.php';
sesVerifySession();
require_once 'localize.php';
sesEndSession();
echo htmlPageStart(_PAGE_TITLE_);
?>

<body>
<div class="pagewrapper ui-widget ui-widget-content">
<div style="padding: 30px;">

<h1><?php 
echo $GLOBALS['locThankYou'];
?>
</h1>
<p>
<?php 
echo $GLOBALS['locSessionClosed'];
?>
</p>
Example #4
0
                    header('Location: ' . getSelfPath() . '/index.php');
                }
                exit;
            case 'FAIL':
                $strMessage = $GLOBALS['locInvalidCredentials'];
                break;
            case 'TIMEOUT':
                $strMessage = $GLOBALS['locLoginTimeout'];
                break;
        }
    } else {
        $strMessage = $GLOBALS['locMissingFields'];
    }
}
$key = sesCreateKey();
echo htmlPageStart(_PAGE_TITLE_, ['jquery/js/jquery.md5.js']);
?>

<body onload="document.getElementById('flogin').focus();">
	<div class="pagewrapper ui-widget ui-widget-content">
		<div class="form" style="padding: 30px;">

<?php 
if (isset($upgradeMessage)) {
    ?>
<div
				class="message ui-widget <?php 
    echo isset($upgradeFailed) ? 'ui-state-error' : 'ui-state-highlight';
    ?>
">
  <?php 
Example #5
0
if (!$strFunc) {
    $strFunc = 'open_invoices';
}
if ($strFunc == 'logout') {
    header('Location: ' . getSelfPath() . '/logout.php');
    exit;
}
if (!$strFunc && $strForm) {
    $strFunc = 'invoices';
}
$title = getPageTitle($strFunc, $strList, $strForm);
if ($strFunc == 'system' && getRequest('operation', '') == 'dbdump' && sesAccessLevel(array(ROLE_BACKUPMGR, ROLE_ADMIN))) {
    create_db_dump();
    exit;
}
echo htmlPageStart(_PAGE_TITLE_ . " - {$title}", getSetting('session_keepalive') ? array('js/keepalive.js') : null);
$normalMenuRights = array(ROLE_READONLY, ROLE_USER, ROLE_BACKUPMGR);
$astrMainButtons = array(array("name" => "invoice", "title" => "locShowInvoiceNavi", 'action' => 'open_invoices', "levels_allowed" => array(ROLE_READONLY, ROLE_USER, ROLE_BACKUPMGR)), array("name" => "archive", "title" => "locShowArchiveNavi", 'action' => 'archived_invoices', "levels_allowed" => array(ROLE_READONLY, ROLE_USER, ROLE_BACKUPMGR)), array("name" => "company", "title" => "locShowClientNavi", 'action' => 'companies', "levels_allowed" => array(ROLE_USER, ROLE_BACKUPMGR)), array("name" => "reports", "title" => "locShowReportNavi", 'action' => 'reports', "levels_allowed" => array(ROLE_READONLY, ROLE_USER, ROLE_BACKUPMGR)), array("name" => "settings", "title" => "locShowSettingsNavi", 'action' => 'settings', "action" => "settings", "levels_allowed" => array(ROLE_USER, ROLE_BACKUPMGR)), array("name" => "system", "title" => "locShowSystemNavi", 'action' => 'system', "levels_allowed" => array(ROLE_BACKUPMGR, ROLE_ADMIN)), array("name" => "logout", "title" => "locLogout", 'action' => 'logout', "levels_allowed" => null));
?>

<body>
<div class="pagewrapper ui-widget-content">
<div class="ui-widget">
  <div id="maintabs" class="navi ui-widget-header ui-tabs">
    <ul class="ui-tabs-nav ui-helper-clearfix ui-corner-all">
<?php 
foreach ($astrMainButtons as $button) {
    $strButton = '<li class="functionlink ui-state-default ui-corner-top';
    if ($button['action'] == $strFunc || $button['action'] == 'open_invoices' && $strFunc == 'invoices') {
        $strButton .= ' ui-tabs-selected ui-state-active';
    }
Example #6
0
                    header('Location: ' . getSelfPath() . '/index.php');
                }
                exit;
            case 'FAIL':
                $strMessage = $GLOBALS['locInvalidCredentials'];
                break;
            case 'TIMEOUT':
                $strMessage = $GLOBALS['locLoginTimeout'];
                break;
        }
    } else {
        $strMessage = $GLOBALS['locMissingFields'];
    }
}
$key = sesCreateKey();
echo htmlPageStart(_PAGE_TITLE_, array('jquery/js/jquery.md5.js'));
?>

<body onload="document.getElementById('flogin').focus();">
<div class="pagewrapper ui-widget ui-widget-content">
<div class="form" style="padding: 30px;">

<?php 
if (isset($upgradeMessage)) {
    ?>
<div class="message ui-widget <?php 
    echo isset($upgradeFailed) ? 'ui-state-error' : 'ui-state-highlight';
    ?>
">
  <?php 
    echo $upgradeMessage;