How to use "getCurrentSelectionCfi()" on iOS?

2 posts / 0 new
Last post

I'd like to use the "getCurrentSelectionCfi()" in readium API using by iOS sample source(github.com/readium/SDKLauncher-iOS),
so I called the methods on iOS like below:
NSString *result = [m_webView stringByEvaluatingJavaScriptFromString:@"ReadiumSDK.reader.getCurrentSelectionCfi()"];

But the "result" is null, and I debug on Safari, I found the error below:
TypeError: ReadiumSDK.reader.getCurrentSelectionCfi is not a function. (In 'ReadiumSDK.reader.getCurrentSelectionCfi()', 'ReadiumSDK.reader.getCurrentSelectionCfi' is undefined)

Would you tell me how to solve this?

Can you re-post this question on the readium-sdk issue tracker:

https://github.com/readium/readium-sdk/issues

That is more likely to get a quick response from one of the developers.

Thanks, RIc Wright

Secondary menu