$power_by = "FrontAccounting";
$power_url = "http://frontaccounting.com";
+ /* No check on edit conflicts. Maybe needed to be set to 1 in certains Windows Servers */
+ $no_check_edit_conflicts = 0;
+
/* Do not print zero lines amount of 0.00 in Sales Documents if service item. 1 = do not */
$no_zero_lines_amount = 1;
$_SESSION['EXPIRES'] = time() + 10;
// Create new session without destroying the old one
- session_regenerate_id(version_compare(PHP_VERSION, '5.1.0') >= 0 && (substr(strtoupper(PHP_OS),0,3) == "WIN"));
-
+ session_regenerate_id();
// Grab current session ID and close both sessions to allow other scripts to use them
$newSession = session_id();
session_write_close();
*/
function check_edit_conflicts($cartname='Items')
{
- global $Ajax;
+ global $Ajax, $no_check_edit_conflicts;
- if (get_post('cart_id') && $_POST['cart_id'] != $_SESSION[$cartname]->cart_id) {
+ if ((!isset($no_check_edit_conflicts) || $no_check_edit_conflicts==0) && get_post('cart_id') && $_POST['cart_id'] != $_SESSION[$cartname]->cart_id) {
display_error(_('This edit session has been abandoned by opening sales document in another browser tab. You cannot edit more than one sales document at once.'));
$Ajax->activate('_page_body');
display_footer_exit();