Skip to main content

Patch the old Form classes in to create Bootstrap-compatible forms

Project description

# Effortless Bootstrap Web/Form Monkey Patch

Bootstrap your old web/ forms!

## Synopsis

Just because hasn't been updated since 2012 doesn't mean you have to
settle for outdated HTML layouts. Scrap that 2001-era table-based form layout,
and use this module to create shiny, new Bootstrap 4-alpha forms!

Two ways to be happy:

1. Patch the old form classes.
2. Use our backwards-compatible form classes.

Either way, *you won't have to change a bit of your program logic.* It's a
just small change at the top of the program.

## How To Patch

To update your old webforms, just import and use the `patch()` function.

from effortless_bootstrap_web_form_monkey_patch import patch

Now you can continue to use your old forms normally.

## How to Use Backwards-Compatible Classes

To use all-new but all-backwards-compatible classes, just import this package
instead of web.form.

import effortless_bootstrap_web_form_monkey_patch as form

Now you can continue to use your old forms normally.

## Remember to Update Your Templates

Oh yeah, make sure you update the templates to use Bootstrap. The most
important piece to remember is to wrap all Bootstrap items with a `.container`

<div class="container">

And of course you need the CSS. If you don't want to host it locally, use their
CDN by adding this piece to the header.

<link rel="stylesheet" href="" integrity="2hfp1SzUoho7/TsGGGDaFdsuuDL0LX2hnUp6VkX3CUQ2K4K+xjboZdsXyp4oUHZj" crossorigin="anonymous">

For more information on using Bootstrap 4-alpha, check out .

## Installation

pip install effortless_bootstrap_web_form_monkey_patch

## Inspiration

- Bootstrap 4 alpha form documentation at
- Runtime patching was learned at

## Author

Justin McGuire &mdash; <> &mdash; <a href=""></a> &mdash;

## License

MIT License

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for effortless_bootstrap_web_form_monkey_patch, version 0.2
Filename, size File type Python version Upload date Hashes
Filename, size effortless_bootstrap_web_form_monkey_patch-0.2.tar.gz (4.3 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page