summaryrefslogtreecommitdiff
path: root/web/html/home.php
blob: 6a2de59056859ad090f2f21dad6fb6de85771ffc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
<?php

set_include_path(get_include_path() . PATH_SEPARATOR . '../lib');

include_once("aur.inc.php");
set_lang();
check_sid();

include_once('stats.inc.php');

html_header( __("Home") );

?>

<div id="content-left-wrapper">
	<div id="content-left">
		<div id="intro" class="box">
			<h2><?= config_get('options', 'branding_shortname'); ?> <?= __("Home"); ?></h2>
			<p>
			<?php
			echo __(
				'Welcome to the %s! Please read the %s%s User Guidelines%s and %s%s TU Guidelines%s for more information.',
				config_get('options', 'branding_shortname'),
				'<a href="https://wiki.archlinux.org/index.php/AUR_User_Guidelines">',
				config_get('options', 'branding_shortname'),
				'</a>',
				'<a href="https://wiki.archlinux.org/index.php/AUR_Trusted_User_Guidelines">',
				config_get('options', 'branding_shortname'),
				'</a>'
				);
			?>
			<?php
			echo __(
				'Contributed PKGBUILDs %smust%s conform to the %sArch Packaging Standards%s otherwise they will be deleted!',
				'<strong>', '</strong>',
				'<a href="https://wiki.archlinux.org/index.php/Arch_Packaging_Standards">',
				'</a>'
				);
			?>
			<?= __('Remember to vote for your favourite packages!'); ?>
			<?= __('Some packages may be provided as binaries in [community].'); ?>
			</p>
			<p class="important">
			<?= __('DISCLAIMER') ?>:
			<?= __('Unsupported packages are user produced content. Any use of the provided files is at your own risk.'); ?>
			</p>
			<p class="readmore"><a href="https://wiki.archlinux.org/index.php/AUR"><?= __('Learn more...') ?></a></p>
		</div>
		<div id="news">
			<h3><a><?= __('Support') ?></a><span class="arrow"></span></h3>
			<h4><?= __('Package Requests') ?></h4>
			<div class="article-content">
			<p>
			<?php
			echo __(
				'There are three types of requests that can be filed in the %sPackage Actions%s box on the package details page:',
				'<var>',
				'</var>'
				);
			?>
			</p>
			<ul>
				<li><em><?= __('Orphan Request') ?></em>: <?= __('Request a package to be disowned, e.g. when the maintainer is inactive and the package has been flagged out-of-date for a long time.') ?></li>
				<li><em><?= __('Deletion Request') ?></em>: <?= __('Request a package to be removed from the %s. Please do not use this if a package is broken and can be fixed easily. Instead, contact the package maintainer and file orphan request if necessary.', config_get('options', 'branding_longname')) ?></li>
				<li><em><?= __('Merge Request') ?></em>: <?= __('Request a package to be merged into another one. Can be used when a package needs to be renamed or replaced by a split package.') ?></li>
			</ul>
			<p>
			<?php
			echo __(
				'If you want to discuss a request, you can use the %saur-requests%s mailing list. However, please do not use that list to file requests.',
				'<a href="https://mailman.archlinux.org/mailman/listinfo/aur-requests">',
				'</a>'
				);
			?>
			</p>
			</div>
			<h4><?= __('Submitting Packages') ?></h4>
			<div class="article-content">
			<p>
			<?php
			echo __(
				'Git over SSH is now used to submit packages to the %s. See the %sSubmitting packages%s section of the Arch User Repository ArchWiki page for more details.',
				config_get('options', 'branding_shortname'),
				'<a href="https://wiki.archlinux.org/index.php/Arch_User_Repository#AUR_4">',
				'</a>'
				);
			?>
			</p>
			<?php if (config_section_exists('fingerprints')): ?>
			<p>
				<?= __('The following SSH fingerprints are used for the %s:', config_get('options', 'branding_shortname')) ?>
			</p>
			<ul>
				<?php foreach (config_items('fingerprints') as $type => $fingerprint): ?>
				<li><code><?= htmlspecialchars($type) ?></code>: <code><?= htmlspecialchars($fingerprint) ?></code></li>
				<?php endforeach; ?>
			</ul>
			<?php endif; ?>
			</div>
			<h4><?= __('Discussion') ?></h4>
			<div class="article-content">
			<p>
			<?php
			echo __(
				'General discussion regarding the %s (%s) and Trusted User structure takes place on %s. For discussion relating to the development of the %s web interface (aurweb), use the %s mailing list.',
				config_get('options', 'branding_longname'),
				config_get('options', 'branding_shortname'),
				'<a href="https://mailman.archlinux.org/mailman/listinfo/aur-general">aur-general</a>',
				config_get('options', 'branding_shortname'),
				'<a href="https://mailman.archlinux.org/mailman/listinfo/aur-dev">aur-dev</a>'
				);
			?>
			</p>
			</div>
			<h4><?= __('Bug Reporting') ?></h4>
			<div class="article-content">
			<p>
			<?php
			echo __(
				'If you find a bug in the %s web interface (aurweb), please fill out a bug report on our %sbug tracker%s. Use the tracker to report bugs in aurweb %sonly%s. To report packaging bugs contact the package maintainer or leave a comment on the appropriate package page.',
				config_get('options', 'branding_shortname'),
				'<a href="https://bugs.archlinux.org/index.php?project=2">',
				'</a>',
				'<strong>',
				'</strong>'
				);
			?>
			</p>
			</div>
		</div>
	</div>
</div>
<div id="content-right">
	<div id="pkgsearch" class="widget">
		<form id="pkgsearch-form" method="get" action="<?= get_uri('/packages/'); ?>">
			<fieldset>
				<label for="pkgsearch-field"><?= __('Package Search') ?>:</label>
				<input type="hidden" name="O" value="0" />
				<input id="pkgsearch-field" type="text" name="K" size="30" value="<?php if (isset($_REQUEST["K"])) { print stripslashes(trim(htmlspecialchars($_REQUEST["K"], ENT_QUOTES))); } ?>" maxlength="35" />
			</fieldset>
		</form>
	</div>
	<div id="pkg-updates" class="widget box">
		<?php updates_table(); ?>
	</div>
	<div id="pkg-stats" class="widget box">
		<?php general_stats_table(); ?>
	</div>
	<?php if (!empty($_COOKIE["AURSID"])): ?>
	<div id="pkg-stats" class="widget box">
		<?php user_table(uid_from_sid($_COOKIE["AURSID"])); ?>
	</div>
	<?php endif; ?>

</div>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
<script type="text/javascript" src="/js/bootstrap-typeahead.min.js"></script>
<script type="text/javascript">
$(document).ready(function() {
    $('#pkgsearch-field').typeahead({
        source: function(query, callback) {
            $.getJSON('<?= get_uri('/rpc'); ?>', {type: "suggest", arg: query}, function(data) {
                callback(data);
            });
        },
        matcher: function(item) { return true; },
        sorter: function(items) { return items; },
        menu: '<ul class="pkgsearch-typeahead"></ul>',
        items: 20,
        updater: function(item) {
            document.location = '/packages/' + item;
            return item;
	}
    }).attr('autocomplete', 'off');

    $('#pkgsearch-field').keydown(function(e) {
        if (e.keyCode == 13) {
            var selectedItem = $('ul.pkgsearch-typeahead li.active');
            if (selectedItem.length == 0) {
                $('#pkgsearch-form').submit();
            }
        }
    });
});
</script>
<?php
html_footer(AURWEB_VERSION);