Revision: 2509
https://sourceforge.net/p/mrbs/code/2509/
Author: cimorrison
Date: 2012-10-19 14:19:11 +0000 (Fri, 19 Oct 2012)
Log Message:
-----------
Fixed bug causing booking name to be erased when dragging a booking
Modified Paths:
--------------
mrbs/branches/improved_repeat_interface/web/edit_entry_handler.php
Modified: mrbs/branches/improved_repeat_interface/web/edit_entry_handler.php
===================================================================
--- mrbs/branches/improved_repeat_interface/web/edit_entry_handler.php
2012-10-17 21:09:43 UTC (rev 2508)
+++ mrbs/branches/improved_repeat_interface/web/edit_entry_handler.php
2012-10-19 14:19:11 UTC (rev 2509)
@@ -225,17 +225,6 @@
unset($id);
}
-// Trim the name field to get rid of any leading or trailing whitespace
-$name = trim($name);
-// Truncate the name field to the maximum length as a precaution.
-// Although the MAXLENGTH attribute is used in the <input> tag, this can
-// sometimes be ignored by the browser, for example by Firefox when
-// autocompletion is used. The user could also edit the HTML and remove
-// the MAXLENGTH attribute. Passing an oversize string to some
-// databases (eg some versions of PostgreSQL) results in an SQL error,
-// rather than silent truncation of the string.
-$name = substr($name, 0, $maxlength['entry.name']);
-
// Make sure the area corresponds to the room that is being booked
if (!empty($rooms[0]))
{
@@ -333,6 +322,17 @@
}
}
+// Trim the name field to get rid of any leading or trailing whitespace
+$name = trim($name);
+// Truncate the name field to the maximum length as a precaution.
+// Although the MAXLENGTH attribute is used in the <input> tag, this can
+// sometimes be ignored by the browser, for example by Firefox when
+// autocompletion is used. The user could also edit the HTML and remove
+// the MAXLENGTH attribute. Passing an oversize string to some
+// databases (eg some versions of PostgreSQL) results in an SQL error,
+// rather than silent truncation of the string.
+$name = substr($name, 0, $maxlength['entry.name']);
+
// When All Day is checked, $start_seconds and $end_seconds are disabled and
so won't
// get passed through by the form. We therefore need to set them.
if (!empty($all_day))
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
_______________________________________________
Mrbs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mrbs-commits