From fb92b0bcd6838da4bec17d82848fce5201986923 Mon Sep 17 00:00:00 2001 From: PMKuipers Date: Fri, 27 Dec 2024 23:22:49 +0100 Subject: [PATCH] Repaired invitation link not working when moodle is installed in a subfolder on the webserver --- invitations.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/invitations.php b/invitations.php index 01edcba..1096bfd 100644 --- a/invitations.php +++ b/invitations.php @@ -26,7 +26,7 @@ require_once("../../config.php"); require_once($CFG->libdir.'/weblib.php'); require_once($CFG->dirroot.'/grade/querylib.php'); -$invitedurl = "/local/treestudyplan/invited.php"; +$invitedurl = "{$CFG->wwwroot}/local/treestudyplan/invited.php"; $systemcontext = context_system::instance(); @@ -97,16 +97,16 @@ if (!get_config("local_treestudyplan", "enableplansharing")) { print "name)."'"; print " data-confirmbtn='".get_string('send', 'local_treestudyplan')."'"; - print " href='#' data-actionhref='edit-invite.php?resend={$invite->id}' title='" + print " href='#' data-actionhref='{$CFG->wwwroot}/local/treestudyplan/edit-invite.php?resend={$invite->id}' title='" .get_string('invite_tooltip_resend', 'local_treestudyplan')."'"; print " >"; - print "wwwroot}/local/treestudyplan/edit-invite.php?update={$invite->id}'>"; print "name)."'"; print " data-confirmbtn='".get_string('delete')."'"; - print " href='#' data-actionhref='edit-invite.php?delete={$invite->id}' title='" + print " href='#' data-actionhref='{$CFG->wwwroot}/local/treestudyplan/edit-invite.php?delete={$invite->id}' title='" .get_string('invite_tooltip_delete', 'local_treestudyplan')."'"; print " >"; @@ -117,7 +117,7 @@ if (!get_config("local_treestudyplan", "enableplansharing")) { } print ""; - print ""; + print ""; print " ".get_string('invite_button_new', 'local_treestudyplan').""; print $OUTPUT->footer();