add editability
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
let nickname = $("#addnickname").val();
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "set",
|
||||
action: "addlink",
|
||||
password: password,
|
||||
id: id,
|
||||
contentid: contentid,
|
||||
@@ -33,15 +33,12 @@
|
||||
function justaddc(){
|
||||
let id = $("#addidc").val();
|
||||
let content = $("#addcontentc").val();
|
||||
let type = "normal";
|
||||
type = $("#addtypec").val();
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "setcontent",
|
||||
action: "addcontent",
|
||||
password: password,
|
||||
id: id,
|
||||
content: content,
|
||||
type: type,
|
||||
}, function( data ) {
|
||||
getcontents();
|
||||
});
|
||||
@@ -57,6 +54,36 @@
|
||||
});
|
||||
}
|
||||
|
||||
function upcthis(name){
|
||||
let id = $("#addidc_" + name).val();
|
||||
let contentin = $("#addcontentc_" + name).val();
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "setcontent",
|
||||
idwhere: name,
|
||||
id: id,
|
||||
content: contentin,
|
||||
}, function( data ) {
|
||||
getcontents();
|
||||
});
|
||||
}
|
||||
|
||||
function uplinkthis(name){
|
||||
let id = $("#addid_" + name).val();
|
||||
let contentid = $("#addcontentid_" + name).val();
|
||||
let nickname = $("#addnickname_" + name).val();
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "setlink",
|
||||
idwhere: name,
|
||||
id: id,
|
||||
contentid: contentid,
|
||||
nickname: nickname,
|
||||
}, function( data ) {
|
||||
getcontents();
|
||||
});
|
||||
}
|
||||
|
||||
function getcontents(){
|
||||
$.post("api.php",
|
||||
{
|
||||
@@ -82,7 +109,7 @@
|
||||
function delthis(name){
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "delete",
|
||||
action: "deletelink",
|
||||
id: name
|
||||
}, function( data ) {
|
||||
getlinks();
|
||||
@@ -125,7 +152,7 @@
|
||||
function getlinks(){
|
||||
$.post("api.php",
|
||||
{
|
||||
action: "get"
|
||||
action: "getlinks"
|
||||
}, function( data ) {
|
||||
$("#linkslist").html(data);
|
||||
$("#addnickname").keyup(function(event) {
|
||||
|
Reference in New Issue
Block a user