使用相机拍摄图像或从库中选择(navigator.camera.getPicture)后,我想在带有上传按钮的新页面上显示图像。我尝试了document.location,但是下一页的console.log不会打印图像。
如何在新页面中保留图像,基本上就像在会话中一样?
`
function onPhotoURISuccess(imageURI) {
// Uncomment to view the image file URI
//console.log(imageURI);
// Get image handle
//
var largeImage = document.getElementById('largeImage');
// Unhide image elements
//
largeImage.style.display = 'block';
// Show the captured photo
// The inline CSS rules are used to resize the image
//
largeImage.src = imageURI;
//alert(imageURI);
document.location='after_getpicture.html';
}`