samedi 31 janvier 2015

Best way to deploy a Content Management System for a relatively static website?


I'm going to create a content management system for a website I am producing for a client.


The website will be a club-page which will allow inquiries to join the club, registration as well as event pages that will include photos and such.


I was wondering what the best way to create a content management system where by the admin can add new event pages, or edit existing information such as titles, headings and paragraphs. I also want to produce a way of adding new headings and paragraphs within the page.


I'm not sure on the best method of adding new tags to an existing HTML document, or what should be included in the homepages' HTML since new tags and content will need to be added after.


This is a given project so using an already existing CMS solution is out of the question.


To give you a flavor of what I'm after, my first solution was to create a homepage with pre-determined tags with id's such as <p id='p1'></p> I was then going to store data in the database with columns 'tag' and 'content' i.e 'tag' = p1 and 'content = "This is a paragraph".


When the user initially visits the homepage, it would fire an ajax request to get all the data from the database and inject it into the tags based on the 'tag' entry. like, if 'tag' = p1 then getElementById("p1").innerHTML...


However, this approach would require me to know what tags to put in the html document. Alternatively I could just store all the homepage's content in one big database entry and return the entirety of it when the page loads. Although I'm sure it's pretty bad practise to request and process this much data just to display a homepage... Or is it okay to do so?


Any help/links you can shed some light on this problem will be greatly appreciated.


Many thanks, Mike





Aucun commentaire:

Enregistrer un commentaire