16-Apr-2010 Joe Hunt
# Minor fixes in voiding transactions
$ /admin/void_transaction.php
+! Layout improvement in hyperlink_back function
+$ /includes/ui/ui_controls.inc
15-Apr-2010 Joe Hunt
! Added an alternative way of presenting tax included on invoices.
function hyperlink_back($center=true, $no_menu=true, $type_no=0, $trans_no=0)
{
+ global $path_to_root;
+
if ($center)
echo "<center>";
- start_table(false, "width=30%");
+ $id = 0;
+ if ($no_menu && $type_no != 0 && $trans_no != 0)
+ {
+ include_once($path_to_root."/admin/db/attachments_db.inc");
+ $id = has_attachment($type_no, $trans_no);
+ }
+ $width = ($id != 0 ? "30%" : "20%");
+ start_table(false, "width=$width");
start_row();
if ($no_menu)
{
- if ($type_no != 0 && $trans_no != 0)
- {
- global $path_to_root;
- include_once($path_to_root."/admin/db/attachments_db.inc");
- $id = has_attachment($type_no, $trans_no);
- if ($id != 0)
- echo "<td align=center><a href='$path_to_root/admin/attachments.php?vw=$id' target='blanc_'>"._("View Attachment")."</a></td>\n";
- }
+ if ($id != 0)
+ echo "<td align=center><a href='$path_to_root/admin/attachments.php?vw=$id' target='blanc_'>"._("View Attachment")."</a></td>\n";
echo "<td align=center><a href='javascript:window.print();'>"._("Print")."</a></td>\n";
}
echo "<td align=center><a href='javascript:goBack();'>".($no_menu ? _("Close") : _("Back"))."</a></td>\n";