Committing changes that were on the server to later merge it with master

This commit is contained in:
Bruno Parga 2016-07-26 18:49:00 +00:00
parent eee4fed3cf
commit 515ae2ee89
21 changed files with 864 additions and 427 deletions

View file

@ -13,7 +13,18 @@ class Controller
$viewParameters = isset($viewAndParams[1]) ? $viewAndParams[1] : [];
$headers = isset($viewAndParams[2]) ? $viewAndParams[2] : [];
static::sendHeaders($headers);
$defaultHeaders = [
'Content-Security-Policy' => "frame-ancestors 'none'",
'X-Frame-Options' => 'DENY',
'X-XSS-Protection'=> '1',
];
if (IS_PRODUCTION)
{
$defaultHeaders['Strict-Transport-Security'] = 'max-age=31536000';
}
static::sendHeaders(array_merge($defaultHeaders, $headers));
if ($viewTemplate === null)
{
@ -47,12 +58,6 @@ class Controller
{
case '/':
return ContentActions::executeHome();
case '/fund':
return CreditActions::executeFund();
case '/fund-after':
return ['fund/fund-after'];
case '/goals':
return ['fund/goals'];
case '/get':
case '/windows':
case '/ios':
@ -66,17 +71,27 @@ class Controller
return OpsActions::executeLogUpload();
case '/list-subscribe':
return MailActions::executeListSubscribe();
case '/press-kit.zip':
return ContentActions::executePressKit();
case '/LBRY-deck.pdf':
return static::redirect('https://s3.amazonaws.com/files.lbry.io/LBRY-deck.pdf', 307);
case '/dl/lbry_setup.sh':
return ['internal/dl-not-supported', ['_no_layout' => true]];
case '/deck.pdf':
return static::redirect('https://www.dropbox.com/s/0xj4vgucsbi8rtv/lbry-deck.pdf?dl=1');
case '/pln.pdf':
case '/plan.pdf':
return static::redirect('https://www.dropbox.com/s/uevjrwnyr672clj/lbry-pln.pdf?dl=1');
case '/lbry-osx-latest.dmg':
return static::redirect('https://github.com/lbryio/lbry/releases/download/v0.2.4/lbry.0.2.4.dmg', 307);
case '/lbry-linux-latest.deb':
return static::redirect('https://github.com/lbryio/lbry/releases/download/v0.2.4/lbry_0.2.4_amd64.deb', 307);
case '/dl/lbry_setup.sh':
return static::redirect('/get', 301);
case '/art':
return static::redirect('/what');
default:
return static::redirect('/what', 301);
case '/why':
case '/feedback':
return static::redirect('/learn', 301);
case '/faq/when-referral-payouts':
return static::redirect('/faq/referrals', 301);
}
$newsPattern = '#^' . ContentActions::URL_NEWS . '(/|$)#';
if (preg_match($newsPattern, $uri))
{
@ -85,15 +100,23 @@ class Controller
{
return ContentActions::executeRss();
}
return $slug ? ContentActions::executePost($uri) : ContentActions::executeNews();
return $slug ? ContentActions::executeNewsPost($uri) : ContentActions::executeNews();
}
$faqPattern = '#^' . ContentActions::URL_FAQ . '(/|$)#';
if (preg_match($faqPattern, $uri))
{
$slug = preg_replace($faqPattern, '', $uri);
return $slug ? ContentActions::executePost($uri) : ContentActions::executeFaq();
return $slug ? ContentActions::executeFaqPost($uri) : ContentActions::executeFaq();
}
$noSlashUri = ltrim($uri, '/');
$accessPattern = '#^/signup#';
if (preg_match($accessPattern, $uri))
{
return DownloadActions::executeSignup();
}
if (View::exists('page/' . $noSlashUri))
{
return ['page/' . $noSlashUri, []];
@ -103,7 +126,6 @@ class Controller
return ['page/404', [], [static::HEADER_STATUS => 404]];
}
}
}
public static function redirect($url, $statusCode = 302)
{

View file

@ -8,6 +8,9 @@
class Session
{
const KEY_MAILCHIMP_LIST_IDS = 'mailchimp_list_ids',
KEY_DOWNLOAD_ACCESS_ERROR = 'download_error2',
KEY_DOWNLOAD_ALLOWED = 'beta_download_allowed2',
KEY_PREFINERY_USER_ID = 'prefinery_user_id',
KEY_LIST_SUB_ERROR = 'list_error',
KEY_LIST_SUB_SIGNATURE = 'list_sub_sig',
KEY_LIST_SUB_SUCCESS = 'list_success',
@ -15,7 +18,10 @@ class Session
public static function init()
{
session_start();
session_start([
'cookie_secure' => IS_PRODUCTION, // cookie over ssl only
'cookie_httponly' => true, // no js access
]);
}
public static function get($key, $default = null)

View file

@ -24,8 +24,28 @@ class ContentActions extends Actions
public static function executeFaq()
{
$posts = Post::find(static::VIEW_FOLDER_FAQ);
$groupNames = [
'getstarted' => 'Getting Started',
'install' => 'Installing LBRY',
'running' => 'Running LBRY',
'wallet' => 'The LBRY Wallet',
'hosting' => 'Hosting Content',
'mining' => 'Mining LBC',
'developer' => 'Developers',
'other' => 'Other Questions',
];
$groups = array_fill_keys(array_keys($groupNames), []);
foreach($posts as $post)
{
$groups[isset($groupNames[$post->getCategory()]) ? $post->getCategory() : 'other'][] = $post;
}
return ['content/faq', [
'posts' => $posts
'groupNames' => $groupNames,
'postGroups' => $groups
]];
}
@ -52,14 +72,14 @@ class ContentActions extends Actions
]];
}
public static function executePost($relativeUri)
public static function executeNewsPost($relativeUri)
{
$post = Post::load(ltrim($relativeUri, '/'));
if (!$post)
{
return ['page/404', []];
}
return ['content/post', [
return ['content/news-post', [
'post' => $post,
View::LAYOUT_PARAMS => [
'showRssLink' => true
@ -67,6 +87,93 @@ class ContentActions extends Actions
]];
}
public static function executeFaqPost($relativeUri)
{
$post = Post::load(ltrim($relativeUri, '/'));
if (!$post)
{
return ['page/404', []];
}
return ['content/faq-post', [
'post' => $post,
]];
}
public static function executePressKit()
{
$zipFileName = 'lbry-press-kit-' . date('Y-m-d') . '.zip';
$zipPath = tempnam('/tmp', $zipFileName);
$zip = new ZipArchive();
$zip->open($zipPath, ZipArchive::OVERWRITE);
// $pageHtml = View::render('page/press-kit', ['showHeader' => false]);
// $html = <<<EOD
//<!DOCTYPE html>
//<html>
// <head prefix="og: http://ogp.me/ns#">
// <title>LBRY Press Kit</title>
// <link href='https://fonts.googleapis.com/css?family=Raleway:300,300italic,400,400italic,700' rel='stylesheet' type='text/css'>
// <link href="https://lbry.io/css/all.css" rel="stylesheet" type="text/css" media="screen,print" />
// </head>
// <body>
// $pageHtml
// </body>
//</html>
//EOD;
//
// $zip->addFromString('press.html', $html);
foreach(glob(ROOT_DIR . '/web/img/press/*') as $productImgPath)
{
$imgPathTokens = explode('/', $productImgPath);
$imgName = $imgPathTokens[count($imgPathTokens) - 1];
$zip->addFile($productImgPath, '/logo_and_product/' . $imgName);
}
foreach(glob(ROOT_DIR . '/posts/bio/*.md') as $bioPath)
{
list($metadata, $bioHtml) = View::parseMarkdown($bioPath);
$zip->addFile($bioPath, '/team_bios/' . $metadata['name'] . ' - ' . $metadata['role'] . '.txt');
}
foreach(array_filter(glob(ROOT_DIR . '/web/img/team/*.jpg'), function($path) {
return strpos($path, 'spooner') === false;
}) as $bioImgPath)
{
$imgPathTokens = explode('/', $bioImgPath);
$imgName = str_replace('644x450', 'lbry', $imgPathTokens[count($imgPathTokens) - 1]);
$zip->addFile($bioImgPath, '/team_photos/' . $imgName);
}
$zip->close();
return ['internal/zip', [
'_no_layout' => true,
'zipPath' => $zipPath
], [
'Content-Disposition' => 'attachment;filename=' . $zipFileName,
'X-Content-Type-Options' => 'nosniff',
'Content-Type' => 'application/zip',
'Content-Length' => filesize($zipPath),
]];
}
public static function prepareBioPartial(array $vars)
{
$person = $vars['person'];
$path = 'bio/' . $person . '.md';
list($metadata, $bioHtml) = View::parseMarkdown($path);
$relativeImgSrc = '/img/team/' . $person . '-644x450.jpg';
$imgSrc = file_exists(ROOT_DIR . '/web' . $relativeImgSrc) ? $relativeImgSrc : '/img/team/spooner-644x450.jpg';
return $vars + $metadata + [
'imgSrc' => $imgSrc,
'bioHtml' => $bioHtml,
'orientation' => 'vertical'
];
}
public static function preparePostAuthorPartial(array $vars)
{
$post = $vars['post'];

View file

@ -1,10 +1,5 @@
<?php
/**
* Description of DownloadActions
*
* @author jeremy
*/
class DownloadActions extends Actions
{
const OS_ANDROID = 'android',
@ -26,25 +21,95 @@ class DownloadActions extends Actions
public static function executeGet()
{
$email = static::param('e');
if ($email)
{
$emailIsValid = filter_var($email, FILTER_VALIDATE_EMAIL);
$user = [];
if ($emailIsValid)
{
$user = Prefinery::findUser($email);
if ($user)
{
static::setSessionVarsForPrefineryUser($user);
}
}
if (!$emailIsValid || !$user)
{
Session::unsetKey(Session::KEY_PREFINERY_USER_ID);
Session::unsetKey(Session::KEY_DOWNLOAD_ALLOWED);
}
}
if (!Session::get(Session::KEY_DOWNLOAD_ALLOWED))
{
return ['download/get', ['os' => static::guessOs()]];
}
$osChoices = static::getOses();
$os = static::guessOs();
if ($os && isset($osChoices[$os]))
{
list($uri, $osTitle, $osIcon, $partial) = $osChoices[$os];
return ['download/get', [
return ['download/getAllowed', [
'os' => $os,
'osTitle' => $osTitle,
'osIcon' => $osIcon,
'prefineryUser' => $user ?: [],
'downloadHtml' => View::exists('download/' . $partial) ?
View::render('download/' . $partial) :
View::render('download/' . $partial, ['downloadUrl' => static::getDownloadUrl($os)]) :
false
]];
}
return ['download/get-no-os', [
'isSubscribed' => in_array(Mailchimp::LIST_GENERAL_ID, Session::get(Session::KEY_MAILCHIMP_LIST_IDS, []))
]];
return ['download/get-no-os'];
}
public static function executeSignup()
{
$email = static::param('email');
$code = static::param('code');
if (!$email || !filter_var($email, FILTER_VALIDATE_EMAIL))
{
Session::set(Session::KEY_DOWNLOAD_ACCESS_ERROR, 'Please provide a valid email. You provided: ' . htmlspecialchars($email));
}
else
{
$referrerId = static::param('referrer_id');
$failure = false;
try
{
MailActions::subscribeToMailchimp($email, Mailchimp::LIST_GENERAL_ID);
}
catch (MailchimpSubscribeException $e)
{
}
try
{
$user = Prefinery::findOrCreateUser($email, $code, $referrerId);
static::setSessionVarsForPrefineryUser($user);
}
catch (PrefineryException $e)
{
$failure = true;
}
if ($failure)
{
Session::set(Session::KEY_DOWNLOAD_ALLOWED, false);
Session::set(Session::KEY_DOWNLOAD_ACCESS_ERROR,
'We were unable to add you to the wait list. Received error "' . $e->getMessage() . '". Please contact ' .
Config::HELP_CONTACT_EMAIL . ' if you think this is a mistake.');
}
}
return Controller::redirect('/get');
}
public static function prepareListPartial(array $vars)
@ -55,6 +120,39 @@ class DownloadActions extends Actions
];
}
public static function prepareSignupPartial(array $vars)
{
return $vars + [
'defaultEmail' => static::param('e'),
'allowInviteCode' => true,
'referralCode' => static::param('r', '')
];
}
protected static function setSessionVarsForPrefineryUser($userData)
{
Session::set(Session::KEY_DOWNLOAD_ALLOWED, in_array($userData['status'], [Prefinery::STATE_ACTIVE, Prefinery::STATE_INVITED]));
Session::set(Session::KEY_PREFINERY_USER_ID, (int)$userData['id']);
}
public static function prepareReferPartial(array $vars)
{
$userId = (int)Session::get(Session::KEY_PREFINERY_USER_ID);
if (!$userId)
{
return null;
}
$prefineryUser = Prefinery::findUser($userId);
preg_match('/\?r\=(\w+)/', $prefineryUser['share_link'], $matches);
return $vars + [
'prefineryUser' => $prefineryUser,
'referralCode' => $matches[1] ?: 'unknown'
];
}
protected static function guessOs()
{
//if exact OS is requested, use that
@ -89,39 +187,53 @@ class DownloadActions extends Actions
return null;
}
// protected static function validateDownloadAccess()
// {
// $seshionKey = 'has-get-access';
// if (Session::get($seshionKey))
// {
// return true;
// }
//
// if ($_SERVER['REQUEST_METHOD'] === 'POST')
// {
// $accessCodes = include ROOT_DIR . '/data/secret/access_list.php';
// $today = date('Y-m-d H:i:s');
// foreach($accessCodes as $code => $date)
// {
// if ($_POST['invite'] == $code && $today <= $date)
// {
// Session::set($seshionKey, true);
// Controller::redirect('/get', 302);
// }
// }
//
// if ($_POST['invite'])
// {
// Session::set('invite_error', 'Please provide a valid invite code.');
// }
// else
// {
// Session::set('invite_error', 'Please provide an invite code.');
// }
//
// Controller::redirect('/get', 401);
// }
//
// return false;
// }
protected static function getDownloadUrl($os, $useCache = true)
{
if (!in_array($os, array_keys(static::getOses())))
{
throw new DomainException('Unknown OS');
}
$apc = $useCache && extension_loaded('apc') && ini_get('apc.enabled');
$key = 'lbry_release_data';
$releaseData = null;
if ($apc)
{
$releaseData = apc_fetch($key);
}
if (!$releaseData)
{
try
{
$releaseData =
json_decode(Curl::get('https://api.github.com/repos/lbryio/lbry/releases/latest', [], ['user_agent' => 'LBRY']), true);
if ($apc)
{
apc_store($key, $releaseData, 600); // cache for 10 min
}
}
catch (Exception $e)
{
}
}
if (!$releaseData)
{
return null;
}
foreach ($releaseData['assets'] as $asset)
{
if ($os == static::OS_LINUX && in_array($asset['content_type'], ['application/x-debian-package', 'application/x-deb']) ||
$os == static::OS_OSX && $asset['content_type'] == 'application/x-diskcopy'
)
{
return $asset['browser_download_url'];
}
}
return null;
}
}

View file

@ -12,13 +12,19 @@ global:
tagline: Play, Share, Earn.
sentence: Watch, read and play in a decentralized digital library controlled by the community.
title:
home: LBRY - Watch, Share, Earn
home: LBRY - Play, Share, Earn
what: "Art in the Internet Age: An Introduction to LBRY"
learn: Learn About LBRY
publish: Publish
description:
home: Meet LBRY, a content sharing and publishing platform that is decentralized and owned by its users.
faq: Frequently asked questions about LBRY.
get: Download/install the latest version of LBRY.
news: Access information and content in ways you never dreamed possible. Earn credits for your unused bandwidth and diskspace.
what: Access information and content in ways you never dreamed possible. Earn credits for your unused bandwidth and diskspace.
team: LBRY is founded by a team passionate about connecting producers and consumers and breaking down broken models. Learn more about them.
learn: Learn more about LBRY, the technology that puts you back in control of the internet.
publish: Publish your content on the world's first platform that leaves creators in control.
email:
disclaimer: You will receive 1-2 messages a month, only from LBRY, Inc. and only about LBRY. You can easily unsubscribe at any time.
page:
@ -86,4 +92,5 @@ social:
tweets: Tweets by @LBRYio
download:
main:
title: LBRY for %os%
title: Get LBRY
signup: LBRY is currently in invite only mode. Enter your email to join the waitlist, or your email and invite code for access.

View file

@ -0,0 +1,31 @@
---
title: How do I mine LBRY credits?
category: mining
---
Library Credits (LBC) are mined over a 20-year Proof of Work period.
Block rewards increase every 100 blocks by 1LBC, peak at 500, and decline slowly.
For GPU mining, please see our list of [pools](https://lbry.io/faq/mining-pools). Each pool has a slightly different setup so please check their Getting Started page.
For CPU mining, LBRY binaries are out for OS X and Ubuntu. Others may try compiling from source.
## Mining on Ubuntu
1. `wget https://s3.amazonaws.com/files.lbry.io/bins.zip`
1. `unzip bins.zip`
1. `./lbrycrdd -server -printtoconsole -gen`
1. If you need to start over, run `rm -rf bins.zip lbry* ~/.lbry*`. **Note:** this will delete your wallet and any credits you may have.
## Mining on macOS
1. `wget https://s3.amazonaws.com/files.lbry.io/osxbins.zip`
1. `unzip osxbins.zip`
1. `mkdir ~/Library/Application\ Support/lbrycrd`
1. `sudo chown -R "$(whoami)" ~/Library/Application\ Support/lbrycrd`
1. `echo -e "rpcuser=lbryrpc\nrpcpassword=$(env LC_CTYPE=C LC_ALL=C tr -dc A-Za-z0-9 < /dev/urandom | head -c 16 | xargs)" > ~/Library/Application\ Support/lbrycrd/lbrycrd.conf`
1. `./lbrycrdd -server -printtoconsole -gen`
1. If you need to start over, run `rm -rf bins.zip lbry* ~/.lbry ~/Library/Application\ Support/lbrycrd`. **Note:** this will delete your wallet and any credits you may have.
## Compiling
Join us on [Slack](https://slack.lbry.io) if you need help compiling from source!

View file

@ -0,0 +1,109 @@
---
author: lbry
title: 'Walking a Day in Venezuelan Shoes'
date: '2016-07-26 00:09:18'
cover: 'venezuela.jpg'
---
Javier, a young Venezuelan and cryptocurrency advocate, joined [LBRYs Slack](http://slack.lbry.io/) earlier this month to get access to our beta and learn more about LBRYs vision.
He shared with us a brief look into his life in Venezuela, where a socialist government has mismanaged the economy to the point of destruction. The local currency, the Venezuelan bolivar, is forecast to experience [1,600% inflation next year](http://blogs.wsj.com/economics/2016/07/18/venezuelas-inflation-is-set-to-top-1600-next-year/). Inflation will reach almost 500% this year.
Venezuelans of all income levels are struggling with crippling shortages of food, medicine, and the most basic everyday products. Riots in the streets are almost a daily occurrence. The President has just given [control of the food supply to the military](http://www.wsj.com/articles/venezuelan-president-puts-armed-forces-in-charge-of-new-food-supply-system-1468335415).
At the time Javier joined us, we had enabled LBRY Credit (LBC) tipping on our Slack channels. Someone sent Javier a small tip, and he responded:
>”From the deepest corner of my heart, thanks a lot sir. I live in a poor country and I starve everyday. ... I really hope we get a new president this year. I can wait no longer, if hunger or insecurity doesn't kill me, sadness will."
We asked him to tell us his story and that is what follows, with minor edits for clarity.
You can help Javier by sending him BTC or LBC:
**BTC:** 35jRKCLRXjL5j8sJDJJQZHmHkMNa18EVR5
**LBC:** bbBNDgX9WDKEWTaGkCi7yDjcaPdRb6GM4L
**<center>Walking a Day in Venezuelan Shoes</center>**
*<center>By Javier [Name Redacted for Safety]</center>*
**The day starts**
You get up early in the morning, you clean yourself, you say hi to your family, you take your breakfast and you go to work, you meet your work schedule, you go to the supermarket and get some food, you get home, share with your family, maybe watch TV news, and then you rest to get ready for another day of living.
I bet this sounds like the day of most of you, because that is the way it should be: You work to get bread to the table. What could defer this short description of the day of an average worker in Venezuela? The answer might take your breath away.
While it is true that here in Venezuela you have to comply with these general guidelines, the truth is that sometimes it is not that easy.
**May the odds be ever in your favor**
Heres how your day really looks in modern Venezuela.
You get up, you clean yourself, you say hi to your family. Up to here everything is normal. Then you have to take the first important decision in your day: Should I have breakfast?
You get paid monthly $33 VEF (Venezuelan bolivars), which is on average $1.10 US dollars per day. For 1 kg of flour, you must pay $1.4 VEF; for 1Kg of sugar you must pay $1.8; $3 for beans; even for a 2-liter Coke you must pay $1.2. You just can't afford it.
In order to be able to buy some food, you must stand in long lines at the supermarkets for hours (4 on average) under a hot, 40°C sunny day.
You must struggle against insecurity. In these lines people get killed by the hands of their fellow citizens. Under anguish and despair they just fall to madness, because these foods are sold on the black market for 4 times their price. Not to mention the constant threat of motorized criminals that even for an smart phone may take your life.
Getting medicines is not easy. Old people die for lack of medicines to treat high tension and cholesterol. Even a painkiller is something that you will rarely see in a pharmacy.
Lets say that you managed to get some food for today, and you are healthy. Whats next? Maybe you want a little distraction go to movie theater, perhaps. Let me tell you that on a movie and a few snacks you can easily spend $14 VEF (almost 13 days of wages).
A car? Ha! You must work for two years without spending a single nickel in order to get an old, rusty car.
A house? Thats 20 years of salary, and you know, don't spend a single bolivar in the meantime, because you'll take longer to save.
**Don't think out loud**
Maybe you feel like expressing yourself about the situation that you are living in, but hey! Don't do it on social networks, because the police might go to your home and take you to jail just because you are talking bad of the government or telling the truth.
**Study. But not for you, for them**
You can prepare yourself as a professional and get a PhD. But that is worth nothing because a taxi driver can earn a lot more than any professional. (No offense to taxi drivers, I'm truly thankful for your services.)
Maybe it will work if you study in a government institution. But here, history books aren't what they used to be, because they have rewritten the whole history to make the government look illustrious, victorious, capable.
**Clap like a seal, nod like an iguana**
The only people that might have a chance of not going through so much (with the exception of their personal safety) are those who are in favor of and working for the government.
Having inside work can get you food, a good salary (but not much better), and maybe you can get into any mob (Have you heard of "El cartel de los soles"?) that exists in the different organizations. They exist to get privileges like medicines.
Take note: Saying "no" is forbidden. Missing a meeting is forbidden. Thinking different is forbidden, at least out loud.
**Light at the end of the tunnel**
How can you survive such a... I don't know what to call it.
You can take my food, you can take my medicines, you can take the peace out of my house.
But there is something that you will never take from me, and this lives in the Blockchain.
I'm talking about cryptocurrencies.
Unlike local currency, cryptocurrencies don't lose their value over time, they reevaluate. This is something that is worth working for.
If I had 1000 VEF yesterday (in local currency, about $1 US dollar), then today it is enough to buy less products than yesterday. (It's true; prices change wildly from one week to the next.)
But if yesterday I had 1 BTC, today Im able to buy more stuff than yesterday. Magic.
**Something that is worth it**
And this is just BTC. Now with a twist, LBRY enters the scene. An open source library that allows me, as an artist, to share my multimedia content in exchange for cryptocurrencies.
Besides freedom of distribution, LBRY is an open source library. Knowledge must be free and accessible to everyone. That is what LBRY aims for.
**Conclusion**
I'm a semi-professional young man (I couldn't finish college for monetary reasons), of low resources (unemployed for not being a professional), with an unstable feeding (my fridge broke two years ago), hated for thinking different (crypto-what? That's a lie in the eyes of my fellow countrymen). But it is time to say enough.
I'm not afraid to express what Im telling you here. What else could they take from me? Can you call this a life?
My life from now on (and always should) contributes to the open source community (secrets in my eyes are tyranny) and developing cryptocurrency platforms, because they can't take those from me. Like LBC a coin that not only will allow me earn the foods I need to survive, but also will help me express myself better to this world and at the same time make it a better place.
Thanks LBRY team.
Javier
July 2016

View file

@ -14,11 +14,13 @@ class View
{
const LAYOUT_PARAMS = '_layout_params';
protected static $metaDescription = '',
$metaImg = '';
public static function render($template, array $vars = [])
{
if (static::isMarkdown($template))
{
return static::markdownToHtml(static::getFullPath($template));
}
if (!static::exists($template) || substr_count($template, '/') !== 1)
{
throw new InvalidArgumentException(sprintf('The template "%s" does not exist or is unreadable.', $template));
@ -35,6 +37,11 @@ class View
$vars = $actionClass::$method($vars);
}
if ($vars === null)
{
return;
}
extract($vars);
ob_start();
ob_implicit_flush(0);
@ -54,13 +61,32 @@ class View
return static::interpolateTokens(ob_get_clean());
}
public static function markdownToHtml($path)
{
return ParsedownExtra::instance()->text(trim(file_get_contents($path)));
}
public static function exists($template)
{
return is_readable(static::getFullPath($template));
}
protected static function isMarkdown($nameOrPath)
{
return strlen($nameOrPath) > 3 && substr($nameOrPath, -3) == '.md';
}
protected static function getFullPath($template)
{
if ($template && $template[0] == '/')
{
return $template;
}
if (static::isMarkdown($template))
{
return ROOT_DIR . '/posts/' . $template;
}
return ROOT_DIR . '/view/template/' . $template . '.php';
}
@ -69,24 +95,13 @@ class View
return '/img/' . $image;
}
public static function setMetaDescription($description)
public static function parseMarkdown($template)
{
static::$metaDescription = $description;
}
public static function setMetaImage($url)
{
static::$metaImg = $url;
}
public static function getMetaDescription()
{
return static::$metaDescription ?: 'A Content Revolution';
}
public static function getMetaImage()
{
return static::$metaImg ?: '//lbry.io/img/lbry-dark-1600x528.png';
$path = static::getFullPath($template);
list($ignored, $frontMatter, $markdown) = explode('---', file_get_contents($path), 3);
$metadata = Spyc::YAMLLoadString(trim($frontMatter));
$html = ParsedownExtra::instance()->text(trim($markdown));
return [$metadata, $html];
}
public static function compileCss()

View file

@ -1,13 +1,18 @@
<?php Response::setMetaDescription('description.faq') ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<?php Response::setMetaDescription(__('description.faq')) ?>
<?php NavActions::setNavUri('/learn') ?>
<?php echo View::render('nav/_header', ['isDark' => false]) ?>
<main>
<section class="content content-readable spacer2">
<h1>{{page.faq.header}}</h1>
<?php foreach($postGroups as $group => $posts): ?>
<h2><?php echo $groupNames[$group] ?></h2>
<?php foreach($posts as $post): ?>
<div class="spacer1">
<a href="<?php echo $post->getRelativeUrl() ?>" class="link-primary"><?php echo $post->getTitle() ?></a>
</div>
<?php endforeach ?>
</section>>
<?php endforeach ?>
</section>
</main>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>

View file

@ -1,5 +1,5 @@
<?php Response::setMetaDescription('description.news') ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<?php Response::setMetaDescription(__('description.news')) ?>
<?php echo View::render('nav/_header', ['isDark' => false]) ?>
<main>
<div class="hero hero-quote hero-img spacer2" style="background-image: url(/img/cover-team.jpg)">
<div class="hero-content-wrapper">
@ -19,6 +19,6 @@
</div>
</div>
<?php endforeach ?>
</section>>
</section>
</main>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>

View file

@ -1,26 +1,28 @@
<?php Response::setMetaDescription(__('Download/install the latest version of LBRY for %os%.', ['%os%' => $osTitle])) ?>
<?php Response::setMetaDescription(__('description.get')) ?>
<?php NavActions::setNavUri('/get') ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<?php echo View::render('nav/_header', ['isDark' => false]) ?>
<main class="column-fluid">
<div class="span7">
<div class="cover cover-dark cover-dark-grad content content-stretch content-dark">
<h1><?php echo strtr(__('download.main.title'), ['%os%' => $osTitle]) ?> <span class="<?php echo $osIcon ?>"></span></h1>
<?php if ($downloadHtml): ?>
<?php echo View::render('download/_betaNotice') ?>
<?php echo $downloadHtml ?>
<?php echo View::render('download/_reward') ?>
<h1>{{download.main.title}}</h1>
<?php if (Session::get(Session::KEY_DOWNLOAD_ACCESS_ERROR)): ?>
<div class="notice notice-error spacer1"><?php echo Session::get(Session::KEY_DOWNLOAD_ACCESS_ERROR) ?></div>
<?php Session::unsetKey(Session::KEY_DOWNLOAD_ACCESS_ERROR) ?>
<?php endif ?>
<?php if (Session::get(Session::KEY_PREFINERY_USER_ID)): ?>
<?php echo View::render('download/_refer') ?>
<?php else: ?>
<?php echo View::render('download/_unavailable') ?>
<p>{{download.main.signup}}</p>
<?php echo View::render('download/_signup') ?>
<?php endif ?>
</div>
</div>
<div class="span5">
<?php echo View::render('download/_list', [
'excludeOs' => $os
]) ?>
<?php echo View::render('download/_social') ?>
<?php echo View::render('download/_publish') ?>
</div>
</main>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>

View file

@ -1,21 +0,0 @@
<?php Response::setMetaDescription('Download or install the latest version of LBRY.') ?>
<?php Response::setMetaTitle(__('Get LBRY')) ?>
<main class="cover-stretch-wrap">
<div class="cover cover-stretch cover-dark cover-dark-grad">
<div class="content content-dark">
<div class="spacer2">
<a href="/"><img src="/img/lbry-white-485x160.png" alt="Fund LBRY"/></a>
</div>
<div class="cover cover-light cover-light-alt-grad">
<div class="content content-light">
<h1>Thank You!!!</h1>
<p>OMG thanks for paying.</p>
<p>Here is a unique URL that you can use to refer others. You get 10% bonus credits for anyone who uses it.</p>
<h3><a class="link-primary" href="https://lbry.io/i/butts">https://lbry.io/i/butts</a></h3>
<p>Here are some details about how to claim them or other things you would want to know.</p>
</div>
</div>
</div>
</div>
</main>
<?php echo View::render('nav/footer') ?>

View file

@ -1,42 +0,0 @@
<?php Response::setMetaTitle(__('LBRY Fund Goals')) ?>
<?php Response::setMetaDescription('Download or install the latest version of LBRY.') ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<main>
<div class="cover cover-dark cover-dark-grad">
<div class="content content-dark">
<?php echo View::render('fund/header') ?>
<h2><?php echo __('Active Goal') ?></h2>
<?php echo View::render('fund/currentGoal') ?>
<h1><?php echo __('All Goals') ?></h1>
<?php ob_start() ?>
<p>Core development continues through 2016.</p>
<?php $coreDevRewardHtml = ob_get_clean() ?>
<?php ob_start() ?>
<p>Android and iPhone so cool.</p>
<?php $appRewardHtml = ob_get_clean() ?>
</div>
<div class="content content-light">
<div class="sale-levels spacer2">
<?php foreach([[
'name' => 'Core Development Continues',
'amount' => 25000,
'rewardHtml' => $coreDevRewardHtml
], [
'name' => 'Android and iPhone Apps',
'amount' => 50000,
'rewardHtml' => $appRewardHtml
]] as $goal): ?>
<div class="sale-level">
<h4 class="sale-level-label"><?php echo $goal['name'] ?></h4>
<div class="sale-level-cost"><?php echo i18n::formatCurrency($goal['amount']) ?></div>
<div class="row-fluid clear">
<h6 class="sale-level-reward-title"><?php echo __('Reward') ?></h6>
<div class="sale-level-reward"><?php echo $goal['rewardHtml'] ?></div>
</div>
</div>
<?php endforeach ?>
</div>
</div>
</div>
</main>
<?php echo View::render('nav/footer') ?>

View file

@ -0,0 +1,33 @@
<?php $error = isset($error) ? $error : null ?>
<form action="/list-subscribe" method="post" novalidate>
<?php if ($error): ?>
<div class="notice notice-error spacer1"><?php echo $error ?></div>
<?php elseif ($success): ?>
<?php js_start() ?>
ga('send', 'event', 'Sign Up', 'Join List', '<?php echo $listId ?>');
twttr.conversion.trackPid('nty1x');
fbq('track', '<?php echo $fbEvent ?>');
<?php js_end() ?>
<div class="notice notice-success spacer1"><?php echo $success ?></div>
<?php endif ?>
<?php if ($error || !$success): ?>
<div class="mail-submit">
<input type="hidden" name="returnUrl" value="<?php echo $returnUrl ?>"/>
<input type="hidden" name="listId" value="<?php echo $listId ?>"/>
<input type="hidden" name="listSig" value="<?php echo $listSig ?>"/>
<input type="email" value="" name="email" class="required email standard" placeholder="someone@somewhere.com">
<input type="submit" value="<?php echo isset($submitLabel) ? $submitLabel : 'Subscribe' ?>" name="subscribe" id="mc-embedded-subscribe" class="<?php echo $btnClass ?>">
<?php if (isset($fbEvent)): ?>
<input type="hidden" name="fbEvent" value="<?php echo $fbEvent ?>" />
<?php endif ?>
<?php if (isset($mergeFields)): ?>
<input type="hidden" name="mergeFields" value="<?php echo htmlentities(serialize($mergeFields)) ?>" />
<?php endif ?>
<?php if (isset($meta) && $meta): ?>
<div class="meta">
{{email.disclaimer}}
</div>
<?php endif ?>
</div>
<?php endif ?>
</form>

View file

@ -0,0 +1,73 @@
<div class="bg-image-full" style="background-image: url(/img/cover-home2.jpg)"></div>
<?php Response::setMetaTitle(__('title.home')) ?>
<?php Response::setMetaDescription(__('description.home')) ?>
<?php echo View::render('nav/_header', ['isDark' => true]) ?>
<main class="column-fluid">
<div class="span12">
<div class="cover cover-dark">
<div class="content content-wide content-dark">
<div class="text-center">
<h1 class="cover-title">{{global.tagline}}</h1>
<h2 class="cover-subtitle" style="max-width: 600px; margin-left: auto; margin-right: auto">{{global.sentence}}</h2>
</div>
<?php /*
<?php $labels = [
__('making history'),
__('empowering artists'),
__('spreading knowledge'),
__('sharing sustainably'),
__('protecting speech'),
__('building tomorrow'),
__('eliminating middlemen'),
__('furthering education'),
] ?>
<?php shuffle($labels) ?>
<div class="sale-call ">
<span class="sale-call-verb"><?php echo __('Join') ?></span>
<span class="sale-call-total-people"><?php echo number_format($totalPeople) ?></span>
<span class="sale-call-prep">others in</span>
<span class="sale-ctas label-cycle" data-cycle-interval="5000">
<span class="sale-cta"><?php echo implode('</span><span class="sale-cta">', $labels) ?></span>
</span>
</div>
*/ ?>
<div class="control-group spacer2 text-center">
<div class="control-item">
<a href="/get" class="btn-primary">{{page.home.primary_button}}</a>
</div>
<div class="control-item">
<a href="/learn" class="btn-alt">{{page.home.learn_button}}</a>
</div>
</div>
<div class="video" style="margin-bottom: 80px">
<iframe width="560" height="315" src="https://www.youtube.com/embed/DjouYBEkQPY" frameborder="0" allowfullscreen></iframe>
</div>
</div>
<div class="content content-dark">
<div class="row-fluid">
<div class="span4">
<h3><?php echo __('Get Updates') ?></h3>
<?php echo View::render('mail/_joinList', [
'submitLabel' => 'Go',
'listId' => Mailchimp::LIST_GENERAL_ID,
'mergeFields' => ['CLI' => 'No'],
'meta' => true,
'returnUrl' => '/',
'btnClass' => 'btn-alt'
]) ?>
</div>
<div class="span4 text-center">
<div class="fb-page" data-href="https://www.facebook.com/lbryio" data-height="300" data-small-header="false" data-width="300"
data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="true" data-show-posts="true">
<div class="fb-xfbml-parse-ignore"><blockquote cite="https://www.facebook.com/lbryio"><a href="https://www.facebook.com/lbryio">LBRY</a></blockquote></div>
</div>
</div>
<div class="span4 text-center">
<a width="300" class="twitter-timeline" href="https://twitter.com/LBRYio" data-widget-id="671104143034073088">{{social.tweets}}</a>
</div>
</div>
</div>
</div>
</div>
</main>

View file

@ -1,42 +1,64 @@
<?php Response::setMetaDescription(__('Learn more about LBRY, the technology that puts you back in control of the internet.')) ?>
<?php Response::setMetaTitle(__('Learn About LBRY')) ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<?php Response::setMetaDescription(__('description.learn')) ?>
<?php Response::setMetaTitle(__('title.learn')) ?>
<?php echo View::render('nav/_header', ['isDark' => false]) ?>
<main class="column-fluid ">
<div class="span6">
<div class="cover cover-light content">
<h1 style="max-width: 660px; margin-left: auto; margin-right: auto">LBRY in 60 Seconds</h1>
<div class="cover cover-dark cover-dark-grad">
<div class="content content-dark content-tile">
<h1 class="cover-title cover-title-tile">LBRY in 100 Seconds</h1>
<?php echo View::render('download/_videoIntro') ?>
</div>
</div>
</div>
<div class="span6">
<div class="cover cover-dark cover-center content content-dark" style="background-image:url(/img/altamira-bison.jpg)">
<h2 class="cover-title cover-title-tile">Art in the Internet Age</h2>
<p class="cover-subtitle text-center">Learn how LBRY will forever improve how<br/>we create and share with one another.</p>
<p class="cover-subtitle text-center" style="max-width: 660px">Learn how LBRY will forever improve how we create and share with one another.</p>
<a href="/what" class="btn-alt"><?php echo __('Read the Essay') ?></a>
</div>
</div>
<div class="span6">
<div class="cover cover-dark cover-dark-grad">
<div class="content content-dark content-tile">
<h3><?php echo __('Who Makes LBRY?') ?></h3>
<p><?php echo __('Learn more about the relentless rebels changing the internet.') ?></p>
<div class="spacer1">
<a href="/team" class="btn-alt"><?php echo __('About The Team') ?></a>
</div>
<h4>Talk With Us</h4>
<?php echo View::render('social/_list') ?>
</div>
</div>
</div>
<div class="span6">
<div class="cover cover-light-alt cover-light-alt-grad">
<div class=" content content-light content-tile">
<h3>Nerd With Us</h3>
<p>LBRY is a completely open source protocol that provides a decentralized digital marketplace.</p>
<div class="row-fluid">
<div class="span6">
<h3>Explore</h3>
<div class="spacer1">
<a href="/faq" class="link-primary">Frequently Asked Questions</a>
</div>
<div class="spacer1">
<a href="http://explorer.lbry.io" class="link-primary">Block Explorer</a>
</div>
<div class="spacer1">
<a href="https://bittrex.com/Market/Index?MarketName=BTC-LBC" class="link-primary">Bittrex Exchange</a>
</div>
</div>
<div class="span6">
<h3>Nerd Out</h3>
<p>LBRY is 100% open source in the <a class="link-primary" href="https://en.wikipedia.org/wiki/The_Cathedral_and_the_Bazaar">Bazaar tradition</a>.</p>
<?php echo View::render('social/_listDev') ?>
</div>
</div>
</div>
</div>
</div>
<div class="span6">
<div class="cover cover-light">
<div class="content content-light content-tile">
<div class="row-fluid">
<div class="span6">
<h3><?php echo __('The Team') ?></h3>
<p><?php echo __('Learn more about the relentless rebels changing the internet.') ?></p>
<a href="/team" class="btn-alt"><?php echo __('About The Team') ?></a>
</div>
<div class="span6">
<h3>Join Us</h3>
<?php echo View::render('social/_list') ?>
</div>
</div>
</div>
</div>
</div>
</main>
<?php /*
<main class="column-fluid">
@ -98,4 +120,4 @@
</div>
</div>
</main> */ ?>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>

View file

@ -0,0 +1,112 @@
<?php NavActions::setNavUri('/get') ?>
<?php Response::setMetaDescription('description.publish') ?>
<?php Response::setMetaTitle(__('title.publish')) ?>
<?php echo View::render('nav/_header', ['isDark' => true, 'isAbsolute' => true]) ?>
<main >
<?php //if you change the image, change it on download/_publish too! ?>
<div class="cover cover-dark cover-center cover-full" style="background-image:url(/img/cover-home3.jpg)">
<h1 class="cover-title" id="art">Publish on LBRY</h1>
<div class="cover-subtitle" style="max-width: 580px; text-align: center">
<strong>Earn $1,000 and join the next content epoch: the viewer and you, with nobody in between.</strong>
</div>
<a href="#learn-more" class="btn-alt">Keep Reading</a>
</div>
<div class="column-fluid" id="learn-more">
<div class="span6">
<div class="cover cover-light">
<div class="content content-light content-tile">
<h2 class="cover-title cover-title-tile cover-title-flat">Publishing Partnership</h2>
<h3>How It Works</h3>
<ul>
<li>
Publish five pieces of content with the LBRY app.
<div class="meta">Existing content is okay, so long as it's content you created.</div>
</li>
<li>Set any price per view from zero to a dime to one million dollars youre in control.</li>
<li>Receive 100% of your list price in real time as it is streamed.</li>
<li>
Receive approximately $1,000.<br/>
<div class="meta">See <a href="#what-you-get" class="link-primary">What You Get</a>.</div>
</li>
<li>Answer our beta feedback survey about your experience.</li>
</ul>
</div>
</div>
</div>
<div class="span6">
<div class="cover cover-dark cover-dark-grad">
<div class="content content-dark content-tile">
<h3 class="cover-title cover-title-tile">What is LBRY?</h3>
<p>Watch "LBRY in 100 Seconds", an introduction to the wonderful technology of LBRY.</p>
<?php echo View::render('download/_videoIntro') ?>
</div>
</div>
</div>
</div>
<div class="hero hero-quote hero-img" style="background-image: url(/img/cover-jcole.jpg)">
<div class="hero-content-wrapper">
<div class="hero-content" style="max-width: 540px">
<blockquote>
<p>You was inspired by the world; allow the world to be inspired by [you]</p>
</blockquote>
<cite>J. Cole, <em><a href="https://www.youtube.com/watch?v=UMCGOAGb4Y0&amp;t=496s">Note to Self</a></em></cite>
</div>
</div>
</div>
<div class="column-fluid" id="how-it-works">
<div class="span6">
<div class="cover cover-dark cover-dark-grad">
<div class="content content-dark content-tile">
<h3 class="cover-title cover-title-tile cover-title-flat">Why LBRY?</h3>
<h4>More, Better Profit</h4>
<p>Any price you charge for content settles near-instantly into an account only you control. You receive 100% of the price. Micro-payments (and free content) supported.</p>
<h4>Open, Trustworthy Technology</h4>
<p>
LBRY uses the ground-breaking innovation of the blockchain to leave no one in control of your content except for you (including us!).</p>
<p>
LBRY is an open-source protocol that is controlled by it's users: we could not change the rules even if wanted to.
</p>
<h4>Complete Creator Control</h4>
<p>Update your content at any time. Change the price. Change the title. Publish, unpublish. You and only you can do this in LBRY.</p>
</li>
</ul>
</div>
</div>
</div>
<div class="span6">
<div class="cover cover-light-alt cover-light-alt-grad">
<div class="content content-light content-tile">
<h3 class="cover-title cover-title-tile cover-title-flat" id="what-you-get" >What You Get</h3>
<ul>
<li>Premier Partner status. Receive insider access and support for life.</li>
<li>Content featured on the LBRY landing screen seen by all users, as well as on our blog, social media, and 100,000 person email list, including links to your YouTube or other profiles.</li>
<li>
Receive $1,000 worth of LBRY credits to hold, use or sell.
<div class="meta">
We make no guarantee of the value of a credit, but credits are actively traded. Current credit price can be seen
<a class="link-primary" href="https://bittrex.com/Market/Index?MarketName=BTC-LBC">here</a> or <a class="link-primary" href="https://poloniex.com/exchange#btc_lbc">here</a>.
</div>
</li>
<li>We hold your hand every step of the way while taking none of your revenue.</li>
</ul>
<h3 class="cover-title cover-title-tile cover-title-flat">What You Give</h3>
<ul>
<li>Upload five videos via the LBRY interface (well help you out).</li>
<li>A single social media mention about your availability on LBRY.</li>
<li>Allowance for us to promote availability of your content.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="content content-readable">
<h3>Get In Now</h3>
<iframe id="feedback-form-iframe" src="https://docs.google.com/forms/d/17yrFsY1W86N9hfNt1batFbySY-1z-tq0wDjFjXKjgp8/viewform?embedded=true"
width="760" height="1000" frameborder="0" marginheight="0" marginwidth="0">Loading...</iframe>
<h3>Questions?</h3>
<p>Email <a class="link-primary" href=mailto:reilly@lbry.io?subject=Publishing Program">Reilly Smith</a> with questions or to schedule a call.</p>
<?php echo View::render('content/_bio', ['person' => 'reilly-smith', 'orientation' => 'horizontal']) ?>
</div>
<?php echo View::render('nav/_learnFooter', ['isDark' => true]) ?>
</main>
<?php echo View::render('nav/_footer') ?>

View file

@ -1,139 +1,30 @@
<?php NavActions::setNavUri('/learn') ?>
<?php Response::setMetaImage('https://lbry.io/img/cover-team.jpg') ?>
<?php Response::setMetaDescription('description.team') ?>
<?php echo View::render('nav/header', ['isDark' => false]) ?>
<?php Response::addMetaImage('https://lbry.io/img/cover-team.jpg') ?>
<?php Response::setMetaDescription('LBRY is founded by a team passionate about connecting producers and consumers and breaking down broken models. Learn more about them.') ?>
<?php echo View::render('nav/_header', ['isDark' => false]) ?>
<main>
<div class="content photo-grid spacer2">
<h1>{{page.team.header}}</h1>
<p>{{page.team.people}}</p>
<h1>The Team</h1>
<p>LBRY is made possible by more people than we could ever list here. The founding team is listed below.</p>
<?php foreach([
['jeremy-kauffman', 'michael-zargham'],
['josh-finer', 'alex-grintsvayg'],
['mike-vine', 'jimmy-kiselak', 'jack-robison'],
['job-evers-meltzer', 'reilly-smith', 'alex-liebowitz']
] as $bioRow): ?>
<div class="row-fluid">
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/jeremy-644x450.jpg" alt="Jeremy Kauffman"/>
</div>
<div>
<h4>Jeremy Kauffman <a href="mailto:jeremy@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.jeremy.title}}</div>
<p>
{{page.team.jeremy.parag1}}
</p>
<p>
{{page.team.jeremy.parag2}}
</p>
<p>
{{page.team.jeremy.parag3}}
</p>
</div>
</div>
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/zargham-644x450.jpg" alt="Michael Zargham"/>
</div>
<div>
<h4>Michael Zargham <a href="mailto:zargham@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.zargham.title}}</div>
<p>
{{page.team.zargham.parag1}}
</p>
<p>
{{page.team.zargham.parag2}}
</p>
</div>
<?php foreach($bioRow as $bioSlug): ?>
<div class="<?php echo count($bioRow) == 2 ? 'span6' : 'span4' ?> spacer2">
<?php echo View::render('content/_bio', ['person' => $bioSlug]) ?>
</div>
<?php endforeach ?>
</div>
<?php endforeach ?>
<div class="row-fluid">
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/josh-644x450.jpg" alt="Josh Finer"/>
</div>
<div>
<h4>Josh Finer <a href="mailto:josh@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.josh.title}}</div>
<p>
{{page.team.josh.parag1}}
<p>
{{page.team.josh.parag2}}
</p>
</div>
</div>
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/jimmy-644x450.jpg" alt="Jimmy Kiselak"/>
</div>
<div>
<h4>
Jimmy Kiselak
<a href="mailto:jimmy@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a>
</h4>
<div class="meta spacer1">{{page.team.jimmy.title}}</div>
<p>
{{page.team.jimmy.parag1}}
</p>
<p>
{{page.team.jimmy.parag2}}
</p>
<p>
{{page.team.jimmy.parag3}}
</p>
</div>
</div>
</div>
<div class="row-fluid">
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/mike-644x450.jpg" alt="Mike Vine"/>
</div>
<div>
<h4>Mike Vine <a href="mailto:mike@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.mike.title}}</div>
<p>
{{page.team.mike.parag1}}
</p>
<p>
{{page.team.mike.parag2}}
</p>
</div>
</div>
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/grin-644x450.jpg" alt="Alex Grin"/>
</div>
<div>
<h4>Alex Grin <a href="mailto:grin@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.grin.title}}</div>
<p>
{{page.team.grin.parag1}}
</p>
<p>
{{page.team.grin.parag2}}
<p>
{{page.team.grin.parag3}}
</p>
</div>
</div>
</div>
<div class="row-fluid">
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/jack-robison-644x450.jpg" alt="Jack Robison"/>
</div>
<div>
<h4>Jack Robison <a href="mailto:jack@lbry.io" class="link-primary"><span class="icon icon-envelope"></span></a></h4>
<div class="meta spacer1">{{page.team.jack.title}}</div>
<p>
{{page.team.jack.parag1}}
</p>
<p>
{{page.team.jack.parag2}}
<p>
{{page.team.jack.parag3}}
</p>
</div>
</div>
<div class="span3"></div>
<div class="span6">
<div class="photo-container">
<img src="/img/spooner-644x450.jpg" alt="you!"/>
<img src="/img/team/spooner-644x450.jpg" alt="you!"/>
</div>
<div>
<h4>{{page.team.you.header}}</h4>
@ -147,66 +38,18 @@
<h2>{{page.team.advisory}}</h2>
<div class="row-fluid">
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/alex-tabarrok-644x450.jpg" alt="Alex Tabarrok"/>
</div>
<div>
<h4>Alex Tabarrok</h4>
<div class="meta spacer1">{{page.team.alex.title}}</div>
<p>{{page.team.alex.parag1}}
</p>
<p>{{page.team.alex.parag2}}
</p>
<p>{{page.team.alex.parag3}}
</p>
</div>
<?php echo View::render('content/_bio', ['person' => 'alex-tabarrok']) ?>
</div>
<div class="span6 spacer2">
<div class="photo-container">
<img src="/img/stephan-644x450.jpg" alt="Stephan Kinsella"/>
</div>
<div>
<h4>Stephan Kinsella</h4>
<div class="meta spacer1">{{page.team.stephan.title}}</div>
<p>
{{page.team.stephan.parag1}}
</p>
<p>
{{page.team.stephan.parag2}}
</p>
</div>
<?php echo View::render('content/_bio', ['person' => 'stephan-kinsella']) ?>
</div>
</div>
<div class="row-fluid">
<div class="span6">
<div class="photo-container">
<img src="/img/huemer-644x450.jpg" alt="Michael Huemer"/>
</div>
<div>
<h4>Michael Huemer</h4>
<div class="meta spacer1">{{page.team.michael.title}}</div>
<p>
{{page.team.michael.parag1}}
</p>
<p>
{{page.team.michael.parag2}}
</p>
</div>
</div>
<div class="span6">
<div class="photo-container">
<img src="/img/spooner-644x450.jpg" alt="you!"/>
</div>
<div>
<h4>{{page.team.you.header}}</h4>
<div class="meta spacer1">{{page.team.you.advheader}}</div>
<p>
{{page.team.you.advtext}}
</p>
<?php echo View::render('content/_bio', ['person' => 'michael-huemer']) ?>
</div>
</div>
</div>
</div>
<?php echo View::render('nav/learnFooter') ?>
<?php echo View::render('nav/_learnFooter') ?>
</main>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>

View file

@ -1,6 +1,7 @@
<?php Response::setMetaDescription('description.what') ?>
<?php Response::setMetaDescription(__('description.what')) ?>
<?php Response::setMetaTitle(__('title.what')) ?>
<?php NavActions::setNavUri('/learn') ?>
<?php echo View::render('nav/header', ['isDark' => true, 'isAbsolute' => true]) ?>
<?php echo View::render('nav/_header', ['isDark' => true, 'isAbsolute' => true]) ?>
<main>
<div class="cover cover-dark cover-center cover-full" style="background-image:url(/img/altamira-bison.jpg)">
<h1 class="cover-title" id="art">Art in the Internet Age</h1>
@ -50,7 +51,7 @@
<li><strong>Domain names are controlled via ongoing auction</strong>. This facilitates names being controlled by the publishers that value them most. These transactions take place via an electronic currency called LBRY credits, or <em>LBC</em>. This is covered in more detail, below.</li>
</ol>
<p>While creating a protocol that we ourselves cannot control sounds chaotic, it is actually about establishing trust. Every other publishing system requires trusting an intermediary that can unilaterally change the rules on you. What happens when you build your business on YouTube or Amazon and they change fees? Or Apple drops your content because the Premier of China thought your comedy went to far?</p>
<p>While creating a protocol that we ourselves cannot control sounds chaotic, it is actually about establishing trust. Every other publishing system requires trusting an intermediary that can unilaterally change the rules on you. What happens when you build your business on YouTube or Amazon and they change fees? Or Apple drops your content because the Premier of China thought your comedy went too far?</p>
<p>Only LBRY consists of a known, promised set of rules that no one can unilaterally change. LBRY provides this by doing something unique: leaving the <em>users</em> in control rather than demanding that control for itself.</p>
<footer id="note-decentralized"><sup>2</sup>If it worries you that LBRY's decentralized nature facilitates infringing or unsavory content, this is addressed in <a class="link-primary" Cohref="#combatting-the-ugly">Combatting the Ugly</a>.</footer>
@ -74,7 +75,7 @@
The data and technology that makes the entire interaction possible is not reliant on nor controlled by any single entity.</p>
</section>
<section>
<h2>The LBRY Network</h2>
<h2 id="the-network">The LBRY Network</h2>
<p>To understand precisely what LBRY is and why it matters, one must understand both LBRY as a protocol and the services the protocol enables. HTTP is the protocol that makes web browsing possible, but it would be of little interest without the service of a web browser!</p>
<p>To understand LBRY, think of LBRY in terms of two layers: <em>protocol</em> and <em>service.</em> The protocol provides a fundamental, underlying technological capability. The service layer utilizes the protocol to do something that a human being would actually find useful.</p>
@ -169,20 +170,20 @@
<p>Essentially, rather than issue a transaction to the core blockchain, transactions are issued to a 3rd-party provider. These providers have a substantial number of coins which are used to maintain balances internally and settle a smaller number of transactions to the core chain. In exchange, these providers earn a small fee, less than the fee required to issue the transaction directly to the blockchain.</p>
</section>
<section>
<h2>LBRY Credits</h2>
<h2 id="credits">LBRY Credits</h2>
<p>LBRY Credits, or <em>LBC</em>, are the unit of account for LBRY. Eventually 1,000,000,000 LBC will exist, according to a defined schedule over 20 years. The schedule decays exponentially, with around 100,000,000 in the first year.</p>
<p>Additionally, some credits are awarded on a fixed basis. The total break down looks like this:</p>
<ul>
<li>10% for organizations, charities, and other strategic partners. Organizations the EFF, ACLU, and others that have fought for digital rights and the security and freedom of the internet.</li>
<li>10% for organizations, charities, and other strategic partners. Organizations like the EFF, ACLU, and others that have fought for digital rights and the security and freedom of the internet.</li>
<li>20% for adoption programs. Well be giving out lots of bonus credits, especially in the early days of LBRY, in order to encourage participation. We will also look to award credits broadly, ensuring the marketplace is egalitarian.</li>
<li>10% for us. For operational costs as well as profit.</li>
<li>60% earned by LBRY users, via mining the LBRY cryptocurrency.</li>
</ul>
</section>
<section>
<h2>More on Naming</h2>
<h2 id="naming">More on Naming</h2>
<p>LBRY names are one of the most unique aspects of LBRY and one that we believe will play a big role in helping it succeed.</p>
<p>Control of a LBRY name is awarded via a <em>continuous running auction </em>in LBC. Bids are entered into a <em>trustless escrow</em>, marking the credits as unspendable, but leaving them intact. When a user looks up a name, the name resolves to the largest bid made by a party or parties. The ability for any number of people to have a say in where a name resolves is part of what makes LBRY a system controlled by its users. As the credits are distributed primarily among users and producers, it is community itself that has ultimate controls over the catalogue of what is available.</p>
@ -214,7 +215,7 @@
<p>And of course, lets not forget that LBRY users are still subject to the DMCA and other laws governing intellectual property. Users who publishing infringing content are still subject to penalties for doing so in exactly the same way they would be via BitTorrent. LBRY only adds to the suite of options available. This makes LBRY a strict improvement over BitTorrent with regards to illegal usages, which provides none of the mechanisms listed.</p>
</section>
<section>
<h2>Our Values</h2>
<h2 id="values">Our Values</h2>
<p>We want to be the first digital content marketplace to:</p>
<ol>
@ -231,7 +232,7 @@
</ol>
</section>
<section>
<h2>TL;DR</h2>
<h2 id="tldr">TL;DR</h2>
<p>Digital art is one of the first goods to evolve beyond scarcity. This evolution is changing the way content is discovered, publicized, paid for and delivered. Heretofore, the lack of transparency and monetization mechanisms in peer-to-peer sharing networks has largely enabled piracy. By equipping a peer-to-peer protocol with a digital currency and transparent decentralized ledger, the LBRY protocol opens the door to a new era of digital content distribution making peer-to-peer content distribution suitable for major publishing housing, self-publishers and everyone in between.</p>
<p>If LBRY succeeds, we will enter a world that is even more creative, connected, and conservatory. We will waste less and we make more. We will create a world where a teenager in Kenya and a reality star in Los Angeles use the same tool to search the same network and have access to the same results -- a world where information, knowledge, and imagination know no borders. </p>
@ -239,9 +240,9 @@
<p>Build our dream with us. Download LBRY at <a class="link-primary" href="https://lbry.io/get">lbry.io/get</a>.</p>
</section>
</div>
<?php echo View::render('nav/learnFooter') ?>
<?php echo View::render('nav/_learnFooter') ?>
</main>
<?php echo View::render('nav/footer') ?>
<?php echo View::render('nav/_footer') ?>
<?php /*
<h3>Layer 1: Protocol</h3>

0
web/css/.gitkeep Normal file → Executable file
View file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 MiB