This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Event creation form</title> | |
</head> | |
<!-- All strings - These are mandatory fields title, start_date, end_date, timezone. The description is optional but guess we would require --> | |
<body> | |
<!-- A form to create an event and passes it's variables to event_creator.php --> | |
<form method="post" action="event_creator.php"> | |
<fieldset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/*This script does the following: | |
1. Loads the eventbrite client library | |
2. Get all variables form form | |
3. Puts my eventbrite account details into an array | |
4. Gets the submitted data and puts into an array | |
5. Passes data to API to create event | |
6. Recieve a confomation ticket of newly created event*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*basic styles to display tweets by Mark Atherton*/ | |
ul.tweets { | |
list-style-type: none; | |
background-color: #fbfbde; | |
width: 300px; | |
padding: 0.25em 1.5em 0.25em 1.5em; | |
} | |
ul.tweets h5{ | |
font-size: 1.15em; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
p.small-italics { | |
font-style: italic; | |
font-family: HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, helvetica, arial, sans-serif; | |
font-size: smaller; | |
line-height: 30%; | |
} | |
.sponsor { | |
width: 300px; | |
height: 300px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* Database connection to test database */ | |
$connection = mysql_connect('localhost','wp_user','wp_password'); | |
if (!$connection) | |
{ | |
die('Could not connect: ' . mysql_error()); | |
} | |
mysql_select_db("wordpres",$connection); | |
?> | |
<html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<meta charset="UTF-8"> | |
<head> | |
<!-- include the Tools --> | |
<script src="http://cdn.jquerytools.org/1.2.6/full/jquery.tools.min.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# code for the advert preview and the "why go premium list" on the create new ad form so that it only adopts fixed positioning when all of it is in view. | |
$ -> | |
e = $("div#advert_preview") | |
jWindow = $(window) | |
offsetTop = e.offset().top | |
positionTop = e.position().top | |
jWindow.scroll -> | |
if jWindow.scrollTop() > offsetTop | |
e.css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table width='100%' border='0' cellpadding='4' cellspacing='0'> | |
<tr> | |
<td height='50' colspan='4' bgcolor='#000000'><a href='http://www.thestage.co.uk'><img border='0' src='data:image/jpg;base64,R0lGODlhsAAaAPcAAObm5qCgoHJyckpKSujo6LKyssHAwNbW1oyMjNDQ0L29vYKCghoaGhwcHAoK | |
CjQ0NE5OTn5+fnp6eqampmRkZMjIyEJCQq6urmhoaMrKypSUlMTFxZKSklRVVHR0dA0NDZuamrm5 | |
uZiZmHh4eHx8fIaGhmFiYkZGRhUVFbCwsJ+enqSlpV5eXh4eHlBQUGBgYBISEoSEhFxcXICAgGZm | |
ZjY2NoqKigQEBGtra0RERDg4OFhYWJCQkI6Pjjw8PCoqKp2dnTo6OiwsLCMjI29vbyIiIr+/vxAQ | |
ECgoKDAwMFtaWi8uLz4+PlZXVnZ2dsXFxYmJia+urx0dGyAgICYmJlNTUycmJGpqZERDP/T09DMz | |
M/Pz8zIyMvj4+Pr6+vn5+YeGf8fHx359dk1NSc7OzvX19dra2nRzbampqWFgW7a2tvv7+7W1tfLy | |
8jo6NtnZ2c3Nze7u7u/v7/z8/IKCgZaWlv39/f7+/rq6uq2trdLS0tTU1DAwLVdWUuDg4KysrOHh | |
4aurq6qqquvr65eXl8/Pz9vb2/b29t3d3d7e3uXl5djY2PHx8e3t7ff396urqszMzNXV1eLi4ru7 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class UsersController < ApplicationController | |
before_filter RubyCAS::Filter, :except => :cas_update_user | |
before_filter :check_user, :except => :cas_update_user | |
def promote | |
error = "Please enter your name" if params[:name].blank? | |
error = "Please enter your telephone number" if params[:telephone].blank? | |
error = "Please enter a valid email address" unless params[:email].match(/[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}/) | |
if error.blank? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JQTWEET = { | |
// Set twitter username, number of tweets & id/class to append tweets | |
user: 'insightinternet', | |
numTweets: 3, | |
appendTo: '#jstwitter', | |
// core function of jqtweet | |
loadTweets: function() { | |
$.ajax({ |
OlderNewer