<?xml version="1.0" encoding="UTF-8" standalone="yes"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-us"><id>https://blog.pgxn.org/tags/administrator/</id><title>Administrator</title><updated>2010-09-28T18:47:37Z</updated><link rel="self" type="application/atom+xml" href="https://blog.pgxn.org/tags/administrator/feed.xml"/><link rel="alternate" type="text/html" href="https://blog.pgxn.org/tags/administrator/"/><author><name>The PGXN Maintainers</name></author><generator uri="https://gohugo.io/" version="0.167.0">Hugo</generator><entry><id>https://blog.pgxn.org/post/1205386689</id><title type="html">Account Requests and Moderation</title><link rel="alternate" type="text/html" href="https://blog.pgxn.org/2010/account-moderation/"/><updated>2026-10-07T16:13:48Z</updated><published>2010-09-28T18:47:37Z</published><author><name>David E. Wheeler</name></author><category scheme="https://blog.pgxn.org/tags" term="account" label="Account"/><category scheme="https://blog.pgxn.org/tags" term="request" label="Request"/><category scheme="https://blog.pgxn.org/tags" term="moderation" label="Moderation"/><category scheme="https://blog.pgxn.org/tags" term="accept" label="Accept"/><category scheme="https://blog.pgxn.org/tags" term="reject" label="Reject"/><category scheme="https://blog.pgxn.org/tags" term="user" label="User"/><category scheme="https://blog.pgxn.org/tags" term="administrator" label="Administrator"/><category scheme="https://blog.pgxn.org/tags" term="jquery" label="jQuery"/><category scheme="https://blog.pgxn.org/tags" term="validation" label="Validation"/><category scheme="https://blog.pgxn.org/tags" term="ue" label="UE"/><category scheme="https://blog.pgxn.org/tags" term="ui" label="UI"/><category scheme="https://blog.pgxn.org/tags" term="degrade" label="Degrade"/><summary type="html"><![CDATA[<p>Last week I created the <a href="https://github.com/theory/pgxn-manager" title="PGXN Manager repository on GitHub">PGXN Manager</a> interface for requesting a PGXN user
account. It looks like this:</p>
<p><img src="/2010/account-moderation/request-account.png" alt="Request PGXN Account"></p>
<p>I really like the placeholder support in HTML 5, here nicely rendered by
Safari. I&rsquo;ve also used the jQuery <a href="https://docs.jquery.com/Plugins/Validation">Validation plugin</a> to validate the form
fields. So if you try to submit an incomplete form, it will complain before
submitting, like so:</p>
<p><img src="/2010/account-moderation/incomplete-form.png" alt="Incomplete PGXN Request Form"></p>
<p>The back end does similar validation if you have JavaScript disabled, so it
should degrade nicely. I think I might add a Twitter field so <a href="https://twitter.com/pgxn">@pgxn</a> can
credit users for their uploads, but otherwise this is done.</p>]]></summary><content type="html" xml:base="https://blog.pgxn.org/" xml:space="preserve"><![CDATA[<p>Last week I created the <a href="https://github.com/theory/pgxn-manager" title="PGXN Manager repository on GitHub">PGXN Manager</a> interface for requesting a PGXN user
account. It looks like this:</p>
<p><img src="/2010/account-moderation/request-account.png" alt="Request PGXN Account"></p>
<p>I really like the placeholder support in HTML 5, here nicely rendered by
Safari. I&rsquo;ve also used the jQuery <a href="https://docs.jquery.com/Plugins/Validation">Validation plugin</a> to validate the form
fields. So if you try to submit an incomplete form, it will complain before
submitting, like so:</p>
<p><img src="/2010/account-moderation/incomplete-form.png" alt="Incomplete PGXN Request Form"></p>
<p>The back end does similar validation if you have JavaScript disabled, so it
should degrade nicely. I think I might add a Twitter field so <a href="https://twitter.com/pgxn">@pgxn</a> can
credit users for their uploads, but otherwise this is done.</p>
<p>As with <a href="https://pause.perl.org/" title="The [Perl programming] Authors Upload Server">PAUSE</a>, an administrator must accept it or reject an account request.
Once your account is approved (likely unless you&rsquo;re a spammer), you&rsquo;ll be able
to upload distributions (I&rsquo;m going to do that part today). I finished the user
admin interface yesterday. Here&rsquo;s a screen snap:</p>
<p><img src="/2010/account-moderation/moderate-requests.png" alt="PGXN User Administration"></p>
<p>Some details. PGXN Manager will be hosted at <a href="https://manager.pgxn.org/"><code>https://manager.pgxn.org/</code></a>. It
uses basic auth for authentication; logged-in users will access
<a href="https://manager.pgxn.org/auth"><code>https://manager.pgxn.org/auth</code></a>. Administrators will have an extra menu item
to this screen, which will allow them to accept or reject account requests.
Its URI is <code>/auth/admin/moderate</code>. The admin can click the &ldquo;Play&rdquo; button to
see the requestor&rsquo;s note explaining why he should get an account. It&rsquo;s a
popover enabled by some jQuery code and looks like this:</p>
<p><img src="/2010/account-moderation/why-popover.png" alt="PGXN User Admin Why Popover"></p>
<p>Once an admin has read the request, she can accept it by clicking the blue
checkmark icon, or reject it by clicking the red minus icon. The former links
to <code>/auth/admin/accept/{nickname}</code> and the latter to
<code>/auth/admin/reject/{nickname}</code>. The submits are done by jQuery async requests
by default, but if you have JavaScript disabled they will submit as usual and
the back end will process the request and simply redirect to the moderation
screen.</p>
<p>This works very well, I think. It&rsquo;s an attractive interface and degrades
reasonably well. (Well, you can&rsquo;t read the request details if you have
JavaScript disabled, but the requests work nicely). The jQuery code fades out
a row after it has been accepted or rejected, so it&rsquo;s easy for an admin to do
a bunch of moderation all at once. And finally, the interface is driven by the
URLs, so I think it&rsquo;s pretty restful. The only ones I&rsquo;m not sure about are the
accept/reject URLs, because they have action names in them (&ldquo;accept&rdquo; and
&ldquo;reject&rdquo;). Is that RESTful? Or should they use GET query strings or something?</p>
<p>Okay, on to the upload interface. Wish me luck!</p>
]]></content></entry></feed>