summaryrefslogtreecommitdiffstats
path: root/web/template/pkg_comment_form.php
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-10-21 22:15:55 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2011-11-02 21:21:23 +0100
commite571a694d6e15891b591c28dd40cd464740a7126 (patch)
tree22f52edb32653ba24ddf9ca5d1230b53a1968d4f /web/template/pkg_comment_form.php
parentfe90b4bc3e6b2a2a352236359577b3d46728aed6 (diff)
downloadaur-e571a694d6e15891b591c28dd40cd464740a7126.tar.gz
aur-e571a694d6e15891b591c28dd40cd464740a7126.tar.xz
Add a new AUR_LOCATION setting
This should be set to something like 'http://localhost' for development or 'https://aur.archlinux.org' in production. It ensures all links in the site stay in the development site and there is no sudden jump from development to production environments. Signed-off-by: Dan McGee <dan@archlinux.org> Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/template/pkg_comment_form.php')
-rw-r--r--web/template/pkg_comment_form.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/web/template/pkg_comment_form.php b/web/template/pkg_comment_form.php
index d3b602cd..a2bbf714 100644
--- a/web/template/pkg_comment_form.php
+++ b/web/template/pkg_comment_form.php
@@ -35,9 +35,9 @@ if (isset($_REQUEST['comment'])) {
# Simply making these strings translatable won't work, users would be
# getting emails in the language that the user who posted the comment was in
$body =
- 'from https://aur.archlinux.org/packages.php?ID='
+ 'from ' . $AUR_LOCATION . '/packages.php?ID='
. $_REQUEST['ID'] . "\n"
- . username_from_sid($_COOKIE['AURSID']) . " wrote:\n\n"
+ . username_from_sid($_COOKIE['AURSID'], $dbh) . " wrote:\n\n"
. $_POST['comment']
. "\n\n---\nIf you no longer wish to receive notifications about this package, please go the the above package page and click the UnNotify button.";
$body = wordwrap($body, 70);