1. 程式人生 > >context must be a dict rather than Context

context must be a dict rather than Context

context instance book ict str con klist end list

render_to_string() got an unexpected keyword argument ‘context_instance‘

context must be a dict rather than RequestContext
解決辦法:

返回的context應該是字典
context = {‘booklist‘: booklist}

context must be a dict rather than Context