Can a WordPress blog pull content from Django pages?
Say you have a WordPress theme you like, but want to make use of a bunch of Django code that's already 开发者_运维技巧written. Is there a good and easy, and performant way, of sucking in HTML that is output from Django and displaying it inline in a WordPress posting, or page without using browser frames? Any good examples of this?
You can do this by outputting the content in Django as usuall and then making a Wordpress plugin with code for downloading it from Django's URL
readfile("http://yourdomain/your/django/view")
But it's a really bad idea. If you just want to use the wordpress theme port it to Django. This strange PHP/Python hybrid will be a nightmare to maintain, especially if at any point you decide to add more features or make it more dynamic.
if the djanjo-code generates a rss-feed, you could use a plugin like wp-o-matic to import posts from your django website into wordpress.
精彩评论