def copy_query_dict(query_dict, attr_list):
 res = QueryDict('', mutable=True)
 for attr in attr_list:
  if query_dict.has_key(attr):
   res[attr] = query_dict.get(attr)
 return res

def copy_query_dict ( query_dict , attr_list ) : res = QueryDict ( '' , mutable = True ) for attr in attr_list : if query_dict . has_key ( attr ) : res [ attr ] = query_dict . get ( attr ) return res
copy_query_dict -> querydict object copy the specified attributes to a new querydict .