{ "info": { "author": "Charles Leifer", "author_email": "coleifer@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python" ], "description": "Getting Started with OEmbed\n===========================\n\nInstallation\n------------\n\nFirst, you need to install OEmbed. It is available at http://github.com/worldcompany/djangoembed/\n\n::\n\n git clone git://github.com/worldcompany/djangoembed/\n cd djangoembed\n python setup.py install\n\nAdding to your Django Project\n--------------------------------\n\nAfter installing, adding OEmbed consumption to your projects is a snap. First,\nadd it to your projects' INSTALLED_APPs and run 'syncdb'::\n \n # settings.py\n INSTALLED_APPS = [\n ...\n 'oembed'\n ]\n\ndjangoembed uses a registration pattern like the admin's. In order to be\nsure all apps have been loaded, djangoembed should run autodiscover() in the\nurls.py. If you like, you can place this code right below your admin.autodiscover()\nbits::\n \n # urls.py\n import oembed\n oembed.autodiscover()\n\nConsuming Resources\n-------------------\n\nNow you're ready to start consuming OEmbed-able objects. There are a couple of\noptions depending on what you want to do. The most straightforward way to get\nup-and-running is to add it to your templates::\n\n {% load oembed_tags %}\n \n {% oembed %}blog.content{% endoembed %}\n\n {# or use the filter #}\n \n {{ blog.content|oembed }}\n \n {# maybe you're working with some dimensional constraints #}\n \n {% oembed \"600x600\" %}blog.content{% endoembed %}\n \n {{ blog.content|oembed:\"600x600\" }}\n\nYou can consume oembed objects in python as well::\n\n import oembed\n oembed.autodiscover()\n \n # just get the metadata\n resource = oembed.site.embed('http://www.youtube.com/watch?v=nda_OSWeyn8')\n resource.get_data()\n \n {u'author_name': u'botmib',\n u'author_url': u'http://www.youtube.com/user/botmib',\n u'height': 313,\n u'html': u'',\n u'provider_name': u'YouTube',\n u'provider_url': u'http://www.youtube.com/',\n u'title': u'Leprechaun in Mobile, Alabama',\n u'type': u'video',\n u'version': u'1.0',\n u'width': 384}\n \n # get the metadata and run it through a template for pretty presentation\n from oembed.consumer import OEmbedConsumer\n client = OEmbedConsumer()\n embedded = client.parse_text(\"http://www.youtube.com/watch?v=nda_OSWeyn8\")\n \n
'\n\nTroubleshooting\n---------------\n\nProblem: You try the youtube embed example, but all you get is a link to the youtube video.\n\nSolution: Djangoembed uses fixtures to load data about oembed providors like Youtube in to the database. Try fooling around with syncdb (or migrations, if you're running South) until there are objects of type oembed.storedprovider.\n\nIf you have another problem, consider looking through the more extensive docs in the project's doc subdirectory.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/worldcompany/djangoembed/tree/master", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "djangoembed", "package_url": "https://pypi.org/project/djangoembed/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/djangoembed/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/worldcompany/djangoembed/tree/master" }, "release_url": "https://pypi.org/project/djangoembed/0.1.1/", "requires_dist": null, "requires_python": null, "summary": "rich media consuming/providing for django", "version": "0.1.1" }, "last_serial": 791156, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "4caf9cf9c207fa5b6d5cd07c7919e8b2", "sha256": "b12910a79496a54d22b36ea61c20099f9dccd5a6c1592f70c449513372abe43c" }, "downloads": -1, "filename": "djangoembed-0.1.tar.gz", "has_sig": false, "md5_digest": "4caf9cf9c207fa5b6d5cd07c7919e8b2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32156, "upload_time": "2010-07-31T00:43:45", "url": "https://files.pythonhosted.org/packages/7b/a0/053e44a92d08f67114a681424233c8a64374c58672ee9add02ebdbed39a4/djangoembed-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "046b1cbe83094bd6ef05f9e90fe80568", "sha256": "e647ad841674642ddfc27ec2d5a98a76c41bd22b5adc7f07c2d7773b3bc7287c" }, "downloads": -1, "filename": "djangoembed-0.1.1.tar.gz", "has_sig": false, "md5_digest": "046b1cbe83094bd6ef05f9e90fe80568", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 114236, "upload_time": "2010-08-21T05:40:26", "url": "https://files.pythonhosted.org/packages/b8/e6/101ca966c401db8b0722a859d4e07cdfbe99c3adaddc62722577159cd250/djangoembed-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "046b1cbe83094bd6ef05f9e90fe80568", "sha256": "e647ad841674642ddfc27ec2d5a98a76c41bd22b5adc7f07c2d7773b3bc7287c" }, "downloads": -1, "filename": "djangoembed-0.1.1.tar.gz", "has_sig": false, "md5_digest": "046b1cbe83094bd6ef05f9e90fe80568", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 114236, "upload_time": "2010-08-21T05:40:26", "url": "https://files.pythonhosted.org/packages/b8/e6/101ca966c401db8b0722a859d4e07cdfbe99c3adaddc62722577159cd250/djangoembed-0.1.1.tar.gz" } ] }