How would one write something in the newpost_attachmentbits?
I made the change in function construct_attachment_add_js of functions_editor.php, I added the values in $attachment_js .= construct_attachment_add_js of editor.php and they are being read cause I either get the value displayed where it supposed to but with a javascript error.
my problem seems to be in vbulletin_attachment.js. Is there something wrong with the below? When I cause the error, the caption displays but the manage attachment button disappears. When I do it like below, I have no errors, but caption does not display in there. I have the caption displaying fine everywhere else.
PHP Code:
div.innerHTML =
'<div style="margin:2px"><img src="' + this.attachments[id]['imgpath'] + '" alt="" class="inlineimg" /> ' +
'<a href="attachment.php?' + SESSIONURL + 'attachmentid=' + id + '&stc=1&d=' + Math.ceil((new Date().getTime()) / 1000) + '" target="_blank" />' + this.attachments[id]['filename'] + '</a> ' +
'(' + this.attachments[id]['filesize'] + ')' + this.attachments[id]['caption'] + ' </div>';