Skip to content

Instantly share code, notes, and snippets.

View tchalvak's full-sized avatar
🐙
making another SPA

Roy R. tchalvak

🐙
making another SPA
View GitHub Profile
@tchalvak
tchalvak / bluejeans_rpm_via_alien.md
Last active January 19, 2018 16:45 — forked from johnduarte/bluejeans_rpm_via_alien.md
BlueJeans rpm install on Debian

FYI, for those of us not running Debian based systems rather than RedHat, the BlueJeans RPM can be successfully installed via alien

Steps to install BlueJeans on Debian

  • Download BlueJeans RPM
  • Install alien package sudo apt-get install alien
  • Convert BlueJeans RPM to a DEB package sudo alien --to-deb --scripts bluejeans-*.rpm
  • Install resulting DEB sudo dpkg -i bluejeans_*.deb
  • Run BlueJeans with /opt/bluejeans/bluejeans-bin

You may get an error loading the expected udev library

@tchalvak
tchalvak / bling.js
Created December 22, 2017 23:02 — forked from paulirish/bling.js
bling dot js
/* bling.js */
window.$ = document.querySelectorAll.bind(document);
Node.prototype.on = window.on = function (name, fn) {
this.addEventListener(name, fn);
}
NodeList.prototype.__proto__ = Array.prototype;
function series(state = {}, action) {
switch (action.type) {
case RECEIVE_SERIES_DATA:
const series = action.data.length ? action.data : [action.data]
return series.reduce((acc, series) => {
return Object.assign({}, acc, { [series.unique_key] : series })
}, state)
default:
return state
Show us how you would code a simple web chat application!
As a web developer, you've certainly used a web chat before, and maybe you have even coded one before.
Let's see if you can use these customer/client stories, and all your skills as a dev, to create a nice, simple chat app.
Here are the stories:
- As a customer, Bob want to chat on the website with other customers, so he can be part of the community.
- As a customer, Jane wants to choose a username, send some chat messages, and see her chats even after a page reload.
- As a corporate admininstrator, Greg wants the chat to get a nice initially designed template, so he can can present it as part of a corporate retreat.
@tchalvak
tchalvak / nw.sql
Created July 12, 2013 19:33 — forked from toopay/nw.sql
--
-- PostgreSQL database dump
--
SET statement_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SET check_function_bodies = false;
SET client_min_messages = warning;
@tchalvak
tchalvak / cakepi.php
Created August 6, 2012 16:01
Simple Programming task
<?php
/*
Using php, write a program that must fulfill these requirements:
For the numbers from 1 to 100,
If the number is a multiple of 3, print cake instead of the number.
If the number is a multiple of 5, print pi instead of the number.
If the number is a multiple of both 3 and 5, print cakepi instead of the number.
@tchalvak
tchalvak / templater_summary.markdown
Created July 11, 2012 12:30
Summary of PHP Webdesigner & Coder Post

PHP Webdesigner & Assistant Coder

=Please answer some of the questions below to receive any consideration of your application=

BitLucid, Inc. is looking for a part-time webdesigner & php programmer:

  • Initially, you will be taking PHP scripts containing html, css, javascript and PHP, and cleaning them up into:
    1. templates with html/javascript/css and no php logic and
  1. PHP scripts with no html in them and all the php logic
@tchalvak
tchalvak / belts_example.php
Created June 10, 2012 20:19
Example of code for the belts.php page.
<?php
require_once(CORE.'core.php') // Includes core systems, a templating engine, any mvc framework, etc.
/* ================== Intro ===========================================
Ok, so this is an example like many of our current scripts, which it should be obvious need a lot of refactoring to be more useful.
This should be split into (at least) two php scripts, one that's an html template, and one that includes all the php logic.
You can pretend that there's a template engine and/or MVC system of your choice available to use and just show me whatever kind of templating syntax
or MVC approach you're familiar with.
@tchalvak
tchalvak / odesk_profile.txt
Created June 10, 2012 19:50
Improved Odesk Profile
In a sentence, I code PHP web apps. I have coded and improved upon the browser based game NinjaWars.net ( http://ninjawars.net ) as a personal project since 2003, have been professionally freelancing building customized web applications and working with a PHP/MySQL based CMS for the last 4 years, and have been designing websites in html/css long before that. In 2011 I co-founded my corporation with my business partner and we have been building up our small business since.
For me, security is paramount. I've seen too many sites burned by bad php coding practices and under attack by sql-injection as a result. I've done a lot of security cleanup work on sites that were coded by programmers without any oversight that resulted in compromised database data and a site that -looked- fine but was full of security holes. And generally one of the first things that I do with a site is I review it's password security for the presence of strong security, that's frequently another pain point with the standard php websi
@tchalvak
tchalvak / templater.markdown
Created June 10, 2012 18:17
PHP Web Templater & Coder

PHP Web Programming Template Coder & Assistant Coder

BitLucid, Inc. is looking for a part-time php programmer to:

  • perform conversions from php scripts with a mixture of php, html, and javascript into:
  1. php templates with html/javascript/css and minimal php logic and
  2. php scripts with no html in them, but all the php logic.
  • You will also be coding web test suite cases and doing QA on upcoming code releases.

Bitlucid.com is our (work-in-progress) company website. shermanbrothers.com is our main client, and the site that you'll be working on the php scripts of. You will be taking existing scripts one by one, separating out the html from the php, making sure all variables are properly escaped, and creating two scripts (or script + template file) that result, with the goal of keeping the html output the same for the same input. You will also be reviewing changes by browsing our development site and looking for breakages. Eventually you'll write tests in php to