quest and waypoint checkbox correct filepath now

This commit is contained in:
Hash Borgir 2023-06-05 22:02:36 -06:00
parent beaeb2fd49
commit e1675ceec3

View File

@ -338,8 +338,10 @@ $(document).ready(function () {
// Get the name of the difficulty
var diff = $(this).attr("diff");
// Get the value of the input named "filePath"
var filePath = $("input[name='filePath']").val();
var parentFormId = $(this).closest("form").attr("id");
var parentFormClass = $(this).closest("form").attr("class");
var filePath = $(`#${parentFormId} input[name='filePath']`).val();
// Construct the URL for the GET request
var url = "/saveCharacter.php?cmd=wp&name=" + name + "&value=" + value + "&filePath=" + filePath + "&diff=" + diff;
@ -362,8 +364,12 @@ $(document).ready(function () {
// Get the name of the difficulty
var diff = $(this).attr("diff");
// Get the value of the input named "filePath"
var filePath = $("input[name='filePath']").val();
var parentFormId = $(this).closest("form").attr("id");
var parentFormClass = $(this).closest("form").attr("class");
var filePath = $(`#${parentFormId} input[name='filePath']`).val();
// Construct the URL for the GET request
var url = "/saveCharacter.php?cmd=q&name=" + name + "&value=" + value + "&filePath=" + filePath + "&diff=" + diff;
@ -401,6 +407,7 @@ $(document).ready(function () {
var cmd = $(this).attr("cmd") || $(this).attr("id") || name;
var parentFormId = $(this).closest("form").attr("id");
var parentFormClass = $(this).closest("form").attr("class");
var filePath = $(`#${parentFormId} input[name='filePath']`).val();
var url = constructURL(cmd, name, newValue, filePath);