我正在尝试创建一个链接到另一个应用程序的按钮。
出于某种原因,这有效:
<a href="{% url 'ridesharing:ride-list' %}" target="blank">Find a ride</a>
但这不是:
<button type="button" class="btn btn-xl" style=" border-color: rgb(2,132,69); background-color: rgb(2,132,69); color: rgb(246,246,247); font-family: Verdana;font-size: large" href="{% url 'ridesharing:ride-list' %}">Find a ride</button>
我正在使用按钮,因为我喜欢如何自定义它的外观。如何让按钮链接到正确的应用程序。
答案 0 :(得分:0)
让按钮提交一个表格,其中URL为表格的 --author=<pattern>, --committer=<pattern>
Limit the commits output to ones with author/committer header lines that match
the specified pattern (regular expression). With more than one
--author=<pattern>, commits whose author matches any of the given patterns are
chosen (similarly for multiple --committer=<pattern>).
--grep=<pattern>
Limit the commits output to ones with log message that matches the specified
pattern (regular expression). With more than one --grep=<pattern>, commits whose
message matches any of the given patterns are chosen (but see --all-match).
When --show-notes is in effect, the message from the notes is matched as if it
were part of the log message.
action
或添加更改<form action="{% url 'ridesharing:ride-list' %}">
<button type="submit" class="btn btn-xl" style=" border-color: rgb(2,132,69); background-color: rgb(2,132,69); color: rgb(246,246,247); font-family: Verdana;font-size: large">Find a ride</button>
</form>
window.location.href