Thread

Suggestions for creating "access code" form functionality?

July 31, 2017 4:45pm

Subscribe [2]
  • #1 / Jul 31, 2017 4:45pm

    xeniamedia

    10 posts

    I’m working on an ExpresssionEngine project for which the client would like to require users to enter one of a set of pre-defined access codes to view private content- either in the form of a separate page, or a modal that would appear upon entering a valid code. The actual form would literally be one input field- and would validate against a set of numerical codes (e.g. “54335”) to view private content. We’d also want to be able, in some manner, to track page views by code. I’m curious if anyone has any ideas on how to implement a feature like this either natively in EE, or with the help of an add-on. I have FreeForm Pro installed, and have contemplated some way of using a FF form to validate against the set of access codes, but not entirely sure how to proceed (ideally these codes would be defined in the backend, and not viewable in the source, say via hidden form fields.)

    Any ideas here are most appreciated.

  • #2 / Aug 01, 2017 10:29am

    Derek Jones's avatar

    Derek Jones

    7176 posts

    I don’t think there’s anything that will fit your needs out of the box, those are pretty specific requirements. But it would be a fairly simple plugin for someone to build, even with just a small amount of PHP experience. Have you considered trying to make a plugin yourself?

  • #3 / Aug 01, 2017 10:37am

    xeniamedia

    10 posts

    Thanks for your response, Derek. My PHP experience is a bit limited as I’m more front-end focused, hence my hope to perhaps rig some kind of existing form functionality with FreeForm…

ExpressionEngine News

#eecms, #events, #releases