security bug fixes

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

Fix coding style

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

use existing escapeHtml function

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