Integrating Django and WordPress can be simple

Video thumbnail (Frame 0) Video thumbnail (Frame 998) Video thumbnail (Frame 1602) Video thumbnail (Frame 2224) Video thumbnail (Frame 2859) Video thumbnail (Frame 3730) Video thumbnail (Frame 4625) Video thumbnail (Frame 5411) Video thumbnail (Frame 6322) Video thumbnail (Frame 6882) Video thumbnail (Frame 8001) Video thumbnail (Frame 8589) Video thumbnail (Frame 9920) Video thumbnail (Frame 10842) Video thumbnail (Frame 13037) Video thumbnail (Frame 14157) Video thumbnail (Frame 15614) Video thumbnail (Frame 16312) Video thumbnail (Frame 18072) Video thumbnail (Frame 20984) Video thumbnail (Frame 21728) Video thumbnail (Frame 22646) Video thumbnail (Frame 23336) Video thumbnail (Frame 23999) Video thumbnail (Frame 24779) Video thumbnail (Frame 25789) Video thumbnail (Frame 26554) Video thumbnail (Frame 27351) Video thumbnail (Frame 29363) Video thumbnail (Frame 31653) Video thumbnail (Frame 40059)
Video in TIB AV-Portal: Integrating Django and WordPress can be simple

Formal Metadata

Title
Integrating Django and WordPress can be simple
Title of Series
Part Number
21
Number of Parts
44
Author
Contributors
License
CC Attribution - ShareAlike 4.0 International:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor and the work or content is shared also in adapted form only under the conditions of this license.
Identifiers
Publisher
Release Date
2014
Language
English

Content Metadata

Subject Area
Abstract
I found it surprisingly easy to do a simple integration of Django with an existing WordPress blog. I use Django to display content from WordPress’s database. I’ll explain how I integrated them and what made things easy.
Point (geometry) Slide rule Computer animation Machine code Line (geometry)
Sign (mathematics) Computer animation Gender Telecommunication Website
Point (geometry) Computer animation Website Client (computing) Window
Computer animation Hypermedia Website Local ring Product (business) Vulnerability (computing)
Programming language Computer animation Vector space Network topology Family Template (C++)
Slide rule Computer animation Gender Stress (mechanics) Basis <Mathematik> Database Machine code Template (C++)
Computer animation Blog Line (geometry) Machine code
Medical imaging Urinary bladder Computer animation Computer configuration Gender Quicksort Cartesian coordinate system
Game controller Arm Computer animation Computer configuration Gender Blog Real number Decision theory Projective plane Authorization Endliche Modelltheorie Number
Moment (mathematics) Workstation <Musikinstrument> 1 (number) Content (media) Machine code Client (computing) Computer animation Blog Website Configuration space Text editor Right angle Endliche Modelltheorie Figurate number
Medical imaging Goodness of fit Computer animation Computer configuration Decision theory Gender Videoconferencing Coma Berenices YouTube Writing
Point (geometry) Home page Building System administrator Gender Bound state Staff (military) Web browser Revision control Heegaard splitting Medical imaging Computer animation Text editor Right angle Family
Web 2.0 Computer animation System administrator Content (media) Website Database Arithmetic progression
User interface Ocean current Logical constant Building Set (mathematics) Web browser Metadata Field (computer science) Connected space Revision control Uniform resource locator Word Computer animation Different (Kate Ryan album) Hypermedia Personal digital assistant Cuboid Endliche Modelltheorie Library (computing)
Multiplication sign Sheaf (mathematics) Database Machine code Rule of inference Human migration Process (computing) Computer animation Blog Customer relationship management Website Cuboid Endliche Modelltheorie Arithmetic progression
Server (computing) Context awareness Computer file Revision control Root Network socket Touch typing File system Cuboid Information security Installation art Default (computer science) Standard deviation Computer-generated imagery Gradient Skewness Total S.A. Subject indexing Uniform resource locator Arithmetic mean Computer animation Website Free variables and bound variables Natural language Right angle
Computer animation Website Configuration space Machine code
Mobile app Gender Weight Content (media) Database Template (C++) Revision control Particle system Computer animation Blog File archiver Website Dualism
Ising-Modell Computer animation Self-organization Database Endliche Modelltheorie Line (geometry) Spacetime
Web page Key (cryptography) 1 (number) Trigonometric functions Revision control Category of being Medical imaging Computer animation Software Cuboid Quicksort Endliche Modelltheorie Object (grammar)
Medical imaging Computer animation Information Machine code Regulärer Ausdruck <Textverarbeitung>
Multiplication sign Gender System administrator Content (media) IP address Symbol table Metadata Hand fan Mathematics Computer animation Website Right angle Computer-assisted translation Address space Form (programming)
Web page Arm Content (media) Sheaf (mathematics) Representational state transfer Cartesian coordinate system 2 (number) Web 2.0 Web application Subject indexing Digital photography Mathematics Uniform resource locator Latent heat Googol Computer animation Internetworking Search engine (computing) Website Resultant
Building Presentation of a group Game controller Context awareness Direction (geometry) System administrator Multiplication sign Client (computing) Theory Synchronization Computer configuration Different (Kate Ryan album) Single-precision floating-point format Damping Endliche Modelltheorie Proxy server God Area Inheritance (object-oriented programming) Sound effect Database Maxima and minima Flow separation Word Computer animation Personal digital assistant Password Order (biology) Video game Website Natural language Freeware Table (information)
Computer animation Natural language Maxima and minima
and that the and
I think that's on mission have a lot of slides with code then go through them quickly and also recommend point of the slides if you wanna look at them later I'm a little more individuals line I but here go there's me
I can answer using
PHP in 2002 and then in 2006 I found
Django and this is actually the Wayback Machine further gender website you like and how the signs the latest release the . 9 5 but over 110
communications and we make like that so that's our about 20 winding
applying websites for clients and started in the lower window and the least agenda 1 . 6 I say at least because a major upgrade if you've been warned point 7 I know that it's and and and actually can running in semester without warnings which I'm pretty proud of so in this situation we
had a five-year-old would as site with a modified the needle built back in the day the net and modify the theme and it's not from the support on its way to quite that far on WordPress is built in PHP and we also had a Django
website for them that handle like an internal and and other problems
mixing person Django I so we can do this
but this is a robust local media act and you get like spam on your side and advertising on and if you really want us so around it will probably eventually get hacked because it's a very popular product and people find vulnerabilities and then write a bottle search websites for that and then then you go you get that automatically in the dotted I'm
talking about family and no 1 likes but the in the world that has a lot of Clements on the end of the it's not funded about things in PHP there's no pretty jego trees acts on the Digital is itself is a problem
because I don't know how to stop it there was never any intent to other programming language I have absolutely no idea how judges kept and logical step along the way so as a crater Ph.D. I'm so so listen try the don't want a vector PhD on templates are
interesting it's no fun and makes pitch templates and gender templates of someone found a way to run arbitrary PHP code in general templates why would you do that I don't know but someone wrote back and forth on the basis of this
not fun are having to on middleware databases 1 Virginia 1 for WordPress set that much fun stressful work pretty much everywhere on this next slide is really working with
a to carry on the mixing PHP python and in our Apache I talked to grand ends about this I'm and he says it actually is not as bad as you would think and yet you have a
blog post yesterday were preferred-stock explaining how to do it and was kind of funny like what I was talking to and you like world 10 lines of code in my whiskey that actually makes it a lot easier to use PHP with that whiskey as funny as that sounds so the solution is what
imaging of everything so this is what a lot of like now on and convert the bladder to gender to of this sort of thing OK what
what gender blond applications you use we got all the options which 1 do you pick on the news 1
you can also just made during the model on you have some control and it's actually kind of fun and a lot people do this it's a good like start a project a fear of interest in learning more about gender when your own blog for a while but you'll you'll learn a lot and it's like real something really can utilize Django and that means do you have a
sad OK with that seems to want to own a title fuel cell and fuel the author's work you know I the well let's if it ready to my blog model there's an unlimited number of options and decide on sometimes even harder when you're working with a client like OK when you want your book you know they can do some work to figure out the possible arm and how much of the present it can migrate
existing content by into into your blog model this is some code I wrote 4 years ago want to migrate a bunch of on data into that model that I made I'm actually we have reflected from the when the other ones are yeah and I you know the
contents of this solution just make about model in the and then you're going to get a feel that looks like this us just what rights you now is that which you can get your client if you don't climb websites like we or our Union Station configure tiny and see if it is in the arena of figure out of the configuration and install it get that this will use editor on the other hand have the documentation is really bad but it's what Drupal users on and will do just change the markdowns so down what like Markdown but you teach the client and is marked down holder and through stuff on tell out of you know make links and such the moment of the last you know here's here's another way on that not all that they could take
it could take days to figure out make those decisions on the I don't work
with images and videos of living in image good writing about post you resize it on do you know you and I'll island YouTube videos and such as nothing go into it gender so this is gender gender packages . com and that has a bunch of computing options on so you could you could that 1 of these installed and configured to make sure it works together on the user side you
know whenever you're building something you could just below the bundling features are human like of the more secure where you have a bunch of text on your home page and there's like read more you click it and then there's the rest of and did you have to make a in the and and to specify where that split is on a you colonization discuss the use of In the comments and Django all you might say I've heard someone use 1 of the of the Django admin before they're like so due other signal cuz I just wrote a bunch and I think I lost it all on there's also the provision so that if you don't actually if you do actually doing something out you can go back and get previous versions of staff in the family of each post on like on the home page you know you want like the image for the post but your post actually has a bunch of images in the content feel that you pick the right 1 and how do you make it look right on the Wikimedia browser I think there's much of gender point in they can also do that but you can install it and make it work with do we see we editor and may want like a pop up where you can browse all of the possible images and you can just come and so on and so on you could do that using Django of but I was going to
take other than the bounds on you know we require work so you got estimated out how much it's going to take that I think there's a way to keep it simple
on candidate you would use that
keep the progress in the and and so we're migrating from existing Wordpress website what if we keep WordPress as for editing content on and then use J of actually serving that content out and gender is actually the public-facing side of the web site that that in is just for a web is actually adding content on the movies keep that as the admin for adding stuff in the database and is gendered actually serve that content on the and
that's actually has a kind of using what had any experience on as using impact installed on has Odyssey revisions that has the media library it has a constant value metadata this is kind of cool words like it is you know the field it's not handled in there on will process can has this thing building in out of the box where you can add any value here can be really handy on for but as given current location of it's it's different than the family of and you you know it looks pretty good has been CSS on so this leads to the facts of the not that many about this and this then use improving the user interface and probably will continue to become like this connection lost features words like backing up in the browser does case user connection
of all the person handles the post model has aged well in 13 years so that if they came up with something you know from a set of problems with it and keep revising revising revising 28 on and at the to think about what fields I need if I can just use that on it's pretty mature and and it works I know I know it works because at least 3 people use it on so in
general I Can a time so and only when the pilots and the and tiny and already of instead fully configured I know it works on the Phillies about when decided on I and I'm sure that you want to do customization and get it have full control and get exactly how you want but on sometimes you just you actually don't care and you care more about the fine and and how it works on this region and migrate from would you start using the database and you know about much of database migration code because the models are exactly the same on and that the time for the fun and in other sections of the website I To this end of the moving fast and it works and so I can work on it we also we also in another section of the website that we actually do use Django use the and everything and I have a lot more time to work on that section the website because if you need to worry about although the individual was awake issues in the and then for the blog I was just kind of fully featured on the box and you're passing that's
PHP that he was going to ahead this so that the kids and all how these rules so you see progress running using this thing called PHP P and Fast CGI process manager on which is
of you just have to directly at the engine acts on you install it might not be into a use AC that didn't stop hp-FEM the against stole my skew well on an island through gradient genetics was pretty standard yeah gotcha server name on and in the context of the size for the rights some means allowed basically allow uploads to the Web site don't walk them you can these where there's you know and I stood to files in slashed have slashed to slash PHP on of anyone actually goes through examples and create psychopath folder in the root of the of their on file system you know that's actually just a placeholder you can put that review want people sure some people actually create a path from anywhere but trials means like a 1st check to see if there's a static file matching you it's not possible to index . php on this of pretty URLs and then finally if you do PHP file pass it over to Fast CGI Fast CGI defaults listens on this socket at least in the latest version of the bill on it just wasn't on Unix socket UNIX socket and works on you can you can configure PM if you want but it just works out of the box as it is for starters on anything I union x 1 of it's it's really good I highly recommend it when this is a scary future
whereas updates itself so the security issues of that used to run into were vessel now actually automatically install security updates when they come out like and women have right about there's a reinstall now but is a you can also get the bottom upgrade to the next major version total basically and but apparently it works I have doubts about I think pen works but you that just don't touch with France don't
stand implements the litany of problems you know if you do have to you may need to be like you have right and try not to deployments unprecedented any custom
PHP and you'll need to maintain it is the PHP hammer on so I don't think that's engaging characters of maintaining and about it and it's not fun and you have to do yet to configure whereas that's peaking configure PHP web sites that on I recommend mountain PHP code to just concerned only
would database with genders database so I I use mice to of of course you along the PostgreSQL if you want you want us again use mice skew well I'm just dumping Wordpress database in the gender database other WordPress the base uses the WP underscore conflict so soon lacking in any cable clashes and it's actually a lot easier to maintain a back of just 1 database because it's 1 website now on there is a
particle of press that you can bet your installed apps and your your hours and or actually just start handling your blog and it understands the Wordpress database and it also about your content has debased archives in such and use weighted templates on I will do that and actually decided in bill is actually advantages dualism scratched
know and you can look at the it's actually fun on that much work Ising half of you just went to the
top on inspect the on inherent a database that space and organ you know this is what I did was don't I went dumping models docking line got something kind like this but which he works I would
have to set up a foreign keys that was by the biggest thing on also figured out there's a pretty simple you can set up a simple many many 4 categories and tags on network for me on then just sort of want easily column models together can inspect the doesn't handle that quite right on the box I'm going to have a cruise
elicited simple distorted by posts as opposed to like revisions of posts were on images of or at pages are silent cosine among the ones that are published now I have post objects and you just know that out of the box to has all
assessed and about something and it's really simple on but the thing to do is we're
plastics in these crazy short codes for like saying if someone image here and there's some information about it and I wrote some really happy Mexico code to get on the and that there's ways to improve it but this is just regular expressions and splits it's totally ugly don't use it yeah but it's it's possible I'm kind of
symbol and just using metatheorem and say I want the offer you know address and to the actual content of the comment I can also add in the offer were at all we present here a few for the collecting IP address erosion so why not on it and then is just a basic model on basic 1 mole form saving and creating on and redirecting
a citizen that is beauty right on well use Python because it simply better on i can support and possible future work as the genocide that accounts for that they need them so there's like we this on they were available in Wordpress admin I don't actually have the fan and so on for that but I can support them later if needed and the change over time although that should be pretty stable recently at things the my 2 years is the metadata is changed but it's it's simple so I think the website up and running the very quickly on and actually I can't even shot off Wordpress website and the gender website is still there so we're precious and the content Django serves the content you know should only website still there and what goes down that's totally fine and I was from the ditch with press and use the Django admin I later so you know I got a got stuff up and running now and I actually were quite limited by what's going on here I can always start using will jingle for the and also good and user has so that's a little to say on what is happening soon but 1 of the cat
photo and then a couple totally random anecdotes on
1 versus application this is totally off topic but it's something I've been thinking about on the distinction between what to demonstrate a web application and Web content so content Web pages should work without JavaScript there so like that on the general don't change of person and the content usually shows up in Google search results on google indexes content arm and generally only the user you like you find something on the internet and you it on and generally things are easy to build that easy to catch a change much all the locations on the other hand are usual behind and the usually invisible the search engines and make use of that post and other HTTP verbs so like you know like a REST API there's plenty of topics in the REST API that's that means you're building a web application around JavaScript and actually you usually JavaScript heavy and using angular JS and such and specific users and things on and changing things in working with your website and it's actually a lot harder to get right then content section and my opinion is a lot of work to allow the user to edit things versus just user reading things so my kids would present the application and Genghis of the content independent oversight of 15 seconds for a really crazy idea was phone we write the
WordPress admin PHP from PHP and use Django for so like keep keep JavaScript and CSS in sync with WordPress and build like this compatibility with compatible back and that uses the WordPress API and enjoy life PHP free I'm going to work crazy idea that unexpected understand it but I in school and that's all of the banks if you are and recall used engines and he had to move out all the and so I have a client who has a WordPress site is hot from host to host just for performance reasons for you know find someone who catches differently or something I suspect using genuine genetics that becomes a non-issue that your experience on the fires caching goes down just over then insert the of the helicopter yeah you can directly if you serving Apache directly and being at some host that uses Apache on and that's going to be way faster to use a instead of properly on so really easy to set up of what I really like WordPress has ah sorry and je has proxy underscore attached to the directive and you can basically do full-page catching on whatever is coming back from Django on which I think is really cool and those lots of options of how the speed of the website and I'm I'm especially because if you if you do do it from scratch using Django you can have a lot more control what are the database queries being run and such so the idea is to actually do this with failure as a you have used gas in doing this when you have an idea yeah I just want you to go look into like combining the WordPress multi-site stuff with Jano aware that you that I have on all the time by the on the site and you know like is this something also were doing and present I will present the site is kind of is the big hack and even in the WordPress community it's like it kind works and kind of and almost 1 actually real issue is on we'll present at the site will put like a table prefix on everything on so each site will have the same blood separate database tables just with a different prefix and I think that require some of you will require some acts in order to get work working directly with Django because you can't really just duplicate models with different table names that really confuses Django on so I just tried to avoid and rather just do a separate database if I'm doing multiple the they also to have a career path indicating that an effect and I I was wondering if unseeded have probably theory using a tooth and indicate against whereas is you know of any ways you get were arrested for the consisting 1 or right so I'm yes that's 1 thing to do is like and this kind of assuming that the person can read a lot into 2 places have 2 different usernames and passwords as 1 of the downsides of I recommend I think I once we once had a case we like installed in l that back and to try to get WordPress engineer to share I using the password you what really wasn't fun a lot of work on I have a good or out of having Django use the WordPress user model as a custom user model I haven't actually tried it I bet it's theoretically possible and then you're actually using the same username and password and reusing this of there is also an idea and generates the theories repressed knowing more than me but president work runs up almost 200 different site is you were precise of a single word presence all while using multi-user the years no reliance they write everything themselves so he need functionality like in the red cells super secure is really stable and really fast and when when an update comes out that they can run it they know that'll work because there's no they know a area minimal and coterie so is doing right so yes the spirit of the times in which and and again it's always Chinese and range the 7th Bomb always missing data so I'm going to I need you that God the this not the is that so that the last thing you will receive really favor Apache is comes with these each t access in need to run was it was easy to just converted into next year and light whereas is also just like were discovering engine x WordPress also discovering and genetics and our they may have documentation of how like the perfect way to set of engine axes on I just used I can't
copy it just like the bare minimum of what you
need to set up on what President genetics and there's a couple of things you can do to tweak this and make it better but I I'm generally WordPress is like support engine x more and more and next what and that's the maximum you have a needle in the and and and and and OR so I
Feedback