[
https://issues.apache.org/jira/browse/WICKET-6232?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15435815#comment-15435815
]
ASF subversion and git services commented on WICKET-6232:
---------------------------------------------------------
Commit f4a6996aa4c3240b31ba191ef396864bf0dfad6c in wicket's branch
refs/heads/wicket-7.x from [~mgrigorov]
[ https://git-wip-us.apache.org/repos/asf?p=wicket.git;h=f4a6996 ]
WICKET-6232 When sending binary data from server to client,
wicket-websocket-jquery.js throws error "message.indexOf is not a function"
> When sending binary data from server to client, wicket-websocket-jquery.js
> throws error "message.indexOf is not a function"
> ---------------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-6232
> URL: https://issues.apache.org/jira/browse/WICKET-6232
> Project: Wicket
> Issue Type: Bug
> Components: wicket-native-websocket
> Affects Versions: 7.4.0
> Reporter: C Quarters
> Assignee: Martin Grigorov
> Priority: Minor
>
> On the server I'm calling this method
> org.apache.wicket.protocol.ws.api.IWebSocketConnection.sendMessage(byte[]
> message, int offset, int length)
> The Wicket javascript client code (wicket-websocket-jquery.js) assumes the
> incoming message is a string and attempts to detect if it's an ajax response.
> self.ws.onmessage = function (event) {
> var message = event.data;
> if (message && message.indexOf('<ajax-response>') > -1) {
> var call = new Wicket.Ajax.Call();
> call.process(message);
> }
> else {
> Wicket.Event.publish(topics.Message, message);
> }
> };
> https://github.com/apache/wicket/blob/master/wicket-native-websocket/wicket-native-websocket-core/src/main/java/org/apache/wicket/protocol/ws/api/res/js/wicket-websocket-jquery.js
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)