[Weberp-svn] SF.net SVN: weberp:[9547] trunk
Brought to you by:
sotandeka,
tim_schofield
From: <tim...@us...> - 2012-08-23 16:53:23
|
Revision: 9547 http://weberp.svn.sourceforge.net/weberp/?rev=9547&view=rev Author: tim_schofield Date: 2012-08-23 16:53:15 +0000 (Thu, 23 Aug 2012) Log Message: ----------- Replace <a tags with InternalLink() function Modified Paths: -------------- trunk/StockLocTransfer.php trunk/StockLocTransferReceive.php trunk/StockMovements.php trunk/StockQties_csv.php trunk/StockQuantityByDate.php trunk/StockReorderLevel.php trunk/StockStatus.php trunk/StockTransferControlled.php trunk/StockTransfers.php trunk/StockUsage.php trunk/Stocks.php trunk/SuppCreditGRNs.php trunk/SupplierAllocations.php trunk/SupplierBalsAtPeriodEnd.php trunk/SupplierContacts.php trunk/css/silverwolf/images/inventory.png Modified: trunk/StockLocTransfer.php =================================================================== --- trunk/StockLocTransfer.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockLocTransfer.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -217,7 +217,7 @@ DB_Txn_Commit($db); prnMsg( _('The inventory transfer records have been created successfully'),'success'); - echo '<p><a href="'.$rootpath.'/PDFStockLocTransfer.php?TransferNo=' . $_POST['Trf_ID'] . '">'. _('Print the Transfer Docket'). '</a></p>'; + echo '<p>' . InternalLink($rootpath, 'PDFStockLocTransfer.php?TransferNo=' . $_POST['Trf_ID'], _('Print the Transfer Docket')) . '</p>'; include('includes/footer.inc'); } else { Modified: trunk/StockLocTransferReceive.php =================================================================== --- trunk/StockLocTransferReceive.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockLocTransferReceive.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -464,7 +464,10 @@ echo '<td class="number">' . locale_number_format($TrfLine->PrevRecvQty, $TrfLine->DecimalPlaces) . '</td>'; if ($TrfLine->Controlled==1){ - echo '<td class="number"><input type="hidden" name="Qty' . $i . '" value="' . locale_number_format($Qty, $TrfLine->DecimalPlaces) . '"><a href="' . $rootpath .'/StockTransferControlled.php?TransferItem=' . $i . '" />' . locale_number_format($Qty, $TrfLine->DecimalPlaces) . '</a></td>'; + echo '<td class="number"> + <input type="hidden" name="Qty' . $i . '" value="' . locale_number_format($Qty, $TrfLine->DecimalPlaces) . '" /> + ' . InternalLink($rootpath, 'StockTransferControlled.php?TransferItem=' . $i, locale_number_format($Qty, $TrfLine->DecimalPlaces)) . ' + </td>'; } else { echo '<td><input type="text" class="number" name="Qty' . $i . '" maxlength="10" class="number" size="auto" value="' . locale_number_format($Qty, $TrfLine->DecimalPlaces) . '" /></td>'; } @@ -476,9 +479,9 @@ if ($TrfLine->Controlled==1){ if ($TrfLine->Serialised==1){ - echo '<td><a href="' . $rootpath .'/StockTransferControlled.php?TransferItem=' . $i . '">' . _('Enter Serial Numbers') . '</a></td>'; + echo '<td>' . InternalLink($rootpath, 'StockTransferControlled.php?TransferItem=' . $i, _('Enter Serial Numbers')) . '</td>'; } else { - echo '<td><a href="' . $rootpath .'/StockTransferControlled.php?TransferItem=' . $i . '">' . _('Enter Batch Refs') . '</a></td>'; + echo '<td>' . InternalLink($rootpath, 'StockTransferControlled.php?TransferItem=' . $i, _('Enter Batch Refs')) . '</td>'; } } @@ -490,7 +493,7 @@ echo '</table><br /> <div class="centre"><button type="submit" name="ProcessTransfer">'. _('Process Inventory Transfer'). '</button> </form></div><br />'; - echo '<div class="centre"><a href="'.htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'). '?NewTransfer=true">'. _('Select A Different Transfer').'</a></div>'; + echo '<div class="centre">' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'). '?NewTransfer=true', _('Select A Different Transfer')) . '</div>'; } else { /*Not $_SESSION['Transfer'] set */ @@ -532,8 +535,10 @@ $LocResult = DB_query($LocSql,$db); $LocRow = DB_fetch_array($LocResult); echo '<table class="selection">'; - echo '<tr><th colspan="4" class="header">'._('Pending Transfers Into').' '.$LocRow['locationname'].'</th></tr>'; echo '<tr> + <th colspan="4" class="header">'._('Pending Transfers Into').' '.$LocRow['locationname'].'</th> + </tr>'; + echo '<tr> <th>'. _('Transfer Ref'). '</th> <th>'. _('Transfer From'). '</th> <th>'. _('Dispatch Date'). '</th> @@ -551,7 +556,7 @@ echo '<td class="number">' . $myrow['reference'] . '</td> <td>' . $myrow['trffromloc'] . '</td> <td>' . ConvertSQLDateTime($myrow['shipdate']) . '</td> - <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?Trf_ID=' . $myrow['reference'] . '">'. _('Receive'). '</a></td></tr>'; + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?Trf_ID=' . $myrow['reference'], _('Receive')) . '</td></tr>'; } Modified: trunk/StockMovements.php =================================================================== --- trunk/StockMovements.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockMovements.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -18,10 +18,6 @@ $StockID = ''; } - -// This is already linked from this page -//echo "<a href='" . $rootpath . '/SelectProduct.php'>" . _('Back to Items') . '</a><br />'; - $result = DB_query("SELECT description, units FROM stockmaster WHERE stockid='".$StockID."'",$db); $myrow = DB_fetch_array($result); echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Inventory') . '" alt="" /><b>' . ' ' . $StockID . ' - ' . $myrow['description'] . ' : ' . _('in units of') . ' : ' . $myrow['units'] . '</b></p>'; @@ -123,88 +119,55 @@ if ($myrow['type']==10){ /*its a sales invoice allow link to show invoice it was sold on*/ - printf('<td><a TARGET="_blank" href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice">%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s%%</td> - <td class="number">%s</td> - </tr>', - $rootpath, - $myrow['transno'], - $myrow['typename'], - $myrow['transno'], - $DisplayTranDate, - $myrow['debtorno'], - $myrow['branchcode'], - locale_number_format($myrow['qty'],$myrow['decimalplaces']), - $myrow['reference'], - locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']), - locale_number_format($myrow['discountpercent']*100,2), - locale_number_format($myrow['newqoh'],$myrow['decimalplaces'])); + echo '<td>' . InternalLink($rootpath, 'PrintCustTrans.php?FromTransNo=' . $myrow['transno'] . '&InvOrCredit=Invoice', $myrow['typename']) . '</td> + <td>' . $myrow['transno'] . '</td> + <td>' . $DisplayTranDate . '</td> + <td>' . $myrow['debtorno'] . '</td> + <td>' . $myrow['branchcode'] . '</td> + <td class="number">' . locale_number_format($myrow['qty'],$myrow['decimalplaces']) . '</td> + <td>' . $myrow['reference'] . '</td> + <td class="number">' . locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']) . '</td> + <td class="number">' . locale_number_format($myrow['discountpercent']*100,2) . '%</td> + <td class="number">' . locale_number_format($myrow['newqoh'],$myrow['decimalplaces']) . '</td> + </tr>'; } elseif ($myrow['type']==11){ - printf('<td><a TARGET="_blank" href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Credit">%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s%%</td> - <td class="number">%s</td> - </tr>', - $rootpath, - $myrow['transno'], - $myrow['typename'], - $myrow['transno'], - $DisplayTranDate, - $myrow['debtorno'], - $myrow['branchcode'], - locale_number_format($myrow['qty'],$myrow['decimalplaces']), - $myrow['reference'], - locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']), - locale_number_format($myrow['discountpercent']*100,2), - locale_number_format($myrow['newqoh'],$myrow['decimalplaces'])); + echo '<td>' . InternalLink($rootpath, 'PrintCustTrans.php?FromTransNo=' . $myrow['transno'] . '&InvOrCredit=Credit', $myrow['typename']) . '</td> + <td>' . $myrow['transno'] . '</td> + <td>' . $DisplayTranDate . '</td> + <td>' . $myrow['debtorno'] . '</td> + <td>' . $myrow['branchcode'] . '</td> + <td class="number">' . locale_number_format($myrow['qty'],$myrow['decimalplaces']) . '</td> + <td>' . $myrow['reference'] . '</td> + <td class="number">' . locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']) . '</td> + <td class="number">' . locale_number_format($myrow['discountpercent']*100,2) . '%</td> + <td class="number">' . locale_number_format($myrow['newqoh'],$myrow['decimalplaces']) . '</td> + </tr>'; } else { - printf('<td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s%%</td> - <td class="number">%s</td> - </tr>', - $myrow['typename'], - $myrow['transno'], - $DisplayTranDate, - $myrow['debtorno'], - $myrow['branchcode'], - locale_number_format($myrow['qty'],$myrow['decimalplaces']), - $myrow['reference'], - locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']), - locale_number_format($myrow['discountpercent']*100,2), - locale_number_format($myrow['newqoh'],$myrow['decimalplaces'])); + echo '<td>' . $myrow['typename'] . '</td> + <td>' . $myrow['transno'] . '</td> + <td>' . $DisplayTranDate . '</td> + <td>' . $myrow['debtorno'] . '</td> + <td>' . $myrow['branchcode'] . '</td> + <td class="number">' . locale_number_format($myrow['qty'],$myrow['decimalplaces']) . '</td> + <td>' . $myrow['reference'] . '</td> + <td class="number">' . locale_money_format($myrow['price'],$_SESSION['CompanyRecord']['currencydefault']) . '</td> + <td class="number">' . locale_number_format($myrow['discountpercent']*100,2) . '%</td> + <td class="number">' . locale_number_format($myrow['newqoh'],$myrow['decimalplaces']) . '</td> + </tr>'; } //end of page full new headings if } //end of while loop echo '</table>'; -echo '<div class="centre"><br /><a href="'.$rootpath.'/StockStatus.php?StockID='.$StockID.'">' . _('Show Stock Status') . '</a>'; -echo '<br /><a href="'.$rootpath.'/StockUsage.php?StockID='.$StockID.'&StockLocation=' . $_POST['StockLocation'] . '">' . _('Show Stock Usage') . '</a>'; -echo '<br /><a href="'.$rootpath.'/SelectSalesOrder.php?SelectedStockItem='.$StockID.'&StockLocation=' . $_POST['StockLocation'] . '">' . _('Search Outstanding Sales Orders') . '</a>'; -echo '<br /><a href="'.$rootpath.'/SelectCompletedOrder.php?SelectedStockItem='.$StockID.'">' . _('Search Completed Sales Orders') . '</a>'; +echo '<div class="centre"> + <br />' . InternalLink($rootpath, 'StockStatus.php?StockID='.$StockID, _('Show Stock Status')) . ' + <br />' . InternalLink($rootpath, 'StockUsage.php?StockID='.$StockID.'&StockLocation=' . $_POST['StockLocation'], _('Show Stock Usage')) . ' + <br />' . InternalLink($rootpath, 'SelectSalesOrder.php?SelectedStockItem='.$StockID.'&StockLocation=' . $_POST['StockLocation'], _('Search Outstanding Sales Orders')) . ' + <br />' . InternalLink($rootpath, 'SelectCompletedOrder.php?SelectedStockItem='.$StockID, _('Search Completed Sales Orders')); echo '</form></div>'; Modified: trunk/StockQties_csv.php =================================================================== --- trunk/StockQties_csv.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockQties_csv.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -40,7 +40,7 @@ fclose($fp); -echo '<br /><div class="centre"><a href="' . $rootpath . '/' . $_SESSION['reports_dir'] . '/StockQties.csv ">' . _('click here') . '</a> ' . _('to view the file') . '</div>'; +echo '<br /><div class="centre">' . InternalLink($rootpath, $_SESSION['reports_dir'] . '/StockQties.csv', _('click here')) . _('to view the file') . '</div>'; include('includes/footer.inc'); Modified: trunk/StockQuantityByDate.php =================================================================== --- trunk/StockQuantityByDate.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockQuantityByDate.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -7,7 +7,7 @@ $title = _('Stock On Hand By Date'); include('includes/header.inc'); -echo '<p Class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Inventory') .'" alt="" /><b>' . $title. '</b></p>'; +echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Inventory') .'" alt="" /><b>' . $title. '</b></p>'; echo '<form onsubmit="return SubmitForm(this, \'\')" action="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '" method="post">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; @@ -72,10 +72,12 @@ if(isset($_POST['ShowStatus']) AND Is_Date($_POST['OnHandDate'])) { if ($_POST['StockCategory']=='All') { - $sql = "SELECT stockid, + $sql = "SELECT distinct stockmoves.stockid, description, decimalplaces FROM stockmaster + LEFT JOIN stockmoves + ON stockmaster.stockid=stockmoves.stockid WHERE (mbflag='M' OR mbflag='B')"; } else { $sql = "SELECT stockid, @@ -131,21 +133,13 @@ } if($NumRows == 0){ - printf('<td><a target="_blank" href="StockStatus.php?%s">%s</td> - <td>%s</td> - <td class="number">%s</td>', - 'StockID=' . mb_strtoupper($myrows['stockid']), - mb_strtoupper($myrows['stockid']), - $myrows['description'], - 0); + echo '<td>' . InternalLink('', 'StockStatus.php?' . 'StockID=' . mb_strtoupper($myrows['stockid']), mb_strtoupper($myrows['stockid'])) . '</td> + <td>' . $myrows['description'] . '</td> + <td class="number">0</td>'; } else { - printf('<td><a target="_blank" href="StockStatus.php?%s">%s</td> - <td>%s</td> - <td class="number">%s</td>', - 'StockID=' . mb_strtoupper($myrows['stockid']), - mb_strtoupper($myrows['stockid']), - $myrows['description'], - locale_number_format($LocQtyRow['newqoh'],$myrows['decimalplaces'])); + echo '<td>' . InternalLink('', 'StockStatus.php?' . 'StockID=' . mb_strtoupper($myrows['stockid']), mb_strtoupper($myrows['stockid'])) . '</td> + <td>' . $myrows['description'] . '</td> + <td class="number">' . locale_number_format($LocQtyRow['newqoh'], $myrows['decimalplaces']) . '</td>'; $TotalQuantity += $LocQtyRow['newqoh']; } Modified: trunk/StockReorderLevel.php =================================================================== --- trunk/StockReorderLevel.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockReorderLevel.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -12,10 +12,8 @@ $StockID = trim(mb_strtoupper($_POST['StockID'])); } -echo '<a href="' . $rootpath . '/SelectProduct.php">' . _('Back to Items') . '</a>'; +echo InternalLink($rootpath, 'SelectProduct.php', _('Back to Items')); -echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Inventory') . '" alt="" /><b>' . $title. '</b></p>'; - $result = DB_query("SELECT description, units FROM stockmaster WHERE stockid='" . $StockID . "'", $db); $myrow = DB_fetch_array($result); @@ -41,6 +39,12 @@ $LocStockResult = DB_query($sql, $db, $ErrMsg, $DbgMsg); echo '<table cellpadding="2" class="selection">'; + +echo '<tr> + <th colspan="3" class="header"> + <img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Inventory') . '" alt="" /><b>' . $title. '</b> + </th> + </tr>'; echo '<tr><th colspan="3">'._('Stock Code') . ':<input type="text" name="StockID" size="21" value="' . $StockID . '" maxlength="20" />'; echo '<button type="submit" name="Show">' . _('Show Re-Order Levels') . '</button></th></tr>'; echo '<tr><th colspan="3" class="header"><b>' . $StockID . ' - ' . $myrow['description'] . '</b> (' . _('In Units of') . ' ' . $myrow['units'] . ')</th></tr>'; @@ -98,11 +102,11 @@ } //end of while loop -echo '</table><br /><div class="centre"><button type="submit" name="UpdateData">' . _('Update') . '</button><br /><br />'; -echo '<a href="' . $rootpath . '/StockMovements.php?StockID=' . $StockID . '">' . _('Show Stock Movements') . '</a>'; -echo '<br /><a href="' . $rootpath . '/StockUsage.php?StockID=' . $StockID . '">' . _('Show Stock Usage') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectSalesOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Outstanding Sales Orders') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectCompletedOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Completed Sales Orders') . '</a>'; +echo '</table><div class="centre"><button type="submit" name="UpdateData">' . _('Update') . '</button>'; +echo '<br />' . InternalLink($rootpath, 'StockMovements.php?StockID=' . $StockID, _('Show Stock Movements')); +echo '<br />' . InternalLink($rootpath, 'StockUsage.php?StockID=' . $StockID, _('Show Stock Usage')); +echo '<br />' . InternalLink($rootpath, 'SelectSalesOrder.php?SelectedStockItem=' . $StockID, _('Search Outstanding Sales Orders')); +echo '<br />' . InternalLink($rootpath, 'SelectCompletedOrder.php?SelectedStockItem=' . $StockID, _('Search Completed Sales Orders')); echo '</div></form>'; include('includes/footer.inc'); Modified: trunk/StockStatus.php =================================================================== --- trunk/StockStatus.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockStatus.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -16,9 +16,6 @@ $StockID = ''; } -// This is already linked from this page -//echo '<a href='" . $rootpath . '/SelectProduct.php'>" . _('Back to Items') . '</a><br />'; - $result = DB_query("SELECT description, units, mbflag, @@ -217,9 +214,9 @@ if ($Serialised ==1){ /*The line is a serialised item*/ - echo '<td><a target="_blank" href="' . $rootpath . '/StockSerialItems.php?Serialised=Yes&Location=' . $myrow['loccode'] . '&StockID=' .$StockID . '">' . _('Serial Numbers') . '</a></td></tr>'; + echo '<td>' . InternalLink($rootpath, 'StockSerialItems.php?Serialised=Yes&Location=' . $myrow['loccode'] . '&StockID=' .$StockID, _('Serial Numbers')) . '</td></tr>'; } elseif ($Controlled==1){ - echo '<td><a target="_blank" href="' . $rootpath . '/StockSerialItems.php?Location=' . $myrow['loccode'] . '&StockID=' .$StockID . '">' . _('Batches') . '</a></td></tr>'; + echo '<td>' . InternalLink($rootpath, 'StockSerialItems.php?Location=' . $myrow['loccode'] . '&StockID=' .$StockID, _('Batches')) . '</td></tr>'; } } else { @@ -346,12 +343,12 @@ } //end of displaying price history for a debtor echo '<div class="centre">'; -echo '<br /><a href="' . $rootpath . '/StockMovements.php?StockID=' . $StockID . '">' . _('Show Movements') . '</a>'; -echo '<br /><a href="' . $rootpath . '/StockUsage.php?StockID=' . $StockID . '">' . _('Show Usage') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectSalesOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Outstanding Sales Orders') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectCompletedOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Completed Sales Orders') . '</a>'; +echo '<br />' . InternalLink($rootpath, 'StockMovements.php?StockID=' . $StockID, _('Show Movements')); +echo '<br />' . InternalLink($rootpath, 'StockUsage.php?StockID=' . $StockID, _('Show Usage')); +echo '<br />' . InternalLink($rootpath, 'SelectSalesOrder.php?SelectedStockItem=' . $StockID, _('Search Outstanding Sales Orders')); +echo '<br />' . InternalLink($rootpath, 'SelectCompletedOrder.php?SelectedStockItem=' . $StockID, _('Search Completed Sales Orders')); if ($Its_A_KitSet_Assembly_Or_Dummy ==False){ - echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Outstanding Purchase Orders') . '</a>'; + echo '<br />' . InternalLink($rootpath, 'PO_SelectOSPurchOrder.php?SelectedStockItem=' . $StockID, _('Search Outstanding Purchase Orders')); } echo '</div></form>'; Modified: trunk/StockTransferControlled.php =================================================================== --- trunk/StockTransferControlled.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockTransferControlled.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -15,7 +15,7 @@ if (!isset($_SESSION['Transfer'])) { /* This page can only be called when a stock Transfer is pending */ - echo '<div class="centre"><a href="' . $rootpath . '/StockTransfers.php?NewTransfer=Yes">'._('Enter A Stock Transfer').'</a><br />'; + echo '<div class="centre">' . InternalLink($rootpath, 'StockTransfers.php?NewTransfer=Yes', _('Enter A Stock Transfer')) . '<br />'; prnMsg( _('This page can only be opened if a Stock Transfer for a Controlled Item has been initiated').'<br />','error'); echo '</div>'; include('includes/footer.inc'); @@ -41,9 +41,9 @@ //Make sure this item is really controlled if ($LineItem->Controlled != 1 ){ if (isset($TransferItem)){ - echo '<div class="centre"><a href="' . $rootpath . '/StockLocTransferReceive.php">'._('Receive A Stock Transfer').'</a></div>'; + echo '<div class="centre">' . InternalLink($rootpath, 'StockLocTransferReceive.php', _('Receive A Stock Transfer')) . '</div>'; } else { - echo '<div class="centre"><a href="' . $rootpath . '/StockTransfers.php?NewTransfer=Yes">'._('Enter A Stock Transfer').'</a></div>'; + echo '<div class="centre">' . InternalLink($rootpath, 'StockTransfers.php?NewTransfer=Yes', _('Enter A Stock Transfer')) . '</div>'; } prnMsg('<br />'. _('Notice') . ' - ' . _('The transferred item must be defined as controlled to require input of the batch numbers or serial numbers being transferred'),'error'); include('includes/footer.inc'); @@ -56,9 +56,9 @@ echo _('Transfer Items is set equal to') . ' ' . $TransferItem; - echo '<br /><a href="'.$rootpath.'/StockLocTransferReceive.php?StockID='.$LineItem->StockID.'">'._('Back To Transfer Screen').'</a>'; + echo '<br />' . InternalLink($rootpath, 'StockLocTransferReceive.php?StockID='.$LineItem->StockID, _('Back To Transfer Screen')); } else { - echo '<br /><a href="'.$rootpath.'/StockTransfers.php?StockID='.$LineItem->StockID. '">'._('Back To Transfer Screen').'</a>'; + echo '<br />' . InternalLink($rootpath, 'StockTransfers.php?StockID='.$LineItem->StockID, _('Back To Transfer Screen')); } echo '<br /><font size="2"><b>'. _('Transfer of controlled item'). ' ' . $LineItem->StockID . ' - ' . $LineItem->ItemDescription . '</b></font></div>'; Modified: trunk/StockTransfers.php =================================================================== --- trunk/StockTransfers.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockTransfers.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -42,8 +42,7 @@ while ($myrow = DB_fetch_array($result)) { echo '<tr><td>'.$myrow['stockid'].'</td> <td>'.$myrow['description'].'</td> - <td><a href="' . $rootpath . '/StockTransfers.php?StockID='.$myrow['stockid'].'&Description='.$myrow['description'].'&NewTransfer=Yes&Quantity='.$_POST['Quantity'].'&From='.$_POST['StockLocationFrom'].'&To='.$_POST['StockLocationTo'].'">' - ._('Transfer').'</a></td> + <td>' . InternalLink($rootpath, 'StockTransfers.php?StockID='.$myrow['stockid'].'&Description='.$myrow['description'].'&NewTransfer=Yes&Quantity='.$_POST['Quantity'].'&From='.$_POST['StockLocationFrom'].'&To='.$_POST['StockLocationTo'], _('Transfer')).'</td> </tr>'; } echo '</table>'; @@ -111,7 +110,7 @@ if ($myrow['mbflag']=='D' OR $myrow['mbflag']=='A' OR $myrow['mbflag']=='K'){ prnMsg(_('The part entered is either or a dummy part or an assembly or a kit-set part') . '. ' . _('These parts are not physical parts and no stock holding is maintained for them') . '. ' . _('Stock Transfers are therefore not possible'),'warn'); echo '.<hr>'; - echo '<a href="' . $rootpath . '/StockTransfers.php?NewTransfer=Yes">' . _('Enter another Transfer') . '</a>'; + echo InternalLink($rootpath, 'StockTransfers.php?NewTransfer=Yes', _('Enter another Transfer')); unset ($_SESSION['Transfer']); include ('includes/footer.inc'); exit; @@ -418,7 +417,7 @@ $Result = DB_Txn_Commit($db); prnMsg(_('An inventory transfer of').' ' . $_SESSION['Transfer']->TransferItem[0]->StockID . ' - ' . $_SESSION['Transfer']->TransferItem[0]->ItemDescription . ' '. _('has been created from').' ' . $_SESSION['Transfer']->StockLocationFrom . ' '. _('to') . ' ' . $_SESSION['Transfer']->StockLocationTo . ' '._('for a quantity of').' ' . $_SESSION['Transfer']->TransferItem[0]->Quantity,'success'); - echo '<br /><a href="PDFStockTransfer.php?TransferNo='.$TransferNumber.'">' . _('Print Transfer Note') . '</a>'; + echo '<br />' . InternalLink('', 'PDFStockTransfer.php?TransferNo='.$TransferNumber, _('Print Transfer Note')); unset ($_SESSION['Transfer']); include ('includes/footer.inc'); exit; @@ -476,7 +475,9 @@ echo '</select></td></tr>'; -echo '<tr><td>'. _('To Stock Location').': </td><td><select name="StockLocationTo"> '; +echo '<tr> + <td>'. _('To Stock Location').': </td> + <td><select name="StockLocationTo"> '; DB_data_seek($resultStkLocs,0); @@ -502,7 +503,7 @@ if (isset($_SESSION['Transfer']->TransferItem[0]->Controlled) and $_SESSION['Transfer']->TransferItem[0]->Controlled==1){ echo '<td class="number"><input type="hidden" name="Quantity" value="' . $_SESSION['Transfer']->TransferItem[0]->Quantity . '" /> - <a href="' . $rootpath .'/StockTransferControlled.php?StockLocationFrom='.$_SESSION['Transfer']->StockLocationFrom.'">' . $_SESSION['Transfer']->TransferItem[0]->Quantity . '</a></td></tr>'; + ' . InternalLink($rootpath, 'StockTransferControlled.php?StockLocationFrom='.$_SESSION['Transfer']->StockLocationFrom, $_SESSION['Transfer']->TransferItem[0]->Quantity) . '</td></tr>'; } elseif (isset($_SESSION['Transfer']->TransferItem[0]->Controlled)){ echo '<td><input type="text" class="number" name="Quantity" size="12" maxlength="12" value="' . $_SESSION['Transfer']->TransferItem[0]->Quantity . '" /></td></tr>'; } else { @@ -520,11 +521,11 @@ $StockID=''; } if (isset($_SESSION['Transfer'])) { - echo '<br /><a href="'.$rootpath.'/StockStatus.php?StockID=' . $StockID . '">'._('Show Stock Status').'</a>'; - echo '<br /><a href="'.$rootpath.'/StockMovements.php?StockID=' . $StockID . '">'._('Show Movements').'</a>'; - echo '<br /><a href="'.$rootpath.'/StockUsage.php?StockID=' . $StockID . '&StockLocation=' . $_SESSION['Transfer']->StockLocationFrom . '">' . _('Show Stock Usage') . '</a>'; - echo '<br /><a href="'.$rootpath.'/SelectSalesOrder.php?SelectedStockItem=' . $StockID . '&StockLocation=' . $_SESSION['Transfer']->StockLocationFrom . '">' . _('Search Outstanding Sales Orders') . '</a>'; - echo '<br /><a href="'.$rootpath.'/SelectCompletedOrder.php?SelectedStockItem=' . $StockID . '">'._('Search Completed Sales Orders').'</a>'; + echo '<br />' . InternalLink($rootpath, 'StockStatus.php?StockID=' . $StockID, _('Show Stock Status')); + echo '<br />' . InternalLink($rootpath, 'StockMovements.php?StockID=' . $StockID, _('Show Movements')); + echo '<br />' . InternalLink($rootpath, 'StockUsage.php?StockID=' . $StockID . '&StockLocation=' . $_SESSION['Transfer']->StockLocationFrom, _('Show Stock Usage')); + echo '<br />' . InternalLink($rootpath, 'SelectSalesOrder.php?SelectedStockItem=' . $StockID . '&StockLocation=' . $_SESSION['Transfer']->StockLocationFrom , _('Search Outstanding Sales Orders')); + echo '<br />' . InternalLink($rootpath, 'SelectCompletedOrder.php?SelectedStockItem=' . $StockID, _('Search Completed Sales Orders')); } echo '</div></form>'; include('includes/footer.inc'); Modified: trunk/StockUsage.php =================================================================== --- trunk/StockUsage.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/StockUsage.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -20,7 +20,7 @@ echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/StockUsageGraph.php?StockLocation=' . $_POST['StockLocation'] . '&StockID=' . $StockID . '">'; echo '<p>' . _('You should automatically be forwarded to the usage graph') . '. ' . _('If this does not happen') .' (' . _('if the browser does not support META Refresh') . ') ' . - '<a href="' . $rootpath . '/StockUsageGraph.php?StockLocation=' . $_POST['StockLocation'] .'&StockID=' . $StockID . '">' . _('click here') . '</a> ' . _('to continue') . '.</p><br />'; + InternalLink($rootpath, 'StockUsageGraph.php?StockLocation=' . $_POST['StockLocation'] .'&StockID=' . $StockID, _('click here')) . _('to continue') . '.</p><br />'; exit; } @@ -170,12 +170,12 @@ echo '</table>'; } /* end if Show Usage is clicked */ -echo '<br /><div class="centre">'; -echo '<a href="' . $rootpath . '/StockStatus.php?StockID=' . $StockID . '">' . _('Show Stock Status') .'</a>'; -echo '<br /><a href="' . $rootpath . '/StockMovements.php?StockID=' . $StockID . '&StockLocation=' . $_POST['StockLocation'] . '">' . _('Show Stock Movements') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectSalesOrder.php?SelectedStockItem=' . $StockID . '&StockLocation=' . $_POST['StockLocation'] . '">' . _('Search Outstanding Sales Orders') . '</a>'; -echo '<br /><a href="' . $rootpath . '/SelectCompletedOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Completed Sales Orders') . '</a>'; -echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?SelectedStockItem=' . $StockID . '">' . _('Search Outstanding Purchase Orders') . '</a>'; +echo '<div class="centre">'; +echo '<br />' . InternalLink($rootpath, 'StockStatus.php?StockID=' . $StockID, _('Show Stock Status')); +echo '<br />' . InternalLink($rootpath, 'StockMovements.php?StockID=' . $StockID . '&StockLocation=' . $_POST['StockLocation'], _('Show Stock Movements')); +echo '<br />' . InternalLink($rootpath, 'SelectSalesOrder.php?SelectedStockItem=' . $StockID . '&StockLocation=' . $_POST['StockLocation'], _('Search Outstanding Sales Orders')); +echo '<br />' . InternalLink($rootpath, 'SelectCompletedOrder.php?SelectedStockItem=' . $StockID, _('Search Completed Sales Orders')); +echo '<br />' . InternalLink($rootpath, 'PO_SelectOSPurchOrder.php?SelectedStockItem=' . $StockID, _('Search Outstanding Purchase Orders')); echo '</form></div>'; include('includes/footer.inc'); Modified: trunk/Stocks.php =================================================================== --- trunk/Stocks.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/Stocks.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -35,7 +35,7 @@ $New=$_POST['New']; } -echo '<a href="' . $rootpath . '/SelectProduct.php">' . _('Back to Items') . '</a><br />' . "\n"; +echo InternalLink($rootpath, 'SelectProduct.php', _('Back to Items')) . '<br />'; echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/inventory.png" title="' . _('Stock') . '" alt="" />' . ' ' . $title . '</p>'; @@ -66,7 +66,11 @@ if ($UploadTheFile=='Yes'){ $result = move_uploaded_file($_FILES['ItemPicture']['tmp_name'], $filename); - $message = ($result)?_('File url') .'<a href="'. $filename .'">' . $filename . '</a>' : _('Something is wrong with uploading a file'); + if ($result) { + $message = ('File url') . InternalLink('', $filename, $filename); + } else { + $message = _('Something is wrong with uploading a file'); + } } /* EOR Add Image upload for New Item - by Ori */ } @@ -911,7 +915,7 @@ $_POST['CategoryID']=$Category; } -echo '</select> <a target="_blank" href="'. $rootpath . '/StockCategories.php">' . _('Add or Modify Stock Categories') . '</a></td></tr>'; +echo '</select> ' . InternalLink($rootpath, 'StockCategories.php', _('Add or Modify Stock Categories')) . '</td></tr>'; if (!isset($_POST['EOQ']) or $_POST['EOQ']==''){ $_POST['EOQ']=0; Modified: trunk/SuppCreditGRNs.php =================================================================== --- trunk/SuppCreditGRNs.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/SuppCreditGRNs.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -24,7 +24,7 @@ if (!isset($_SESSION['SuppTrans'])){ prnMsg(_('To enter a supplier transactions the supplier must first be selected from the supplier selection screen') . ', ' . _('then the link to enter a supplier credit note must be clicked on'),'info'); - echo '<br /><a href="' . $rootpath . '/SelectSupplier.php">' . _('Select A Supplier to Enter a Transaction For') . '</a>'; + echo '<br />' . InternalLink($rootpath, 'SelectSupplier.php', _('Select A Supplier to Enter a Transaction For')); include('includes/footer.inc'); exit; /*It all stops here if there aint no supplier selected and credit note initiated ie $_SESSION['SuppTrans'] started off*/ @@ -89,13 +89,15 @@ foreach ($_SESSION['SuppTrans']->GRNs as $EnteredGRN){ - echo '<tr><td>' . $EnteredGRN->GRNNo . '</td> + echo '<tr> + <td>' . $EnteredGRN->GRNNo . '</td> <td>' . $EnteredGRN->ItemCode . '</td> <td>' . $EnteredGRN->ItemDescription . '</td> <td class="number">' . locale_number_format($EnteredGRN->This_QuantityInv,$EnteredGRN->DecimalPlaces) . '</td> <td class="number">' . locale_money_format($EnteredGRN->ChgPrice,$_SESSION['SuppTrans']->CurrCode) . '</td> <td class="number">' . locale_money_format($EnteredGRN->ChgPrice * $EnteredGRN->This_QuantityInv,$_SESSION['SuppTrans']->CurrCode) . '</td> - <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?Delete=' . $EnteredGRN->GRNNo . '">' . _('Delete') . '</a></td></tr>'; + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?Delete=' . $EnteredGRN->GRNNo, _('Delete')) . '</td> + </tr>'; $TotalValueCharged = $TotalValueCharged + ($EnteredGRN->ChgPrice * $EnteredGRN->This_QuantityInv); @@ -108,7 +110,7 @@ echo '<tr><th colspan="5" class="header">' . _('Total Value Credited Against Goods') . ':</th> <th class="header"><u>' . locale_money_format($TotalValueCharged,$_SESSION['SuppTrans']->CurrCode) . '</u></th></tr>'; -echo '</table><br /><div class="centre"><a href="' . $rootpath . '/SupplierCredit.php">' . _('Back to Credit Note Entry') . '</a></div>'; +echo '</table><br /><div class="centre">' . InternalLink($rootpath, 'SupplierCredit.php', _('Back to Credit Note Entry')) . '</div>'; /* Now get all the GRNs for this supplier from the database after the date entered */ @@ -197,7 +199,7 @@ if (DB_num_rows($GRNResults)==0){ prnMsg(_('There are no goods received records for') . ' ' . $_SESSION['SuppTrans']->SupplierName . '<br /> ' . _('To enter a credit against goods received') . ', ' . - _('the goods must first be received using') . ' <a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?SupplierID=' . $_SESSION['SuppTrans']->SupplierID . '">' . _('this link') . ' </a>' . + _('the goods must first be received using') . InternalLink($rootpath, 'PO_SelectOSPurchOrder.php?SupplierID=' . $_SESSION['SuppTrans']->SupplierID, _('this link')) . _('to select purchase orders to receive'),'info'); echo '<br />'; // include('includes/footer.inc'); Modified: trunk/SupplierAllocations.php =================================================================== --- trunk/SupplierAllocations.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/SupplierAllocations.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -569,56 +569,50 @@ } echo '<table class="selection">'; - $TableHeader = '<tr><th>' . _('Trans Type') . - '</th><th>' . _('Supplier') . - '</th><th>' . _('Number') . - '</th><th>' . _('Date') . - '</th><th>' . _('Total') . - '</th><th>' . _('To Alloc') . '</th></tr>'. "\n"; + $TableHeader = '<tr> + <th>' . _('Trans Type') . '</th> + <th>' . _('Supplier') . '</th> + <th>' . _('Number') . '</th> + <th>' . _('Date') . '</th> + <th>' . _('Total') . '</th> + <th>' . _('To Alloc') . '</th> + </tr>'; - echo $TableHeader; + echo $TableHeader; - /* set up table of TransType - Supplier - Trans No - Date - Total - Left to alloc */ + /* set up table of TransType - Supplier - Trans No - Date - Total - Left to alloc */ - $RowCounter = 0; - $k = 0; //row colour counter - while ($myrow = DB_fetch_array($result)) { - if ($k == 1){ - echo '<tr class="EvenTableRows">'; - $k = 0; - } else { - echo '<tr class="OddTableRows">'; - $k = 1; - } + $RowCounter = 0; + $k = 0; //row colour counter + while ($myrow = DB_fetch_array($result)) { + if ($k == 1){ + echo '<tr class="EvenTableRows">'; + $k = 0; + } else { + echo '<tr class="OddTableRows">'; + $k = 1; + } - printf('<td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%0.2f</td> - <td class="number">%0.2f</td> - <td><a href="%sAllocTrans=%s">' . _('Allocate') .'</td> - </tr>', - $myrow['typename'], - $myrow['suppname'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - locale_money_format($myrow['total'],$myrow['currcode']), - locale_money_format($myrow['total']-$myrow['alloc'],$myrow['currcode']), - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') .'?', - $myrow['id']); + echo '<td>' . $myrow['typename'] . '</td> + <td>' . $myrow['suppname'] . '</td> + <td>' . $myrow['transno'] . '</td> + <td>' . ConvertSQLDate($myrow['trandate']) . '</td> + <td class="number">' . locale_money_format($myrow['total'],$myrow['currcode']) . '</td> + <td class="number">' . locale_money_format($myrow['total']-$myrow['alloc'],$myrow['currcode']) . '</td> + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') .'?AllocTrans=' . $myrow['id'], _('Allocate')) .'</td> + </tr>'; - } + } } else { /* show all outstanding payments and credits to be allocated */ - /*Clear any previous allocation records */ + /*Clear any previous allocation records */ - unset($_SESSION['Alloc']->Allocs); - unset($_SESSION['Alloc']); + unset($_SESSION['Alloc']->Allocs); + unset($_SESSION['Alloc']); - $sql = "SELECT id, - transno, + $sql = "SELECT id, + transno, typename, type, suppliers.supplierid, @@ -663,22 +657,14 @@ $k = 1; } - printf('<td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td><a href="%sAllocTrans=%s">' . _('Allocate') . '</td> - </tr>', - $myrow['typename'], - $myrow['suppname'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - locale_money_format($myrow['total'],$myrow['currcode']), - locale_money_format($myrow['total']-$myrow['alloc'],$myrow['currcode']), - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') .'?', - $myrow['id']); + echo '<td>' . $myrow['typename'] . '</td> + <td>' . $myrow['suppname'] . '</td> + <td>' . $myrow['transno'] . '</td> + <td>' . ConvertSQLDate($myrow['trandate']) . '</td> + <td class="number">' . locale_money_format($myrow['total'],$myrow['currcode']) . '</td> + <td class="number">' . locale_money_format($myrow['total']-$myrow['alloc'],$myrow['currcode']) . '</td> + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') .'?AllocTrans=' . $myrow['id'], _('Allocate')) . '</td> + </tr>'; } //END WHILE LIST LOOP Modified: trunk/SupplierBalsAtPeriodEnd.php =================================================================== --- trunk/SupplierBalsAtPeriodEnd.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/SupplierBalsAtPeriodEnd.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -54,7 +54,7 @@ $title = _('Supplier Balances - Problem Report'); include('includes/header.inc'); prnMsg(_('The Supplier details could not be retrieved by the SQL because') . ' ' . DB_error_msg($db),'error'); - echo '<br /><a href="' . $rootpath . '/index.php">' . _('Back to the menu') . '</a>'; + echo '<br />' . InternalLink($rootpath, 'index.php', _('Back to the menu')); if ($debug==1){ echo '<br />' . $SQL; } @@ -65,7 +65,7 @@ $title = _('Supplier Balances - Problem Report'); include('includes/header.inc'); prnMsg(_('There are no supplier balances to list'),'error'); - echo '<br /><a href="' . $rootpath . '/index.php">' . _('Back to the menu') . '</a>'; + echo '<br />' . InternalLink($rootpath, 'index.php', _('Back to the menu')); include('includes/footer.inc'); exit; } Modified: trunk/SupplierContacts.php =================================================================== --- trunk/SupplierContacts.php 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/SupplierContacts.php 2012-08-23 16:53:15 UTC (rev 9547) @@ -15,7 +15,7 @@ $SupplierID = $_POST['SupplierID']; } -echo '<a href="' . $rootpath . '/SelectSupplier.php">' . _('Back to Suppliers') . '</a><br />'; +echo InternalLink($rootpath, '/SelectSupplier.php', _('Back to Suppliers')) . '<br />'; echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/transactions.png" title="' . _('Supplier Allocations') . '" alt="" />' . ' ' . $title . '</p>'; @@ -145,25 +145,15 @@ <th>' . _('Email') . '</th></tr>'; DB_data_seek($result, 0); while ($myrow = DB_fetch_array($result)) { - printf('<tr><td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td><a href="mailto:%s">%s</td> - <td><a href="%s?SupplierID=%s&SelectedContact=%s">' . _('Edit') . '</td> - <td><a href="%s?SupplierID=%s&SelectedContact=%s&delete=yes" onclick=\'return confirm("' . _('Are you sure you wish to delete this contact?') . '");\'>' . _('Delete') . '</td></tr>', - $myrow['contact'], - $myrow['position'], - $myrow['tel'], - $myrow['fax'], - $myrow['email'], - $myrow['email'], - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'), - $SupplierID, - $myrow['contact'], - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'), - $SupplierID, - $myrow['contact']); + echo '<tr> + <td>' . $myrow['contact'] . '</td> + <td>' . $myrow['position'] . '</td> + <td>' . $myrow['tel'] . '</td> + <td>' . $myrow['fax'] . '</td> + <td>' . $myrow['email'] . '</td> + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?SupplierID=' . $SupplierID . '&SelectedContact=' . $myrow['contact'], _('Edit')) . '</td> + <td>' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?SupplierID=' . $SupplierID . '&SelectedContact=' . $myrow['contact'] . '&delete=yes', _('Delete')) . '</td> + </tr>'; } } else { prnMsg(_('There are no contacts defined for this supplier'),'info'); @@ -176,8 +166,7 @@ echo '</table><br />'; if (isset($SelectedContact)) { - echo '<div class="centre"><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?SupplierID=$SupplierID">' . - _('Show all the supplier contacts for') . ' ' . $SupplierID . '</a></div></p>'; + echo '<div class="centre">' . InternalLink('', htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '?SupplierID=' . $SupplierID, _('Show all the supplier contacts for') . ' ' . $SupplierID) . '</div>'; } if (! isset($_GET['delete'])) { @@ -243,7 +232,7 @@ <td><input type="text" name="Fax" size="31" maxlength="30" value="' . $_POST['Fax'] . '" /></td></tr> <tr><td>' . _('Mobile No') . ':</td> <td><input type="text" name="Mobile" size="31" maxlength="30" value="' . $_POST['Mobile'] . '" /></td></tr> - <tr><td><a href="Mailto:' . $_POST['Email'] . '">' . _('Email') . ':</a></td> + <tr><td>' . _('Email') . ':</td> <td><input type="text" name="Email" size="51" maxlength="50" value="' . $_POST['Email'] . '" /></td></tr> </table><br />'; Modified: trunk/css/silverwolf/images/inventory.png =================================================================== --- trunk/css/silverwolf/images/inventory.png 2012-08-22 21:13:13 UTC (rev 9546) +++ trunk/css/silverwolf/images/inventory.png 2012-08-23 16:53:15 UTC (rev 9547) @@ -1,11 +1,33 @@ \x89PNG |