mirror of
https://github.com/twisterarmy/twister-html.git
synced 2025-01-13 16:37:52 +00:00
fix multi-byte character hashtag
This commit is contained in:
parent
75de1b9ef2
commit
49292bf61e
@ -174,7 +174,7 @@ function openHashtagModal(e)
|
||||
|
||||
function openHashtagModalFromSearch(hashtag)
|
||||
{
|
||||
window.location.hash = '#hashtag?hashtag=' + hashtag;
|
||||
window.location.hash = '#hashtag?hashtag=' + encodeURIComponent(hashtag);
|
||||
}
|
||||
|
||||
function openHashtagModalFromSearchHandler(hashtag)
|
||||
|
@ -307,7 +307,7 @@ function requestHashtag(postboard,hashtag,resource, timeoutArgs) {
|
||||
}
|
||||
|
||||
function processHashtag(postboard, hashtag, data) {
|
||||
if( data && window.location.hash.indexOf(hashtag) != -1 ) {
|
||||
if( data && window.location.hash.indexOf(encodeURIComponent(hashtag)) != -1 ) {
|
||||
for( var i = data.length-1; i >= 0; i-- ) {
|
||||
var userpost = data[i]["userpost"];
|
||||
var key = userpost["n"] + ";" + userpost["time"];
|
||||
|
Loading…
Reference in New Issue
Block a user