moving inline js out from db_designer.lib.php plus minor bug fixes

Signed-off-by: Smita Kumari <kumarismita62@gmail.com>
resolve conflict

Signed-off-by: Smita Kumari <kumarismita62@gmail.com>
remove trailing white spaces

Signed-off-by: Smita Kumari <kumarismita62@gmail.com>
fixing coding style

Signed-off-by: Smita Kumari <kumarismita62@gmail.com>
Merge pull request #1383 from smita786/master

moving out inline js from db_designer.lib.php plus minor bug fixes