inserted js code for view in demo page