Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added error messages to login/register; added privacy policy and term…

…s of service
  • Loading branch information...
commit a2d0da6775ef9fae77bc37f4755fc5860759604d 1 parent baea790
@ureddit authored
Showing with 326 additions and 5 deletions.
  1. +2 −1  footer.php
  2. +12 −3 login.php
  3. +157 −0 privacy.php
  4. +11 −1 register.php
  5. +144 −0 tos.php
View
3  footer.php
@@ -1,6 +1,7 @@
<footer>
University of Reddit is not in any way affiliated with <a href="http://reddit.com" target="_blank">Reddit.com</a> or <a href="http://condenast.com" target="_blank">Conde Nast</a>.<br>
- Hosting is provided by <a href="http://anastasllc.com" target="_blank">Anastas, LLC</a>.
+<a href="<?=PREFIX ?>/tos">Terms of Service</a> | <a href="<?=PREFIX ?>/privacy">Privacy Policy</a><br>
+ Hosting is donated by <a href="http://anastasllc.com" target="_blank">Anastas, LLC</a><br>
</footer>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
View
15 login.php
@@ -3,6 +3,7 @@
require_once('init.php');
$loginmsg = "";
+$error = array();
if(!empty($_POST))
{
$user = new user($dbpdo);
@@ -11,10 +12,10 @@
try
{
$user->get_attribute_value('banned');
- die("<h1>you have been banned</h1>");
}
catch (ObjectAttributeNotFoundException $e)
{
+ $error[] = 'that account has been banned';
}
login($user);
@@ -31,6 +32,10 @@
$user->timestamp()
));
}
+ else
+ {
+ $error[] = "the username or password you entered is incorrect";
+ }
}
if(logged_in())
@@ -80,8 +85,12 @@
<input type="password" name="password" id="password" /><br /><br />
<input type="submit" />
- </form>
-
+ </form><br />
+<?php
+ if(!empty($_POST) && count($error) > 0)
+ foreach($error as $err)
+ echo '<span style="color: red;">' . $err . '</span><br />';
+?>
<p>
<strong>Forgot your password?</strong> <a href="<?=PREFIX ?>/recover_password"><br>Reset my password</a></p>
</p>
View
157 privacy.php
@@ -0,0 +1,157 @@
+<?php
+
+require_once('init.php');
+
+?>
+
+<!doctype html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
+<head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>University of Reddit</title>
+ <meta name="description" content="">
+
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet" href="<?=PREFIX ?>/css/style.css">
+
+ <script src="<?=PREFIX ?>/js/libs/modernizr-2.5.2.min.js"></script>
+ <style type="text/css">
+ p {
+ margin: 0 0 5px 50px;
+ }
+
+ h1 {
+ margin-top: 10px;
+ margin-bottom: 10px;
+ }
+
+ h2 {
+ margin-left: 25px;
+ margin-bottom: 3px;
+ }
+
+ h3 {
+ margin-left: 30px;
+ margin-bottom: 3px;
+ }
+
+ ul {
+ margin: 10px 0 10px 100px;
+ }
+-->
+</style>
+</head>
+<body>
+ <!--[if lt IE 7]><p class=chromeframe>Your browser is <em>ancient!</em> <a href="http://browsehappy.com/">Upgrade to a different browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">install Google Chrome Frame</a> to experience this site.</p><![endif]-->
+ <?php
+ require_once('header.php');
+ require_once('social.php');
+
+ if(isset($_GET['category_id']) && count($dbpdo->query("SELECT `id` FROM `objects` WHERE `id` = ? AND `type` = 'category' LIMIT 1", array($_GET['category_id'])) != 0))
+ $active_category_id = $_GET['category_id'];
+ else
+ $active_category_id = -1;
+
+ $catalog = new catalog($dbpdo);
+ ?>
+ <div id="main" role="main">
+ <div id="help">
+ <div class="content">
+<?php
+
+$str = <<<EOD
+#Privacy Policy
+
+##What information do we collect?
+
+We collect information from you when you register on our site.
+
+When ordering or registering on our site, as appropriate, you may be asked to enter your name and, optionally, you e-mail address. You may, however, visit our site anonymously.
+
+Google, as a third party vendor, uses cookies to serve ads. Google's use of the DART cookie enables it to serve ads to users based on their visit to our site and other sites on the Internet. Users may opt out of the use of the DART cookie by visiting the Google ad and content network privacy policy.
+
+##What do we use your information for?
+
+Any of the information we collect from you may be used in one of the following ways:
+
+* To personalize your experience (your information helps us to better respond to your individual needs)
+* To improve our website (we continually strive to improve our website offerings based on the information and feedback we receive from you)
+* To improve customer service (your information helps us to more effectively respond to your customer service requests and support needs)
+* To send occassional emails
+
+The email address you provide may be used to send you information, respond to inquiries, and/or other requests or questions.
+
+##How do we protect your information?
+
+We implement a variety of security measures to maintain the safety of your personal information when you enter, submit, or access your personal information.
+
+##Do we use cookies?
+
+Yes. (Cookies are small files that a site or its service provider transfers to your computers hard drive through your Web browser (if you allow) that enables the sites or service providers systems to recognize your browser and capture and remember certain information.)
+
+We use cookies to understand and save your preferences for future visits, keep track of advertisements and compile aggregate data about site traffic and site interaction so that we can offer better site experiences and tools in the future.
+
+##Do we disclose any information to outside parties?
+
+We do not sell, trade, or otherwise transfer to outside parties your personally identifiable information. This does not include trusted third parties who assist us in operating our website, conducting our business, or servicing you, so long as those parties agree to keep this information confidential. We may also release your information when we believe release is appropriate to comply with the law, enforce our site policies, or protect ours or others rights, property, or safety. However, non-personally identifiable visitor information may be provided to other parties for marketing, advertising, or other uses.
+
+##Third party links
+
+Occasionally, at our discretion, we may include or offer third party products or services on our website. These third party sites have separate and independent privacy policies. We therefore have no responsibility or liability for the content and activities of these linked sites. Nonetheless, we seek to protect the integrity of our site and welcome any feedback about these sites.
+
+##California Online Privacy Protection Act Compliance
+
+Because we value your privacy we have taken the necessary precautions to be in compliance with the California Online Privacy Protection Act. We therefore will not distribute your personal information to outside parties without your consent.
+
+As part of the California Online Privacy Protection Act, all users of our site may make any changes to their information at anytime by logging into the University of Reddit website, navigating to the top right hand menu, and selecting "settings". In most cases you will not have a specific profile outside of an account name and password; however, if you are going to teach you can elect to provide some background about yourself and why you are fit to teach on a certain subject. This information can be edited at any time by accessing your class page.
+
+##Childrens Online Privacy Protection Act Compliance
+
+We are in compliance with the requirements of COPPA (Childrens Online Privacy Protection Act), we do not collect any information from anyone under 13 years of age. Our website, products and services are all directed to people who are at least 13 years old or older.
+
+##Your Content is Your Content
+
+By using the University of Reddit we do not make any claims to ownership of the content you create or provide. We can however feature your content on a dedicated University of Reddit channel or use various aspects of your class (attributed) to help bring attention to it. The channels that we may use include, but are not limited to a Twitter feed, YouTube account, Vimeo account, communication on reddit, and newsletters.
+
+##Not Responsible For User Generated Content
+
+The University of Reddit is not responsible for the content that its users post, share, or create for it. We will attempt to ensure that all information on the site are legal, and are not harmful to anyone's right's.
+
+##Privacy Policy Coordinator
+
+If you have any concerns or questions about any aspect of this policy, please feel free to contact our Privacy Policy Coordinator as follows: Privacy Policy Coordinator <universityofreddit@gmail.com>
+
+##Terms and Conditions
+
+Please also visit our Terms and Conditions section establishing the use, disclaimers, and limitations of liability governing the use of our website [here](http://ureddit.com/tos).
+
+##Your Consent
+
+By using our site, you consent to our privacy policy.
+
+##Changes to our Privacy Policy
+
+If we decide to change our privacy policy, we will post those changes on this page, and/or update the Privacy Policy modification date below.
+
+This policy was last modified on May 22, 2012.
+
+##Contacting Us
+
+If there are any questions regarding this privacy policy you may contact us at universityofreddit@gmail.com.
+
+All logos and names are owned by their respective copyright holders.
+
+EOD;
+
+echo process($str);
+?>
+ </div>
+ </div>
+ </div>
+ <?php require_once('footer.php'); ?>
+</body>
+</html>
View
12 register.php
@@ -6,6 +6,9 @@
if(!empty($_POST))
{
+ if(!isset($_POST['age']) || $_POST['age'] != "checked")
+ $error[] = "you must be at least 13 years of age to use this website.";
+
$validation = array("username" => '/^([A-Z0-9_.-]){3,32}$/i', "password" => '/^(.*){6,}$/i', "email" => '/^([A-Z0-9._%+-])+@([A-Z0-9.-]+)\.[A-Z]{2,4}$/i');
if(!preg_match($validation['username'],$_POST['username']))
@@ -137,8 +140,15 @@
email (optional):<br />
<input type="email" name="email" id="email" value="<?=post('email'); ?>" size="25" /><br /><br />
+ <label><input type="checkbox" name="age" id="age"> I am at least 13 years of age.</label><br /><br />
+
<input type="submit" />
- </form>
+ </form><br />
+<?php
+ if(!empty($_POST) && count($error) > 0)
+ foreach($error as $err)
+ echo '<span style="color: red;">' . $err . '</span><br />';
+?>
</div>
</div>
<div id="whyregister">
View
144 tos.php
@@ -0,0 +1,144 @@
+<?php
+
+require_once('init.php');
+
+?>
+
+<!doctype html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
+<head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>University of Reddit</title>
+ <meta name="description" content="">
+
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet" href="<?=PREFIX ?>/css/style.css">
+
+ <script src="<?=PREFIX ?>/js/libs/modernizr-2.5.2.min.js"></script>
+ <style type="text/css">
+ p {
+ margin: 0 0 5px 50px;
+ }
+
+ h1 {
+ margin-top: 10px;
+ margin-bottom: 10px;
+ }
+
+ h2 {
+ margin-left: 25px;
+ margin-bottom: 3px;
+ }
+
+ h3 {
+ margin-left: 30px;
+ margin-bottom: 3px;
+ }
+
+ ul {
+ margin: 10px 0 10px 100px;
+ }
+-->
+</style>
+</head>
+<body>
+ <!--[if lt IE 7]><p class=chromeframe>Your browser is <em>ancient!</em> <a href="http://browsehappy.com/">Upgrade to a different browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">install Google Chrome Frame</a> to experience this site.</p><![endif]-->
+ <?php
+ require_once('header.php');
+ require_once('social.php');
+
+ if(isset($_GET['category_id']) && count($dbpdo->query("SELECT `id` FROM `objects` WHERE `id` = ? AND `type` = 'category' LIMIT 1", array($_GET['category_id'])) != 0))
+ $active_category_id = $_GET['category_id'];
+ else
+ $active_category_id = -1;
+
+ $catalog = new catalog($dbpdo);
+ ?>
+ <div id="main" role="main">
+ <div id="help">
+ <div class="content">
+<?php
+
+$str = <<<EOD
+#Website Terms and Conditions of Use
+
+##1. Terms
+
+By accessing this website, you are agreeing to be bound by these website Terms and Conditions of Use, all applicable laws and regulations, and agree that you are responsible for compliance with any applicable local laws. If you do not agree with any of these terms, you are prohibited from using or accessing this site. The materials contained in this website are protected by applicable copyright and trademark law.
+
+##2. Use License
+
+Permission is granted to temporarily view a copy of the materials (information) on the University of Reddit's website for personal, non-commercial transitory viewing only. This is the grant of a license, not a transfer of title, and under this license you may not:
+
+* modify or copy the materials, unless by the explicit permission of the teacher;
+* use the materials for any commercial purpose, or for any public display (commercial or non-commercial), unless owned by you;
+* transfer the materials to another person or "mirror" the materials on any other server, unless by the explicit permission of the teacher.
+
+This license shall automatically terminate if you violate any of these restrictions and may be terminated by University of Reddit at any time..
+
+##3. Disclaimer
+
+The materials on University of Reddit's website are provided "as is". University of Reddit makes no warranties, expressed or implied, and hereby disclaims and negates all other warranties, including without limitation, implied warranties or conditions of merchantability, fitness for a particular purpose, or non-infringement of intellectual property or other violation of rights. Further, University of Reddit does not warrant or make any representations concerning the accuracy, likely results, or reliability of the use of the materials on its Internet website or otherwise relating to such materials or on any sites linked to this site.
+
+##4. Limitations
+
+In no event shall University of Reddit or its suppliers be liable for any damages (including, without limitation, damages for loss of data or profit, or due to business interruption,) arising out of the use or inability to use the materials on University of Reddit's Internet site, even if University of Reddit or a University of Reddit authorized representative has been notified orally or in writing of the possibility of such damage. Because some jurisdictions do not allow limitations on implied warranties, or limitations of liability for consequential or incidental damages, these limitations may not apply to you.
+
+##5. Revisions and Errata
+
+The materials appearing on University of Reddit's website could include technical, typographical, or photographic errors. University of Reddit does not warrant that any of the materials on its website are accurate, complete, or current; however, we will do our utmost work to ensure that they are. University of Reddit may make changes to the materials contained on its website at any time without notice. University of Reddit does not, however, make any commitment to update the materials. As we update our Terms of Service we will inform you through either a specified post in our subreddit on reddit, or an alert on our site.
+
+##6. Links
+
+University of Reddit has not reviewed all of the sites linked to its Internet website and is not responsible for the contents of any such linked site. The inclusion of any link does not imply endorsement by University of Reddit of the site. Use of any such linked website is at the user's own risk.
+
+##7. Site Terms of Use Modifications
+
+University of Reddit may revise these terms of use for its website at any time without notice. By using this website you are agreeing to be bound by the then current version of these Terms and Conditions of Use.
+
+##8. Governing Law
+
+Any claim relating to University of Reddit's website shall be governed by the laws of the State of Pennsylvania without regard to its conflict of law provisions.
+General Terms and Conditions applicable to Use of a Website.
+
+##9. Medical and Legal Information Disclaimer
+
+The University of Reddit is not a platform for the exchange of medical or legal information. While you may freely discuss these topics, you should not look to the follow any information without first consulting the proper professional (whether that be doctor or lawyer). The University of Reddit will not be held liable for any improper or potentially damaging information that is provided.
+
+##10. Copyright Complaints:
+
+If you believe that your information has been copied and is accessible on our website, or that the website contains links or other references to another online location that contains material or activity that infringes your copyright rights, you may notify the University of Reddit by providing the following information (as required by the Online Copyright Infringement Liability Limitation Act of the Digital Millennium Copyright Act, 17 U.S.C. sec. 512) to our copyright agent set forth below:
+
+(i) A physical or electronic signature of a person authorized to act on behalf of the owner of an exclusive right that is allegedly infringed.
+(ii) Identification of the copyrighted work claimed to have been infringed, or, if multiple copyrighted works at a single online site are covered by a single notification, a representative list of such works at that site.
+(iii) Identification of the material that is claimed to be infringing or to be the subject of infringing activity and that is to be removed or access to which is to be disabled, and information reasonably sufficient to permit the service provider to locate the material.
+(iv) Information reasonably sufficient to permit the service provider to contact the complaining party, such as an address, telephone number, and, if available, an electronic mail address at which the complaining party may be contacted.
+(v) A statement that the complaining party has a good faith belief that use of the material in the manner complained of is not authorized by the copyright owner, its agent, or the law.
+(vi) A statement that the information in the notification is accurate, and under penalty of perjury, that the complaining party is authorized to act on behalf of the owner of an exclusive right that is allegedly infringed.
+
+##11. Editing And Deletions:
+
+The University of Reddit reserves the right, but undertakes no duty, to review, edit, move or delete any material provided for display or placed on the website, in its sole discretion, without notice.
+
+##Privacy Policy
+
+Your privacy is very important to us. Accordingly, we have developed this Policy in order for you to understand how we collect, use, communicate and disclose and make use of personal information. The following outlines our privacy policy.
+
+Please view our Privacy Policy [here](http://ureddit.com/privacy).
+
+We are committed to conducting our business in accordance with these principles in order to ensure that the confidentiality of personal information is protected and maintained.
+
+EOD;
+
+echo process($str);
+?>
+ </div>
+ </div>
+ </div>
+ <?php require_once('footer.php'); ?>
+</body>
+</html>
Please sign in to comment.
Something went wrong with that request. Please try again.