xiuli.gao 6 years ago
parent
commit
86d85dd7b0
1 changed files with 3 additions and 1 deletions
  1. 3 1
      shareBooks/invitingFriends.html

+ 3 - 1
shareBooks/invitingFriends.html

179
 	    	if(we_chat_Arr[i].indexOf('redirect_uri') != -1){
179
 	    	if(we_chat_Arr[i].indexOf('redirect_uri') != -1){
180
 	    		redirect_uri = we_chat_Arr[i].split('=')[1];
180
 	    		redirect_uri = we_chat_Arr[i].split('=')[1];
181
 	    		redirect_uri = decodeURIComponent(redirect_uri)
181
 	    		redirect_uri = decodeURIComponent(redirect_uri)
182
-	    		we_chat_Arr[i] = "redirect_uri=" + redirect_uri + "?book_id=" + book_id + "&cid=" + cid
182
+	    		var redirect = redirect_uri + "?book_id=" + book_id + "&cid=" + cid;
183
+	    		redirect = encodeURIComponent(redirect);
184
+	    		we_chat_Arr[i] = "redirect_uri=" + redirect;
183
 	    	}
185
 	    	}
184
     	}
186
     	}
185
     	wechat = we_chat_Arr.join("&")
187
     	wechat = we_chat_Arr.join("&")