Added ugly hack to allow switching export options in Opera (bug #828712).

This commit is contained in:
Michal Čihař
2003-10-23 12:55:10 +00:00
parent c848070471
commit a8b1de3a30
2 changed files with 33 additions and 27 deletions

View File

@@ -13,6 +13,8 @@ $Source$
libraries/common.lib.php3, libraries/config_import.lib.php3: Allow to
supress dates in SQL dump separately.
* lang/add_message.sh: Fail if no message specified.
* libraries/display_export.lib.php3: Added ugly hack to allow switching
export options in Opera (bug #828712).
2003-10-21 Marc Delisle <lem9@users.sourceforge.net>
* pdf_pages.php3: Patch 825672: show fields in Edit PDF scratchboard,

View File

@@ -53,6 +53,35 @@ if (isset($sql_query)) {
<?php } ?>
getElement("none_options").style.display = 'none';
}
function show_checked_option() {
hide_them_all();
if (getElement('radio_dump_latex').checked) {
getElement('latex_options').style.display = 'block';
<?php if (!$hide_sql) { ?>
} else if (getElement('radio_dump_sql').checked) {
getElement('sql_options').style.display = 'block';
<?php } ?>
<?php if (!$hide_xml) { ?>
} else if (getElement('radio_dump_xml').checked) {
getElement('none_options').style.display = 'block';
<?php } ?>
} else if (getElement('radio_dump_csv').checked) {
getElement('csv_options').style.display = 'block';
} else if (getElement('radio_dump_excel').checked) {
getElement('excel_options').style.display = 'block';
} else {
if (getElement('radio_dump_sql')) {
getElement('radio_dump_sql').checked = true;
getElement('sql_options').style.display = 'block';
} else if (getElement('radio_dump_csv')) {
getElement('radio_dump_csv').checked = true;
getElement('csv_options').style.display = 'block';
} else {
getElement('none_options').style.display = 'block';
}
}
}
//-->
</script>
@@ -60,7 +89,7 @@ if (isset($sql_query)) {
<tr>
<!-- Formats to export to -->
<td nowrap="nowrap" valign="top">
<td nowrap="nowrap" valign="top" onclick="if (typeof(window.opera) != 'undefined')setTimeout('show_checked_option()', 1); return true">
<fieldset <?php echo ((!isset($multi_values) || isset($multi_values) && $multi_values == '') ? 'style="height: 220px;"' : ''); ?>>
<legend><?php echo $strExport; ?></legend>
<br>
@@ -376,32 +405,7 @@ if ($cfgRelation['mimework']) {
<script type="text/javascript">
<!--
hide_them_all();
if (getElement('radio_dump_latex').checked) {
getElement('latex_options').style.display = 'block';
<?php if (!$hide_sql) { ?>
} else if (getElement('radio_dump_sql').checked) {
getElement('sql_options').style.display = 'block';
<?php } ?>
<?php if (!$hide_xml) { ?>
} else if (getElement('radio_dump_xml').checked) {
getElement('none_options').style.display = 'block';
<?php } ?>
} else if (getElement('radio_dump_csv').checked) {
getElement('csv_options').style.display = 'block';
} else if (getElement('radio_dump_excel').checked) {
getElement('excel_options').style.display = 'block';
} else {
if (getElement('radio_dump_sql')) {
getElement('radio_dump_sql').checked = true;
getElement('sql_options').style.display = 'block';
} else if (getElement('radio_dump_csv')) {
getElement('radio_dump_csv').checked = true;
getElement('csv_options').style.display = 'block';
} else {
getElement('none_options').style.display = 'block';
}
}
show_checked_option();
//-->
</script>
</td>