Integrate existing blog code in Django-CMS?

If I already have a blog application made using Django and I want to use it with my new Django CMS website, can I just add it to my new Django CMS project as an unbundled application and map something / blog / application for a blog related to the Django CMS plugin? I guess I need to know when it is best to write my Django application as a plugin against the whole application?

thanks

Jeffc

+1
source share
1 answer

Yes, but you do not just urls.py it in urls.py , instead you can write an AppHook to link your blog URL scheme to a specific page in your CMS.

Plugins , on the other hand, are useful if you want to embed certain aspects of your application in other page placeholders - for example, to show your last 3 posts on the main page.

You might also want to include your paths in a blog or in a menu on your site - in this case you need to write a custom Menu too.

Finally, it may also be useful to use django cms placeholders in your blog model . It will allow you to publish a variety of materials through plugins.

+3
source

Source: https://habr.com/ru/post/1411384/


All Articles