File uploading (type:'file')

Source code: Survey setup
Survey.defaultBootstrapCss.navigationButton = "btn btn-primary";
Survey.Survey.cssType = "bootstrap";
var survey = new Survey.Model({ questions: [
    { type: "file", title: "Please upload your photo", name: "image", storeDataAsText: true, showPreview: true, imageWidth: 150, maxSize: 102400 }
]});

$("#surveyElement").Survey({model:survey});

Preview the image: default is false.

survey.getQuestionByName('image').showPreview = yourValue; survey.render();

Store file content directoy in data JSON: default is false.

survey.getQuestionByName('image').storeDataAsText = yourValue; survey.render();

Image Preview Height: default is empty.

survey.getQuestionByName('image').imageHeight; survey.render();

Image Preview Width: default is empty.

survey.getQuestionByName('image').imageWidth; survey.render();

File Max Size (in bytes): default is 0 (no limits).

survey.getQuestionByName('image').maxSize; survey.render();