mirror of
https://github.com/sileht/bird-lg.git
synced 2024-11-21 14:34:43 +01:00
Merge pull request #52 from tamihiro/new-pr-batch-4
Encode `+` when it appears in URL.
This commit is contained in:
commit
fa1c071682
|
@ -14,7 +14,7 @@ function reload(){
|
|||
loc = "/" + request_type + "/" + hosts + "/" + proto;
|
||||
if (request_type != "summary" ){
|
||||
if( request_args != undefined && request_args != ""){
|
||||
loc = loc + "?q=" + escape(request_args);
|
||||
loc = loc + "?q=" + encodeURIComponent(request_args);
|
||||
change_url(loc)
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -84,7 +84,7 @@
|
|||
<li class="nav-header">Request history</li>
|
||||
{% for hosts, proto, request_type, request_args in session.history %}
|
||||
<li{% if loop.first %} class="active"{% endif %}>
|
||||
<a href="/{{ [request_type, hosts, proto]|join("/") }}{% if request_args %}?q={{request_args}}{% endif %}">
|
||||
<a href="/{{ [request_type, hosts, proto]|join("/") }}{% if request_args %}?q={{request_args|urlencode}}{% endif %}">
|
||||
{{hosts}}/{{proto}}: {{ commands_dict[request_type]|replace("...", request_args) }}
|
||||
</a>
|
||||
</li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
{% for host in detail %}
|
||||
<h3>
|
||||
{{host}}: {{command}}
|
||||
<small><a class="pull-right" href="/{{session.request_type|replace("_detail","")}}_bgpmap/{{session.hosts}}/{{session.proto}}?q={{session.request_args}}">View the BGP map</a></small>
|
||||
<small><a class="pull-right" href="/{{session.request_type|replace("_detail","")}}_bgpmap/{{session.hosts}}/{{session.proto}}?q={{session.request_args|urlencode}}">View the BGP map</a></small>
|
||||
</h3>
|
||||
{% if session.request_args != expression|replace("/32","")|replace("/128","") %}
|
||||
<i>DNS: <a href="/whois/{{session.request_args}}" class="whois">{{session.request_args}}</a> => <a href="/whois/{{ expression|replace("/32","")|replace("/128","") }}" class="whois">{{expression|replace("/32","")|replace("/128","")}}</a></i><br />
|
||||
|
|
Loading…
Reference in a new issue