diff --git a/seed/labs.json b/seed/labs.json new file mode 100644 index 0000000000..5131432a29 --- /dev/null +++ b/seed/labs.json @@ -0,0 +1,30 @@ +[ + { + "camper": "johnstonbl01", + "name": "Clementine.js", + "url": "http://johnstonbl01.github.io/clementinejs/", + "description": "The elegant and lightweight boilerplate for full stack JavaScript.", + "image": "http://i.imgur.com/ib1wOho.png" + }, + { + "camper": "akiralaine", + "name": "Camper News Bot", + "url": "https://twitter.com/campernewsbot", + "description": "This twitter bot tweets out Camper News stories once they hit 5 upvotes.", + "image": "https://pbs.twimg.com/media/CLXOFLPWIAEHYPJ.png" + }, + { + "camper": "adventurebear", + "name": "Coding Bootcamp Cost Calculator", + "url": "http://www.freecodecamp.com/coding-bootcamp-cost-calculator", + "description": "This d3.js-powered coding bootcamp cost calculator takes into account tuition, financing, lost wages and cost of living.", + "image": "https://qph.is.quoracdn.net/main-qimg-670d6a0c5b01f74138e777732994240f?convert_to_webp=true" + }, + { + "camper": "ericdouglas", + "name": "Open Source Society", + "url": "https://github.com/open-source-society/computer-science", + "description": "A path to a free education in Computer Science.", + "image": "https://camo.githubusercontent.com/c42438055d3fee26b29e6d046fd8d06ebff3db20/687474703a2f2f692e696d6775722e636f6d2f6838786a72726a2e706e67" + } +] diff --git a/server/boot/randomAPIs.js b/server/boot/randomAPIs.js index bd35e05e62..c3411441ac 100644 --- a/server/boot/randomAPIs.js +++ b/server/boot/randomAPIs.js @@ -5,6 +5,8 @@ var Rx = require('rx'), request = require('request'), debug = require('debug')('freecc:cntr:resources'), constantStrings = require('../utils/constantStrings.json'), + labs = require('../../seed/labs.json'), + testimonials = require('../../seed/testimonials.json'), secrets = require('../../config/secrets'); module.exports = function(app) { @@ -32,6 +34,8 @@ module.exports = function(app) { router.get('/unsubscribed', unsubscribed); router.get('/get-started', getStarted); router.get('/submit-cat-photo', submitCatPhoto); + router.get('/labs', showLabs); + router.get('/success-stories', showSuccessStories); app.use(router); @@ -180,6 +184,20 @@ module.exports = function(app) { res.redirect('https://gitter.im/FreeCodeCamp/FreeCodeCamp'); } + function showLabs(req, res) { + res.render('resources/labs', { + title: 'Projects Built by Free Code Camp Students', + projects: labs + }); + } + + function showSuccessStories(req, res) { + res.render('resources/labs', { + title: 'Projects Built by Free Code Camp Students', + labs: testimonials + }); + } + function submitCatPhoto(req, res) { res.send('Submitted!'); } diff --git a/server/views/home.jade b/server/views/home.jade index 9b8b65fa06..e2783f4576 100644 --- a/server/views/home.jade +++ b/server/views/home.jade @@ -30,9 +30,6 @@ block content h2 As featured in img.img-center.img-responsive(src='https://s3.amazonaws.com/freecodecamp/as-seen-on.png') .spacer - h2 We're a proven way to start your software engineering career: - img.img-center.img-responsive(src='https://s3.amazonaws.com/freecodecamp/linkedin-alumni.png') - .spacer h2 Campers you'll hang out with: .row .col-xs-12.col-sm-12.col-md-4 @@ -47,6 +44,8 @@ block content img.img-responsive.testimonial-image.img-center(src="https://s3.amazonaws.com/freecodecamp/testimonial-cynthia.jpg", alt="@cynthialanel's testimonial image") .testimonial-copy I'm currently working through Free Code Camp to improve my JavaScript. The community is very welcoming! h3 - @cynthialanel + .button-spacer + .btn.btn-primary.btn-block(a href='/success-stories') See more successful campers .big-break h2 Skills you'll learn: .text-center.negative-35 diff --git a/server/views/resources/labs.jade b/server/views/resources/labs.jade new file mode 100644 index 0000000000..e3f3a41577 --- /dev/null +++ b/server/views/resources/labs.jade @@ -0,0 +1,22 @@ +extends ../layout +block content + .panel.panel-info + .panel-heading.text-center Projects Created by Free Code Camp Campers + .panel-body.text-left + .row + .col-xs-12.col-sm-10.col-sm-offset-1 + for project in projects + .spacer + .row + .col-xs-12.col-sm-3 + img.img-responsive(src=project.image) + .col-xs-12.col-sm-9.negative-15 + h3 + a(href=project.url) #{project.name} + h4 by  + a(href='/' + project.camper) #{project.camper} + p= project.description + + if !user + a.btn.btn-cta.signup-btn.btn-primary(href="/login") Start learning to code (it's free) + .spacer