Homec4science

WebStyle: avoid double-escaping title in page header

Authored by Jerome Caffaro <jerome.caffaro@cern.ch> on Dec 14 2011, 14:59.

Description

WebStyle: avoid double-escaping title in page header

  • Changed websearch_templates.tmpl_record_page_header_content() to not return escaped output. Escape title/description/keyword only when needed. Changed webstyle.tmpl_pageheader() to escape quotes in description/keywords.
  • Clarified usage of some functions wrt escaping of input parameters and returned output.
  • If you have modified webstyle_templates.tmpl_pageheader() function, ensure that you use 'cgi.escape(description, True)' and 'cgi.escape(keywords, True)' when preparing for description and keyword header tag.
  • If you have modified websearch_templates.tmpl_record_page_header_content() function, make sure that you do not return escaped output.

Details

Committed
Tibor Simko <tibor.simko@cern.ch>Jan 6 2012, 15:24
Parents
R3600:b7a3472c8383: WebJournal: update weather widget for new APIs
Branches
Unknown
Tags
Unknown

Event Timeline

Tibor Simko <tibor.simko@cern.ch> committed R3600:cc219c8a1b95: WebStyle: avoid double-escaping title in page header (authored by Jerome Caffaro <jerome.caffaro@cern.ch>).Jan 6 2012, 15:24