我正在尝试使用 aviary 发送图像名称,并且需要包含图像名称。我的表单“img”中有一个隐藏字段这是代码:
<script type='text/javascript'>
var featherEditor = new Aviary.Feather({
apiKey: 'yogbsxxxxxxxx4',
apiVersion: 3,
theme: 'dark', // Check out our new 'light' and 'dark' themes!
tools: 'enhance,crop,orientation,brightness,sharpness,redeye,resize,text',
appendTo: '',
onSave: function(imageID, newURL) {
var img = document.getElementById(imageID);
img.src = newURL;
},
onError: function(errorObj) {
alert(errorObj.message);
},
postUrl: 'http://xxxxx/~gsidev/gallery/post.php',
postData : document.getElementById(img),// this is the field I need and does not work?
});
function launchEditor(id, src) {
featherEditor.launch({
image: id,
url: src
});
return false;
}
</script>
感谢您的任何指导。对 php 实现的支持在 Aviary 上很糟糕......