mlandis / phylowood

Browser-based Interactive Phylogeographic Animations
http://mlandis.github.com/phylowood/
20 stars 9 forks source link

FileReader support in Chrome and Safari #1

Closed trvrb closed 12 years ago

trvrb commented 12 years ago

On my Mac, file parsing works great in Firefox, but doesn't work at all in Chrome or Safari. With Chrome I get the following:

Uncaught TypeError: Cannot call method 'split' of undefined 

This is occurring because inputStr is undefined.

In Safari I get:

ReferenceError: Can't find variable: FileReader
TypeError: 'undefined' is not an object (evaluating 'inputStr.split')

I'll look into Chrome and Safari alternatives.

mlandis commented 12 years ago

For Chrome, there's a default security feature that disallows the application local file access. FileReader behaves properly when you run Chrome with the "--allow-file-access-from-files" flag. I found this resolved the issue for my Chromium installation.

For Safari, it appears to be unsupported entirely: http://caniuse.com/filereader

trvrb commented 12 years ago

On Mac, launch Google Chrome with:

/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --allow-file-access-from-files &> /dev/null &

trvrb commented 12 years ago

It looks like the web input has made this a moot issue.