This commit is contained in:
mileswa1q2 authored and GitHub committed 2023-11-06 01:37:18 +00:00
1 parent 3218ee5d47
commit 09460432a0
20 files changed
+14 -858

No files matched your search

+13
View File
@@ -0,0 +1,13 @@
<html>
<head>
<form action="/html/tags/html_form_tag_action.cfm" method="post">
<div>
<textarea name="comments" id="comments" style="font-family:sans-serif;font-size:1.2em;">
Hey... say something!
</textarea>
</div>
<input type="submit" value="Submit">
</form>
</head>
</html>
+1 -1
View File
@@ -10,7 +10,7 @@
<a href="dino.html">dino games</a>
<a href="sonhgs.html">sonhgs</a>
<a href="credits.html">credits</a>
<a href="/pusher-community-realtime-commenting-efa3078/pusher-community-realtime-commenting-efa3078/index.php"></a>
<a href="/coment.html">comments</a>
<a href="https://github.com/mileswolfallen2/funforyou-wedsite/releases/tag/3.0" target="_blank">offline</a>
<a href="/dextensify-master/dextensify-master/index2.html">unbloxer</a>
<a href="coment.html">contacting me</a>
Binary file not shown.
@@ -1,2 +0,0 @@
*.DS_Store
pusher_config.php
@@ -1,108 +0,0 @@
<?php
date_default_timezone_set('UTC');
class Persistence {
private $data = array();
function __construct() {
session_start();
if( isset($_SESSION['blog_comments']) == true ){
$this->data = $_SESSION['blog_comments'];
}
}
/**
* Get all comments for the given post.
*/
function get_comments($comment_post_ID) {
$comments = array();
if( isset($this->data[$comment_post_ID]) == true ) {
$comments = $this->data[$comment_post_ID];
}
return $comments;
}
/**
* Get all comments.
*/
function get_all_comments() {
return $this->data;
}
/**
* Store the comment.
*/
function add_comment($vars) {
$added = false;
$comment_post_ID = $vars['comment_post_ID'];
$input = array(
'comment_author' => $vars['comment_author'],
'email' => $vars['email'],
'comment' => $vars['comment'],
'comment_post_ID' => $comment_post_ID,
'date' => date('r'));
if($this->validate_input($input) == true) {
if( isset($this->data[$comment_post_ID]) == false ) {
$this->data[$comment_post_ID] = array();
}
$input['id'] = uniqid('comment_');
$this->data[$comment_post_ID][] = $input;
$this->sync();
$added = $input;
}
return $added;
}
function delete_all() {
$this->data = array();
$this->sync();
}
private function sync() {
$_SESSION['blog_comments'] = $this->data;
}
/**
* TODO: much more validation and sanitization. Use a library.
*/
private function validate_input($input) {
$input['email'] = filter_var($input['email'], FILTER_SANITIZE_EMAIL);
if (filter_var($input['email'], FILTER_VALIDATE_EMAIL) == false) {
return false;
}
$input['comment_author'] = substr($input['comment_author'], 0, 70);
if($this->check_string($input['comment_author']) == false) {
return false;
}
$input['comment_author'] = htmlentities($input['comment_author']);
$input['comment'] = substr($input['comment'], 0, 300);
if($this->check_string($input['comment'], 5) == false) {
return false;
}
$input['comment'] = htmlentities($input['comment']);
$input['comment_post_ID'] = filter_var($input['comment_post_ID'], FILTER_VALIDATE_INT);
if (filter_var($input['comment_post_ID'], FILTER_VALIDATE_INT) == false) {
return false;
}
return true;
}
private function check_string($string, $min_size = 1) {
return strlen(trim($string)) >= $min_size;
}
}
?>
@@ -1,8 +0,0 @@
<?php
require('Persistence.php');
$db = new Persistence();
$db->delete_all();
print_r($db->get_all_comments());
?>
@@ -1,119 +0,0 @@
/*
Name: Global Form Styles
Description: Default styling for forms.
Message classes borrowed from
http://www.blueprintcss.org/
Coder: Enrique Ramirez
Coder URI: http://enrique-ramirez.com
*/
fieldset {
background: #f9f9f9;
margin: 1.5em;
padding: 2em;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}
legend {font-size: 1.25em; margin-bottom: 0 !important; margin-bottom: 1.429em; padding: 0 .5em;}
label {font-size: 1.1em; height: 25px; line-height: 25px;}
/* Input Types */
input[type='text'],
input[type='email'],
input[type='url'],
textarea {
background: #fff;
border: 1px solid #eee;
color: #999;
font-family: inherit;
font-size: inherit;
padding: 2px;
}
input[type='text']:hover,
input[type='email']:hover,
input[type='url']:hover,
textarea:hover {
background: #FFFBEF;
border-color: #ff0;
cursor: text;
}
input[type='text']:focus,
input[type='email']:focus,
input[type='url']:focus,
textarea:focus {
background: #ffC;
border-color: #ff1;
color: #0d0d0d;
}
input[type='checkbox'], input[type='radio'] {
display: block;
margin-top: 4px;
}
input[type='submit'] {
background: #C74350;
border: 0;
border-radius: 5px;
color: #fff;
cursor: pointer;
font-family: inherit;
font-size: inherit;
padding: .3em 2em;
text-shadow: 1px 1px 1px #000;
}
input:required, textarea:required {outline: 1px solid #C74350;}
/* Textarea */
textarea {width: 99%; margin-bottom: 7px;}
/* Alignments */
div.left {margin-left: 1em;}
div.right {margin-right: 1em;}
.labels-left label, div.left label {
clear: left;
float: left;
margin-right: .5em;
text-align: right;
}
.labels-left input, div.left input, .labels-left select, div.left select {float: left;}
.labels-right label, div.right label {
float: left;
margin-left: .5em;
text-align: right;
}
.labels-right input, div.right input, .labels-right select, div.right select {clear: left; float: left;}
.labels-top label, div.top label {display: block;}
.labels-top input, div.top input {margin-bottom: 0;}
/* Columns */
.columns-2 div.column1, .columns-2 div.column2 {float: left; width: 48%;}
.columns-2 input.text {width: 150px;}
.columns-3 div.column1, .columns-3 div.column2, .columns-3 div.column3 {float: left; width: 33%;}
.columns-3 input.text {width: 120px;}
.columns-2 div.left, .columns-2 div.right, .columns-2 div.top {width: 32%;}
.columns-3 div.left, .columns-3 div.right, .columns-3 div.top {width: 29%;}
/* Messages classes */
.req {color: #C74350;}
.error,.notice, .success {
padding: .2em;
margin-bottom: 1em;
border: 2px solid #ddd;
}
.error {background: #FBE3E4; border-color: #FBC2C4; color: #8a1f11;}
.notice {background: #FFF6BF; border-color: #FFD324; color: #514721;}
.success {background: #E6EFC2; border-color: #C6D880; color: #264409;}
.error a {color: #8a1f11;}
.notice a {color: #514721;}
.success a {color: #264409;}
@@ -1,432 +0,0 @@
/*
Name: Smashing HTML5
Date: July 2009
Description: Sample layout for HTML5 and CSS3 goodness.
Version: 1.0
Author: Enrique Ramírez
Autor URI: http://enrique-ramirez.com
*/
/* Imports */
@import url("reset.css");
@import url("global-forms.css");
/***** Global *****/
/* Body */
body {
background: #F5F4EF url('../images/bg.png');
color: #000305;
font-size: 87.5%; /* Base font size: 14px */
font-family: 'Trebuchet MS', Trebuchet, 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
line-height: 1.429;
margin: 0;
padding: 0;
text-align: left;
}
/* Headings */
h2 {font-size: 1.571em} /* 22px */
h3 {font-size: 1.429em} /* 20px */
h4 {font-size: 1.286em} /* 18px */
h5 {font-size: 1.143em} /* 16px */
h6 {font-size: 1em} /* 14px */
h2, h3, h4, h5, h6 {
font-weight: 400;
line-height: 1.1;
margin-bottom: .8em;
}
/* Anchors */
a {outline: 0;}
a img {border: 0px; text-decoration: none;}
a:link, a:visited {
color: #C74350;
padding: 0 1px;
text-decoration: underline;
}
a:hover, a:active {
background-color: #C74350;
color: #fff;
text-decoration: none;
text-shadow: 1px 1px 1px #333;
}
/* Paragraphs */
p {margin-bottom: 1.143em;}
* p:last-child {margin-bottom: 0;}
strong, b {font-weight: bold;}
em, i {font-style: italic;}
::-moz-selection {background: #F6CF74; color: #fff;}
::selection {background: #F6CF74; color: #fff;}
/* Lists */
ul {
list-style: outside disc;
margin: 1em 0 1.5em 1.5em;
}
ol {
list-style: outside decimal;
margin: 1em 0 1.5em 1.5em;
}
dl {margin: 0 0 1.5em 0;}
dt {font-weight: bold;}
dd {margin-left: 1.5em;}
/* Quotes */
blockquote {font-style: italic;}
cite {}
q {}
/* Tables */
table {margin: .5em auto 1.5em auto; width: 98%;}
/* Thead */
thead th {padding: .5em .4em; text-align: left;}
thead td {}
/* Tbody */
tbody td {padding: .5em .4em;}
tbody th {}
tbody .alt td {}
tbody .alt th {}
/* Tfoot */
tfoot th {}
tfoot td {}
/* HTML5 tags */
header, section, footer,
aside, nav, article, figure {
display: block;
}
/***** Layout *****/
.body {clear: both; margin: 0 auto; width: 800px;}
img.right figure.right {float: right; margin: 0 0 2em 2em;}
img.left, figure.left {float: right; margin: 0 0 2em 2em;}
/*
Header
*****************/
#banner {
margin: 0 auto;
padding: 2.5em 0 0 0;
}
/* Banner */
#banner h1 {font-size: 3.571em; line-height: .6;}
#banner h1 a:link, #banner h1 a:visited {
color: #000305;
display: block;
font-weight: bold;
margin: 0 0 .6em .2em;
text-decoration: none;
width: 427px;
}
#banner h1 a:hover, #banner h1 a:active {
background: none;
color: #C74350;
text-shadow: none;
}
#banner h1 strong {font-size: 0.36em; font-weight: normal;}
/* Main Nav */
#banner nav {
background: #000305;
font-size: 1.143em;
height: 40px;
line-height: 30px;
margin: 0 auto 2em auto;
padding: 0;
text-align: center;
width: 800px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}
#banner nav ul {list-style: none; margin: 0 auto; width: 800px;}
#banner nav li {float: left; display: inline; margin: 0;}
#banner nav a:link, #banner nav a:visited {
color: #fff;
display: inline-block;
height: 30px;
padding: 5px 1.5em;
text-decoration: none;
}
#banner nav a:hover, #banner nav a:active,
#banner nav .active a:link, #banner nav .active a:visited {
background: #C74451;
color: #fff;
text-shadow: none !important;
}
#banner nav li:first-child a {
border-top-left-radius: 5px;
-moz-border-radius-topleft: 5px;
-webkit-border-top-left-radius: 5px;
border-bottom-left-radius: 5px;
-moz-border-radius-bottomleft: 5px;
-webkit-border-bottom-left-radius: 5px;
}
/*
Featured
*****************/
#featured {
background: #fff;
margin-bottom: 2em;
overflow: hidden;
padding: 20px;
width: 760px;
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
}
#featured figure {
border: 2px solid #eee;
float: right;
margin: 0.786em 2em 0 5em;
width: 248px;
}
#featured figure img {display: block; float: right;}
#featured h2 {color: #C74451; font-size: 1.714em; margin-bottom: 0.333em;}
#featured h3 {font-size: 1.429em; margin-bottom: .5em;}
#featured h3 a:link, #featured h3 a:visited {color: #000305; text-decoration: none;}
#featured h3 a:hover, #featured h3 a:active {color: #fff;}
/*
Body
*****************/
#content {
background: #fff;
margin-bottom: 2em;
overflow: hidden;
padding: 20px 20px;
width: 760px;
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
}
/*
Extras
*****************/
#extras {margin: 0 auto 3em auto; overflow: hidden;}
#extras ul {list-style: none; margin: 0;}
#extras li {border-bottom: 1px solid #fff;}
#extras h2 {
color: #C74350;
font-size: 1.429em;
margin-bottom: .25em;
padding: 0 3px;
}
#extras a:link, #extras a:visited {
color: #444;
display: block;
border-bottom: 1px solid #F4E3E3;
text-decoration: none;
padding: .3em .25em;
}
#extras li:last-child,
#extras li:last-child a {border: 0}
#extras .blogroll li:nth-last-child(2),
#extras .blogroll li:nth-last-child(3),
#extras .blogroll li:nth-last-child(2) a,
#extras .blogroll li:nth-last-child(3) a {border: 0;}
#extras a:hover, #extras a:active {color: #fff;}
/* Blogroll */
#extras .blogroll {
float: left;
width: 615px;
}
#extras .blogroll li {float: left; margin: 0 20px 0 0; width: 185px;}
/* Social */
#extras .social {
float: right;
width: 175px;
}
#extras div[class='social'] a {
background-repeat: no-repeat;
background-position: 3px 6px;
padding-left: 25px;
}
/* Icons */
.social a[href*='delicious.com'] {background-image: url('../images/icons/delicious.png');}
.social a[href*='digg.com'] {background-image: url('../images/icons/digg.png');}
.social a[href*='facebook.com'] {background-image: url('../images/icons/facebook.png');}
.social a[href*='last.fm'], .social a[href*='lastfm.'] {background-image: url('../images/icons/lastfm.png');}
.social a[href*='/feed/'] {background-image: url('../images/icons/rss.png');}
.social a[href*='twitter.com'] {background-image: url('../images/icons/twitter.png');}
/*
About
*****************/
#about {
background: #fff;
font-style: normal;
margin-bottom: 2em;
overflow: hidden;
padding: 20px;
text-align: left;
width: 760px;
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
}
#about .primary {float: left; width: 165px;}
#about .primary strong {color: #C64350; display: block; font-size: 1.286em;}
#about .photo {float: left; margin: 5px 20px;}
#about .url:link, #about .url:visited {text-decoration: none;}
#about .bio {float: right; width: 500px;}
/*
Footer
*****************/
#contentinfo {padding-bottom: 2em; text-align: right;}
/***** Sections *****/
/* Blog */
.hentry {
border-bottom: 1px solid #eee;
padding: 1.5em 0;
}
li:last-child .hentry, #content > .hentry {border: 0; margin: 0;}
#content > .hentry {padding: 1em 0;}
.entry-title {font-size: 1.429em; margin-bottom: 0;}
.entry-title a:link, .entry-title a:visited {text-decoration: none;}
.hentry .post-info * {font-style: normal;}
/* Content */
.hentry footer {margin-bottom: 2em;}
.hentry footer address {display: inline;}
#posts-list footer address {display: block;}
/* Blog Index */
#posts-list {list-style: none; margin: 0;}
#posts-list .hentry {padding-left: 200px; position: relative;}
#posts-list .hentry:hover {
background: #C64350;
color: #fff;
}
#posts-list .hentry:hover a:link, #posts-list .hentry:hover a:visited {
color: #F6CF74;
text-shadow: 1px 1px 1px #333;
}
#posts-list footer {
left: 10px;
position: absolute;
top: 1.5em;
width: 190px;
}
/* About the Author */
#about-author {
background: #f9f9f9;
clear: both;
font-style: normal;
margin: 2em 0;
padding: 10px 20px 15px 20px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}
#about-author strong {
color: #C64350;
clear: both;
display: block;
font-size: 1.429em;
}
#about-author .photo {border: 1px solid #ddd; float: left; margin: 5px 1em 0 0;}
/* Comments */
#comments-list {list-style: none; margin: 0 1em;}
#comments-list blockquote {
background: #f8f8f8;
clear: both;
font-style: normal;
margin: 0;
padding: 15px 20px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}
#comments-list footer {color: #888; padding: .5em 1em 0 0; text-align: right;}
#comments-list li:nth-child(2n) blockquote {background: #F5f5f5;}
/* Add a Comment */
#add-comment label {clear: left; float: left; text-align: left; width: 150px;}
#add-comment input[type='text'],
#add-comment input[type='email'],
#add-comment input[type='url'] {float: left; width: 200px;}
#add-comment textarea {float: left; height: 150px; width: 495px;}
#add-comment p.req {clear: both; margin: 0 .5em 1em 0; text-align: right;}
#add-comment input[type='submit'] {float: right; margin: 0 .5em;}
#add-comment * {margin-bottom: .5em;}
#comments {
background: #fff;
margin-bottom: 2em;
overflow: hidden;
padding: 20px 20px;
width: 760px;
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
}
#comments label {
display: block;
}
#comments label:after {
content:" *";
}
#comments ol li:nth-child(2n+1) {
background-color: #F5F4EF;
}
@@ -1,52 +0,0 @@
/*
Name: Reset Stylesheet
Description: Resets browser's default CSS
Author: Eric Meyer
Author URI: http://meyerweb.com/eric/tools/css/reset/
*/
/* v1.0 | 20080212 */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td {
background: transparent;
border: 0;
font-size: 100%;
margin: 0;
outline: 0;
padding: 0;
vertical-align: baseline;
}
body {line-height: 1;}
ol, ul {list-style: none;}
blockquote, q {quotes: none;}
blockquote:before, blockquote:after,
q:before, q:after {
content: '';
content: none;
}
/* remember to define focus styles! */
:focus {
outline: 0;
}
/* remember to highlight inserts somehow! */
ins {text-decoration: none;}
del {text-decoration: line-through;}
/* tables still need 'cellspacing="0"' in the markup */
table {
border-collapse: collapse;
border-spacing: 0;
}
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 896 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

@@ -1,136 +0,0 @@
<!DOCTYPE html>
<html lang="en-US">
<head>
<title>Smashing HTML5!</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="css/main.css" type="text/css" />
<!--[if IE]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
<!--[if lte IE 7]>
<link rel="stylesheet" type="text/css" media="all" href="css/ie.css"/>
<script src="js/IE8.js" type="text/javascript"></script><![endif]-->
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" media="all" href="css/ie6.css"/><![endif]-->
</head>
<body id="index" class="home">
<header id="banner" class="body">
<h1><a href="#">Smashing HTML5! <strong>HTML5 in the year <del>2022</del> <ins>2012</ins></strong></a></h1>
<nav><ul>
<li class="active"><a href="#">home</a></li>
<li><a href="#">portfolio</a></li>
<li><a href="#">blog</a></li>
<li><a href="#">contact</a></li>
</ul></nav>
</header>
<section id="content" class="body">
<article class="hentry">
<header>
<h2 class="entry-title"><a href="#" rel="bookmark" title="Permalink to this Building a Pusher-powered Real-Time Commenting System">Building a Pusher-powered Real-Time Commenting System</a></h2>
</header>
<footer class="post-info">
<abbr class="published" title="2012-02-10T14:07:00-07:00">
10th February 2012
</abbr>
<address class="vcard author">
By <a class="url fn" href="#">Phil Leggetter</a>
</address>
</footer>
<div class="entry-content">
<p>The web has become increasingly interactive over the years. This trend is set to continue with the next generation of applications driven by the <strong>real-time web</strong>. Adding real-time functionality to an application can result in a more interactive and engaging user experience. However, setting up and maintaining the server-side realtime components can be an unwanted distraction. But don't worry, there is a solution.</p>
</div>
</article>
</section>
<section id="comments" class="body">
<header>
<h2>Comments</h2>
</header>
<ol id="posts-list" class="hfeed">
<li><article id="comment_1" class="hentry">
<footer class="post-info">
<abbr class="published" title="Thu, 23 Feb 2012 23:54:46 +0000">
23 February 2012
</abbr>
<address class="vcard author">
By <a class="url fn" href="#">Phil Leggetter</a>
</address>
</footer>
<div class="entry-content">
<p>The Realtime Web Rocks!</p>
</div>
</article></li>
</ol>
</section>
<section id="extras" class="body">
<div class="blogroll">
<h2>blogroll</h2>
<ul>
<li><a href="#" rel="external">HTML5 Doctor</a></li>
<li><a href="#" rel="external">HTML5 Spec (working draft)</a></li>
<li><a href="#" rel="external">Smashing Magazine</a></li>
<li><a href="#" rel="external">W3C</a></li>
<li><a href="#" rel="external">Wordpress</a></li>
<li><a href="#" rel="external">Wikipedia</a></li>
<li><a href="#" rel="external">HTML5 Doctor</a></li>
<li><a href="#" rel="external">HTML5 Spec (working draft)</a></li>
<li><a href="#" rel="external">Smashing Magazine</a></li>
<li><a href="#" rel="external">W3C</a></li>
<li><a href="#" rel="external">Wordpress</a></li>
<li><a href="#" rel="external">Wikipedia</a></li>
<li><a href="#" rel="external">HTML5 Doctor</a></li>
<li><a href="#" rel="external">HTML5 Spec (working draft)</a></li>
<li><a href="#" rel="external">Smashing Magazine</a></li>
<li><a href="#" rel="external">W3C</a></li>
<li><a href="#" rel="external">Wordpress</a></li>
<li><a href="#" rel="external">Wikipedia</a></li><article class="hentry">
</ul>
</div>
<div class="social">
<h2>social</h2>
<ul>
<li><a href="http://delicious.com/">delicious</a></li>
<li><a href="http://digg.com/">digg</a></li>
<li><a href="http://facebook.com/">facebook</a></li>
<li><a href="http://www.last.fm">last.fm</a></li>
<li><a href="http://website.com/feed/" rel="alternate">rss</a></li>
<li><a href="http://twitter.com/">twitter</a></li>
</ul>
</div>
</section>
<footer id="contentinfo" class="body">
<address id="about" class="vcard body">
<span class="primary">
<strong><a href="#" class="fn url">Smashing Magazine</a></strong>
<span class="role">Amazing Magazine</span>
</span>
<img src="images/avatar.gif" alt="Smashing Magazine Logo" class="photo" />
<span class="bio">Smashing Magazine is a website and blog that offers resources and advice to web developers and web designers. It was founded by Sven Lennartz and Vitaly Friedman.</span>
</address>
<p>2005-2012 <a href="http://smashingmagazine.com">Smashing Magazine</a>.</p>
</footer>
</body>
</html>