I am using theme files I bought from Template Monster in 2013. It was half-assed from the beginning, but I eventually got it working great, customized it further, and still love it.
I can't upgrade to php7 without this piece of code in the tpl-header.php crashing everything. It is code to select the currency. This works fine with php5.6, but causes the website to work not with any version of php7.
Perhaps someone can point me in the right direction.
<!-- ========== CURRENCIES ========= -->
<?php echo zen_draw_form('currencies', zen_href_link(basename(ereg_replace('.php','', $PHP_SELF)), '', $request_type, false), 'get'); ?>
<div>
<span class="label"><?php echo BOX_HEADING_CURRENCIES;?>: </span>
<?php
if (isset($currencies) && is_object($currencies)) {
reset($currencies->currencies);
$currencies_array = array();
while (list($key, $value) = each($currencies->currencies)) {
$currencies_array[] = array('id' => $key, 'text' => $value['title']);
}
$hidden_get_variables = '';
reset($_GET);
while (list($key, $value) = each($_GET)) {
if ( ($key != 'currency') && ($key != zen_session_name()) && ($key != 'x') && ($key != 'y') ) {
$hidden_get_variables .= zen_draw_hidden_field($key, $value);
}
}
}
?>
<?php echo zen_draw_pull_down_menu('currency', $currencies_array, $_SESSION['currency'], 'class="select" onchange="this.form.submit();"') . $hidden_get_variables . zen_hide_session_id()?>
</div>
</form>
<!-- ====================================== -->
Bookmarks