Skip to content

Commit 1636005

Browse files
committed
no leading slashes
1 parent c91ac93 commit 1636005

File tree

7 files changed

+11
-11
lines changed

7 files changed

+11
-11
lines changed

webroot/admin/pi-mgmt.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ class="filterSearch"
143143
}
144144
});
145145

146-
var ajax_url = "<?php echo getURL("/admin/ajax/get_group_members.php"); ?>?gid=";
146+
var ajax_url = "<?php echo getURL("admin/ajax/get_group_members.php"); ?>?gid=";
147147
</script>
148148

149149
<?php

webroot/admin/user-mgmt.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
switch ($_POST["form_type"]) {
1313
case "viewAsUser":
1414
$_SESSION["viewUser"] = $_POST["uid"];
15-
UnityHTTPD::redirect(getURL("/panel/account.php"));
15+
UnityHTTPD::redirect(getURL("panel/account.php"));
1616
break;
1717
}
1818
}

webroot/panel/groups.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@
120120
echo "<h5>Current Groups</h5>";
121121

122122
if ($USER->isPI() && count($PIGroupGIDs) == 1) {
123-
$url = getURL("/panel/pi.php");
123+
$url = getURL("panel/pi.php");
124124
echo "
125125
You are only a member of your own PI group.
126126
Navigate to the
@@ -181,11 +181,11 @@
181181

182182
<script>
183183
$("button.btnAddPI").click(function () {
184-
openModal("Add New PI", "<?php echo getURL("/panel/modal/new_pi.php"); ?>");
184+
openModal("Add New PI", "<?php echo getURL("panel/modal/new_pi.php"); ?>");
185185
});
186186

187187
// tables.js uses ajax_url to populate expandable tables
188-
var ajax_url = "<?php echo getURL("/panel/ajax/get_group_members.php"); ?>?gid=";
188+
var ajax_url = "<?php echo getURL("panel/ajax/get_group_members.php"); ?>?gid=";
189189
</script>
190190

191191
<style>

webroot/panel/modal/new_key.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
?>
55

66
<form id="newKeyform" enctype="multipart/form-data" method="POST"
7-
action="<?php echo getURL("/panel/account.php"); ?>">
7+
action="<?php echo getURL("panel/account.php"); ?>">
88
<input type='hidden' name='form_type' value='addKey'>
99

1010
<div class='inline'>
@@ -68,7 +68,7 @@ function generateKey(type) {
6868
var endingSection = "</section>";
6969

7070
$.ajax({
71-
url: "<?php echo getURL("/js/ajax/ssh_generate.php"); ?>?type=" + type,
71+
url: "<?php echo getURL("js/ajax/ssh_generate.php"); ?>?type=" + type,
7272
success: function(result) {
7373
var pubKey = result.substr(result.indexOf(pubSection) + pubSection.length,
7474
result.indexOf(endingSection) - result.indexOf(pubSection) - pubSection.length);
@@ -97,7 +97,7 @@ function generateKey(type) {
9797
$("textarea[name=key]").on("input", function() {
9898
var key = $(this).val();
9999
$.ajax({
100-
url: "<?php echo getURL("/js/ajax/ssh_validate.php"); ?>",
100+
url: "<?php echo getURL("js/ajax/ssh_validate.php"); ?>",
101101
type: "POST",
102102
data: {
103103
key: key

webroot/panel/modal/new_pi.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<form
77
id="newPIform"
88
method="POST"
9-
action="<?php echo getURL("/panel/groups.php"); ?>"
9+
action="<?php echo getURL("panel/groups.php"); ?>"
1010
>
1111
<input type="hidden" name="form_type" value="addPIform">
1212
<div style="position: relative;">

webroot/panel/new_account.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
use UnityWebPortal\lib\UnityUser;
77

88
if ($USER->exists()) {
9-
UnityHTTPD::redirect(getURL("/panel/account.php"));
9+
UnityHTTPD::redirect(getURL("panel/account.php"));
1010
}
1111
if ($_SERVER["REQUEST_METHOD"] == "POST") {
1212
$user = new UnityUser($SSO["user"], $LDAP, $SQL, $MAILER, $WEBHOOK);

webroot/panel/pi.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
$assocs = $group->getGroupMembers();
4545

4646
if (count($requests) + count($assocs) == 1) {
47-
$url = getURL("/panel/groups.php");
47+
$url = getURL("panel/groups.php");
4848
echo "<p>You do not have any users attached to your PI account.
4949
Ask your users to request to join your account on the <a href='$url'>My PIs</a> page.</p>";
5050
}

0 commit comments

Comments
 (0)