18 lines
626 B
JavaScript
Raw Normal View History

2024-10-23 10:07:45 +09:00
function onclickWrite(type, keyword, html) {
let title_field = document.getElementById('title_field')
var hasValues = true
if (hasValues) {
let data = {
'title': title_field.value,
'content': encodeURIComponent(html),
}
let uploadUrl = location.protocol + "//" + location.hostname + "/blog/post.ajax";
if(confirm(JSON.stringify(data) + "\n해당 내용으로\n유저 등록 하실??")) {
post(uploadUrl,type,JSON.stringify(data),keyword, function (resultData) {
alert(resultData)
})
} else {
}
}
}