Commit graph

59 commits

Author SHA1 Message Date
Lukas Fleischer
c08c384e9a Show official language names in the drop-down list
We already store the native language names. Display them in the
drop-down list instead of using language codes.

Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-08 14:26:26 +02:00
Lukas Fleischer
cc1e8aed30 Rename the AUR software to aurweb
Rename the project to help differentiate between the software providing
access to the Arch User Repository and the collection of source packages
itself.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2015-02-04 09:50:01 +01:00
Lukas Fleischer
8e06a607c8 Use a custom logo
Currently, the AUR sites are hard to distinguish from the official
website, especially when browsing Git repositories in cgit. Add "user
repository" to the logo to make it distinguishable from the official
site.

In order to avoid confusion, also change the link in the logo to the AUR
home page instead of the main Arch Linux website.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-12-29 11:30:04 +01:00
Lukas Fleischer
74edb6fea9 Use Git repositories to store packages
* Remove package submission page from the web interface.
* Replace PKGBUILD and tarball links with links to cgit.
* Remove the "URLPath" field from RPC replies.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-12-27 12:42:12 +01:00
Lukas Fleischer
5ebf534ba7 Avoid double slashes in notification email body
Refactor some of the URI generation code to avoid double slashes in
absolute URIs.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-12-13 15:28:54 +01:00
Lukas Fleischer
27850943bb Fix login link
Regression introduced in 76343fb (Use an INI-style configuration file,
2014-10-24).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-11-19 10:20:31 +01:00
Lukas Fleischer
76343fb915 Use an INI-style configuration file
Replace web/lib/config.inc.php with an INI-style configuration file.
This allows us to get rid of several globals and makes it easier to use
the same configuration file in external scripts.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-10-24 10:03:54 +02:00
Lukas Fleischer
03c6304e19 Rework permission handling
Add a new function has_credential() that checks whether the currently
logged in user is allowed to perform a given action. Moving all
permission handling to this central place makes adding new user groups
and adjusting permissions much more convenient.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-07-15 22:56:57 +02:00
Lukas Fleischer
8260111bcc Add a package request list
Introduce a new navigation point "Requests" that shows a list of pending
package requests. This functionality is only available to Trusted Users.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-06-25 11:33:29 +02:00
Lukas Fleischer
bc93e68dc7 Set language using a POST request
Fixes FS#39027.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-05-13 14:19:55 +02:00
Marcel Korpel
8e1051932e Add description meta-element to package pages
Implements FS#33294

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2013-01-19 12:18:13 +01:00
Lukas Fleischer
4e4db4133b header.php: Do not lowercase language selection entries
Commit 091c2b5f55 introduced lower casing
to the language drop-down list. Revert this and use htmlspecialchars()
to escape language entries instead.

Addresses FS#32453.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-11-04 16:49:47 +01:00
Dan McGee
5222bf0932 Use HTTPS links everywhere for Arch sites
The main site, wiki, and BBS are using HTTPS exclusively, so link
directly to the correct protocol rather than forcing a redirect.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-10-22 12:33:11 +02:00
Lukas Fleischer
7e201e5a3a Link to the HTTPs login page in the header
Change the login link so that it points directly to the HTTPs version of
the login page if "$DISABLE_HTTP_LOGIN" is set and if HTTP is used.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-10-21 02:50:06 +02:00
canyonknight
e9a0272118 Change logo link for consistency with Archweb
Fixes FS#27669

Signed-off-by: canyonknight <canyonknight@gmail.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-10-10 17:22:23 +02:00
Lukas Fleischer
6102759b7c Use echo shortcut syntax
Replace all occurrences of "<?php echo" and "<?php print" by "<?=" to
reduce noise in templates.

Note that as of PHP 5.4.0, "<?=" is always available and no longer
requires "short_open_tag" to be set.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-09-24 12:23:04 +02:00
Lukas Fleischer
c959d95fb1 Fix language selection
Use "REQUEST_URI" instead of the "PHP_SELF" sever variable to determine
the redirection URL for the language selection form. This fixes the
language selection feature to work well with virtual URLs.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-09-18 15:19:30 +02:00
canyonknight
98ab6515b4 header.php: Update account editing link
* Use AUR_URL/account/userfoo/edit format for own account editing.
* Change "Accounts" label to "My Account" for regular users.
* Add ability for Developers and Trusted Users to edit their account
without having to use the search form first.

Signed-off-by: canyonknight <canyonknight@gmail.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-09-18 00:59:48 +02:00
Lukas Fleischer
2425f963f8 Use virtual path feature for links
Use virtual paths in links (e.g. link to "/packages/" instead of
"/packages.php" etc.) if the virtual path feature is enabled.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-07-15 22:44:51 +02:00
Lukas Fleischer
a03c684ecd Use absolute URIs for style sheets and images
This is needed for our new URI scheme, since we will use virtual
directories, such as "/packages/" instead of "/packages.php" etc.

Having relative URIs results in incorrect paths, such as
"/packages/css/aur.css" (instead of "/css/aur.css").

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-07-15 22:42:45 +02:00
Lukas Fleischer
a64f23ff94 Remove legacy CSS
We completely switched to using the archweb stylesheet (with some custom
extensions in "aur.css"). The old CSS files are no longer needed.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-07-08 10:32:40 +02:00
Lukas Fleischer
091c2b5f55 Move language selection to a drop-down list
Move all languages to a select container to save some space. Language
selection is a rarely used feature, so there's no need to make this a
one click option.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-07-06 11:26:47 +02:00
Lukas Fleischer
98c497d039 Restructure the navigation bar
* Remove "Bugs" and "Discussion" links. Move these to the home page.
* Reorder links in a reasonable and consistent manner.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: canyonknight <canyonknight@gmail.com>
2012-07-06 11:26:42 +02:00
Lukas Fleischer
0928525793 Move login form to a separate page
Do not show the login form on every page. Move it to a separate login
page and add a link to the navigation bar. Also, add a logout link for
logged-in users.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: canyonknight <canyonknight@gmail.com>
2012-07-06 11:26:38 +02:00
Lukas Fleischer
9cee53f3cf Wrap everything in a content cotainer
For consistency with archweb.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: canyonknight <canyonknight@gmail.com>
2012-07-06 11:25:55 +02:00
Lukas Fleischer
df19822e00 Add archweb style sheet
* Add "archweb.css" from the master branch of archweb. We will use this
  as base style sheet in the future.

* Add "aur.css" for AUR-specific extensions to "archweb.css".

* Remove the "archnavbar.css" link from the header template since this
  is included in "archweb.css".

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-07-06 11:25:53 +02:00
Lukas Fleischer
a774b3d355 Merge branch 'maint' 2012-02-19 16:41:47 +01:00
Lukas Fleischer
19789c3f75 Escape all output strings in the header and footer
Escape each output string using htmlspecialchars(). These aren't
exploitable; it's still better to escape them properly.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-02-19 05:21:48 +01:00
Lukas Fleischer
6f6904db3f Fix some more XSS vulnerabilities
Escape strings properly using htmlspecialchars(). Seems like we missed
these in former cleanups. Fixes FS#28515.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2012-02-19 04:48:31 +01:00
Dan McGee
e571a694d6 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>
2011-11-02 21:21:23 +01:00
Florian Pritz
b60a30af71 fix incompatibility with php short open tags
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-06-25 11:29:56 +02:00
Lukas Fleischer
897211374f Use HTTPs for links in the main site navigation bar (fixes FS#23832).
Basically just sync with what archweb currently uses, prefixing all
relative URLs with "http://www.archlinux.org".

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-04-20 00:13:10 +02:00
Lukas Fleischer
0a625ae8ff Fix XSS vulnerability in "web/template/header.php".
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-03-30 17:07:27 +02:00
Lukas Fleischer
7f9e498e48 Fix broken XHTML.
Fix a lot of invalid XHTML in the templates and actions. There might
still be some legacy code left, but this should cover most of it.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-03-11 19:00:50 +01:00
Loui Chang
137e7a1ad3 header.php: Add missing closing </li> tag.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-08-01 10:03:06 -04:00
Denis Kobozev
b22f66b3ee Header and navbar consistent with Arch site redesign
-- Loui Chang
Change is_tu to check_user_privileges
Change div#archdev-navbar style

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-07-23 05:40:15 -04:00
Loui Chang
f5c1851bbb header.php: Remove lingering </li> tag.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-12-07 18:44:22 -05:00
Loui Chang
1bc4836e19 Restyle the layout.
Make HTML markup more logical.
Remove some unused style sheets rules.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-11-23 23:24:56 -05:00
Loui Chang
cf49644f4e Change rss2.php references to rss.php
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-28 16:23:35 -04:00
Dan McGee
5c13854922 Remove Google ads from header
Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-08-11 13:58:11 -04:00
Loui Chang
6bac561bf8 Rework login form.
Correct some xhtml validation errors.
Correct translation usage.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-01-24 00:40:30 -05:00
Loui Chang
f82f3dd247 Fix a few xhtml validation errors.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-01-23 15:49:41 -05:00
Dan McGee
8f97330100 Store account type in local var when possible
No need to call this function way too often, especially when on the package
list page where it could be called up to once per row.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-01-04 14:09:53 -05:00
Loui Chang
cfeb080dcd Make all web paths relative.
The site no longer needs to be hosted from the
root of a domain, or virtual host.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
2008-12-21 15:24:57 +09:00
Thayer Williams
9aa03d3262 Renamed Get Arch to Download.
AL logo now goes to AL homepage, not AUR homepage
Appended forward slash to top navigation links

Signed-off-by: Thayer Williams <thayer@archlinux.org>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2008-11-25 00:27:05 -05:00
Callan Barrett
4b616e20ba Move logout link from main menu to login bar
Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2008-10-05 20:42:52 -04:00
Simo Leone
99e65b28d8 Revamped pkg_search_page()
- Reduced database hits
- Improved speed
- Improved sanity (slightly)
- Fixed searches,buttons,gizmos

Signed-off-by: Simo Leone <simo@archlinux.org>
2008-03-23 03:07:22 -05:00
Loui Chang
a5a8895f49 Put login into its own function.
Utilise login form template.
Also cleaned up a couple notices.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
Signed-off-by: Simo Leone <simo@archlinux.org>
2008-03-23 03:04:16 -05:00
Callan Barrett
d14def92ff Turn action bar into drop box
Moves the action bar down to the bottom right of the search results and turns it
into a drop-down selection box.

Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
Signed-off-by: Simo Leone <simo@archlinux.org>
2008-01-20 03:18:16 -06:00
Callan Barrett
52a770e7e7 Fix login error and translation bug
Fixes a login error where entering nothing would result in the login message
"Incorrect password for username, ." and changes the translation "TU" to
"Trusted User" so the menu bar on the accounts page doesn't bug up (we need a
new translation system :((()

Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
Signed-off-by: Simo Leone <simo@archlinux.org>
2008-01-20 03:16:07 -06:00