Adding a CMS to Your Pyramid Web App Transcripts
Chapter: Course conclusion
Lecture: Review: problem with HTML
Login or
purchase this course
to watch this video and the rest of the course contents.
0:00
we started out thinking, Well, we have a CMS for a website.
0:04
So what we want to do is type HTML into it and then have it show it back to the users and that was all well and good. But we saw each team.
0:11
L is a little brittle and harden mostly annoying to work with. So here's the page that we hope we're going to create in our CMS After we typed it in.
0:19
This is the page we actually agree with our CMS. What's the problem? Well, there's this subtle when you don't highlight it.
0:26
Subtle unclos h to remember what we were typing into. It's not like an editor that would find the problems with HTML.
0:33
No, it's just a text area in a Web page.
0:36
This was hard to find, and that causes big problems that follow on for everything that comes after it in the site, Not just what we right, but even the content that was part of the outer shell of our general look and feel.
0:48
So what we decided to do was go with mark down and we use the simple mde markdown editor and all you gotta do is take a text area include a little CSS and JavaScript and point this thing at it.
1:00
It becomes in awesome little editor. Remember, we're gonna go and add the CSS at the top.
1:07
We're going to add the JavaScript at the bottom in this additional Js thing. And we have a script section.
1:12
We just create this simple MD And we say the element element is document dog get element bidi. Our text area had the i d contents.
1:20
So we just say contents. That's it. One other thing I would do is I would say spellchecker false. Turn that off. The spell checker is not great.
1:29
Yeah, I just like to turn it off cause you already got a spellchecker in here. What browser, anyway? Just use that.