{ "info": { "author": "Konstantinos Bairaktaris", "author_email": "kbairak@indifex.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: Utilities" ], "description": "================\nDjango-mailchimp-forms\n================\n\nDjango-mailchimp-forms is a django tool that helps with the integration of web\napplications with Mailchimp. With django-mailchimp-forms you will be able to add and\nremove user emails to a mailchimp mailing list with minimum effort.\n\nInstalling\n==========\n\nYou can install the latest version of django-mailchimp-forms running \n``pip install django-mailchimp-forms`` or ``easy_install django-mailchimp-forms``\nYou can also install the `in-development version`_ of django-mailchimp-forms with\n``pip install django-mailchimp-forms==dev`` or ``easy_install django-mailchimp-forms==dev``.\n\n.. _in-development version: http://code.indifex.com/django-mailchimp-forms/get/tip.tar.gz#egg=django-mailchimp-forms-dev\n\nFeatures\n========\n\n* utility methods that use the module chimpy to communicate with mailchimp.com\nand add/remove emails\n* form wrappers to enhance your registration form so that it contains a\n'newsletter' checkbox and registers the user's email to mailchimp.com on save()\n* views that logged-in users can navigate to register/unregister themselved\nfrom the mailing list\n\nForm enhancement\n================\n\nIn order to be able to register users with newsletter functionality using\ndjango-mailchimp-forms you have 3 options:\n\n1. The default form:\n\nThe default form contains fields for: *username*, *password*, *password\nconfirmation*, *email*, *newsletter*. (In fact it is a\ndjango.contrib.auth.forms.UserCreationForm wrapped with the django-mailchimp-forms\nform wrapper).\n\nIt is used in a view like this:\n\n::\n\n from django_mailchimp_forms.forms import ChimpyForm\n \n def register(request):\n if request.method == 'POST':\n form = ChimpyForm(request.POST)\n if form.is_valid():\n newuser = form.save()\n return HttpResponseRedirect('profile_page', user_id=newuser.id)\n else:\n form = ChimpyForm()\n return render_to_response('register.html', {'form': form})\n\n2. The form class wrapper:\n\nYou can use this if you have already defined a form for registration or if you\nare currently using a registration form from another django app\n(django-registration, django-userprofile, etc). The only requirement of the\ninitial form is that it defines a 'save' method that creates and returns the\nnewly created User instance.\n\n::\n\n from registration import RegistrationForm\n from django_mailchimp_forms.forms import chimpy_form_class_wrapper\n \n form_class = chimpy_form_class_wrapper(RegistrationForm)\n def register(request):\n if request.method == 'POST':\n form = form_class(request.POST)\n if form.is_valid():\n newuser = form.save()\n return HttpResponseRedirect('profile_page', user_id=newuser.id)\n else:\n form = form_class()\n return render_to_response('register.html', {'form': form})\n\n3. The form instance wrapper:\n\nIf you are already use a form instance you can 'enhance' it as well with\nnewsletter capabilities. Note: the wrapper function takes a second optional\n'data' argument that should be the POST dictionary in case the form is supposed\nto be bound to post data.\n\n::\n\n from registration import RegistrationForm\n from django_mailchimp_forms import chimpy_form_instance_wrapper\n \n def register(request):\n if request.method == 'POST':\n form = RegistrationForm(request.POST)\n form = chimpy_form_instance_wrapper(form, request.POST)\n if form.is_valid():\n newuser = form.save()\n return HttpResponseRedirect('profile_page', user_id=newuser.id)\n else:\n form = form_class()\n form = chimpy_form_instance_wrapper(form)\n return render_to_response('register.html', {'form': form})\n\nViews\n=====\n\nThere are 2 views, one to register a user to a mailing list and one to\nunregister. The views require HTTP POST request methods and support both AJAX\nand non-AJAX requests. In the case of an AJAX request, the view will return a\nJSON string with 'success'(boolean) and 'message'(string) attributes while in\nthe case of a non-AJAX request, the view will redirect to the path designated\nby the 'next' GET variable and an appropriate message will be added to the\nrelevant user's message set.", "description_content_type": null, "docs_url": null, "download_url": "http://code.indifex.com/django-mailchimp-forms/downloads/", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://code.indifex.com/django-mailchimp-forms/", "keywords": null, "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "django-mailchimp-forms", "package_url": "https://pypi.org/project/django-mailchimp-forms/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-mailchimp-forms/", "project_urls": { "Download": "http://code.indifex.com/django-mailchimp-forms/downloads/", "Homepage": "http://code.indifex.com/django-mailchimp-forms/" }, "release_url": "https://pypi.org/project/django-mailchimp-forms/0.2/", "requires_dist": null, "requires_python": null, "summary": "Mailchimp registration framework for Django", "version": "0.2" }, "last_serial": 790022, "releases": { "0.2": [ { "comment_text": "", "digests": { "md5": "6fd3bc2bd49598618abac83bb20a9fb0", "sha256": "e3e2f85914d8447b6480bbd0dc188966571d0238130786710f6ee24109291d1b" }, "downloads": -1, "filename": "django_mailchimp_forms-0.2-py2.7.egg", "has_sig": false, "md5_digest": "6fd3bc2bd49598618abac83bb20a9fb0", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 17407, "upload_time": "2010-11-29T20:21:13", "url": "https://files.pythonhosted.org/packages/59/eb/4c5d410f191a8602e98d485345fdf3f0710d0903a2f7ab4c94eefdcecc0f/django_mailchimp_forms-0.2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "818ba2147bfc1d98f987f299c2ff9849", "sha256": "81601ea64fb847debac147432d0eaf5265e7df92cffd4913c9ef48dda85b77b8" }, "downloads": -1, "filename": "django-mailchimp-forms-0.2.tar.gz", "has_sig": false, "md5_digest": "818ba2147bfc1d98f987f299c2ff9849", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7477, "upload_time": "2010-11-29T20:21:12", "url": "https://files.pythonhosted.org/packages/e0/60/f31c909304cc3e77cb87b519493f1267fc89ee7606ac115226878cbb0cea/django-mailchimp-forms-0.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "6fd3bc2bd49598618abac83bb20a9fb0", "sha256": "e3e2f85914d8447b6480bbd0dc188966571d0238130786710f6ee24109291d1b" }, "downloads": -1, "filename": "django_mailchimp_forms-0.2-py2.7.egg", "has_sig": false, "md5_digest": "6fd3bc2bd49598618abac83bb20a9fb0", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 17407, "upload_time": "2010-11-29T20:21:13", "url": "https://files.pythonhosted.org/packages/59/eb/4c5d410f191a8602e98d485345fdf3f0710d0903a2f7ab4c94eefdcecc0f/django_mailchimp_forms-0.2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "818ba2147bfc1d98f987f299c2ff9849", "sha256": "81601ea64fb847debac147432d0eaf5265e7df92cffd4913c9ef48dda85b77b8" }, "downloads": -1, "filename": "django-mailchimp-forms-0.2.tar.gz", "has_sig": false, "md5_digest": "818ba2147bfc1d98f987f299c2ff9849", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7477, "upload_time": "2010-11-29T20:21:12", "url": "https://files.pythonhosted.org/packages/e0/60/f31c909304cc3e77cb87b519493f1267fc89ee7606ac115226878cbb0cea/django-mailchimp-forms-0.2.tar.gz" } ] }