def netconf_read(request): if is_signed_in(request): return render_to_response('ip.html',{'netinfo':netconf.read()}) return HttpResponseRedirect('/')
def read(request): inf = etree.tostring(netconf.read(), encoding='UTF-8', xml_declaration=True, pretty_print=True) return HttpResponse(inf,mimetype='text/xml')