• Integrating your SaaS app with Yammer

    Using Process.st just became even easier, thanks to our new Yammer integration. Since the general procedure for integrating with Yammer should be similar for most SaaS apps, I made a public template of the process.

    Read more

  • How to add support for posting multipart forms to the Play Scala WS library

    For Process Street's Yammer integration, I needed to post file attachments to their API using the Play Scala WS library.

    However, it turns out that WS does not yet support uploading files using multipart/form-data and POST. There are several workarounds on the 'net, but they all involve getting the underlying Ning Java client and doing thing manually.

    Why not harness the power of Play and Scala and write our own Writeable to do that job? Heck, we already have a MultipartFormData object for handling multipart form requests, why not use that?

    Read more

  • How to create an Angular directive for eonasdan's Bootstrap datetime picker

    I recently needed to add a DateTime picker to Process Street for use with our upcoming assignment feature. I ended up choosing eonasdan's DateTime picker. Here's the code to wrap it in an AngularJS directive.

    Read more

  • How to convert a PostgreSQL UUID to bytea

    I recently needed to convert a PostgreSQL UUID to bytea, and couldn't find any quick one-liners on the web. So here it is, for your enjoyment:

    Read more

  • Finding out the size of localStorage

    In the next update of Process Street we are adding more caching to our front end JavaScript client (named Front Street after the street in Toronto) in an effort to make the experience of using our app as fast as possible.

    Front Street uses web storage (specifically localStorage) to store persistent user data. To make the cache as effective as possible, it should be able to grow to use as much space as it can. However, we also store other information in localStorage, like user session information (the user's login token and list of teams, for example). That means if the cache grew to use all the localStorage space, the app couldn't function properly. Thus, we needed a way to detect the size of localStorage so we could partition localStorage between cache and session information.

    Read more

  • Forcing HTTPS in a Play 2 Scala app

    At Process Street we've been developing a new app called MailTheme that, like the Process Street app, it uses the Play Framework.

    Unlike Process Street, MailTheme will be running on Google Cloud and, for the time being, won't be behind a load balancer or proxy. As such, I needed to make all HTTP requests auto-redirect to HTTPS via Play. This turned out to be more difficult than I first imagined, as Play prior to version 2.3 has no way to detect whether or not the incoming request is over SSL.

    Read more

  • Play 2 Framework not finding environment variables in IntelliJ IDEA on Mac

    Recently I was experiencing an issue with the Play 2 Framework where it could not find environment variables on Mac OS when compiled within IntelliJ IDEA. The solution turned out to be simple, but could be inconvenient when an environment variable is used in many programs.

    Read more

  • Process Street is looking for a UI/UX Co-Founder

    We are looking for a team member to join as a co-founder for a new startup called Process Street. Process Street is building a collaborative process management system targeted at the SME market.

    We are a brand new startup, working to build our MVP. We currently have 2 of our desired 3 "Dream Team". We have our Hustler (business/marketing) and our Hacker (coding/sys-admin), we just need our Hipster (UI/UX) co-founder to help make our dream a reality.

    We are Australian and Canadian and the company is based in Delaware, USA, but we are living and working in Buenos Aires, where we plan to build out the initial product and work on doing market testing and gaining traction. If everything goes well, we plan to move to San Francisco (Silicon Valley) to scale out the business.

    Read more

  • Pajama: Client and Server Validation Simplified

    When implementing an HTML form that requires validation, a developer must make a decision: should I use client-side validation, server-side validation, or both?

    In this article I will give a quick overview of the pros and cons of these validation techniques, as well as introduce my solution to the problem: Pajama.

    Read more (2 comments)

  • Counting Syllables and Detecting Rhyme in PHP

    I was looking at a Software Developer posting on the FreshBooks careers page the other day, and near the end of the "How to apply" instructions there was a curious sentence:

    "If you want to prove you're really paying attention, include a verse of ottava rima and a link to your GitHub profile with your application and you're guaranteed to have your application reviewed by our Software Development Manager."

    I'd never heard of the ottava rima rhyming stanza form before, but a quick trip to Wikipedia remedied that. Essentially, an ottava rima stanza must satisfy three rules:

    1. Each stanza must have 8 lines,
    2. The lines must be iambic pentameter,
    3. The stanza must have the rhyming format a-b-a-b-a-b-c-c.

    Here is an example of an ottava rima stanza by Frere (as given in the Wikipedia article):

    But chiefly, when the shadowy moon had shed
    O'er woods and waters her mysterious hue,
    Their passive hearts and vacant fancies fed
    With thoughts and aspirations strange and new,
    Till their brute souls with inward working bred
    Dark hints that in the depths of instinct grew
    Subjection not from Locke's associations,
    Nor David Hartley's doctrine of vibrations.

    The simplicity of the rules got me thinking: how hard would it be to write a program to check if a poem stanza is ottava rima?

    In this article, we will write a simple ottava rima detector in PHP.

    (If you're not interested in the details, you can skip to the code at GitHub.)

    Read more (2 comments)

subscribe via RSS