Python 更改'';至'&';地址栏中的
例如,在我的web应用程序中,我有一个url www.example.com/profile?name=name的链接。当我点击该链接时,我会看到一个页面,在那里我可以更改配置文件的信息,但是点击该链接后,地址栏中的url会变成www.example.com/profile&name=name 更有趣的是:当我做一些更改并单击“保存”时,url将恢复为www.example.com/profile?name=name 若我并没有点击保存,只是刷新页面,我得到了错误404 怎么可能呢 p.S我的视图功能Python 更改'';至'&';地址栏中的,python,django,Python,Django,例如,在我的web应用程序中,我有一个url www.example.com/profile?name=name的链接。当我点击该链接时,我会看到一个页面,在那里我可以更改配置文件的信息,但是点击该链接后,地址栏中的url会变成www.example.com/profile&name=name 更有趣的是:当我做一些更改并单击“保存”时,url将恢复为www.example.com/profile?name=name 若我并没有点击保存,只是刷新页面,我得到了错误404 怎么可能呢 p.S我的视
@check_document_access_permission()
def notebook(request, is_embeddable=False):
if not SHOW_NOTEBOOKS.get():
return serve_403_error(request)
notebook_id = request.GET.get('notebook', request.GET.get('editor'))
is_yarn_mode = False
try:
from spark.conf import LIVY_SERVER_SESSION_KIND
is_yarn_mode = LIVY_SERVER_SESSION_KIND.get()
except:
LOG.exception('Spark is not enabled')
return render('notebook.mako', request, {
'editor_id': notebook_id or None,
'notebooks_json': '{}',
'is_embeddable': request.GET.get('is_embeddable', False),
'options_json': json.dumps({
'languages': get_ordered_interpreters(request.user),
'session_properties': SparkApi.get_properties(),
'is_optimizer_enabled': has_optimizer(),
'is_navigator_enabled': has_navigator(request.user),
'editor_type': 'notebook'
}),
'is_yarn_mode': is_yarn_mode,
})
我发现了错误
前端是JS函数,它错误地更改了url。为post添加了代码。您的相关url条目是什么样子的?