Content Placement - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Content Placement (/showthread.php?tid=22197) |
Content Placement - El Forum - 09-01-2009 [eluser]georgerobbo[/eluser] Hello, I'm trying to decided what to do with my content (plain text). Should I have it read off a database, an xml file or just stored in an array? What's the most function solution? Content Placement - El Forum - 09-01-2009 [eluser]tim1965[/eluser] I store mine in a DB for ease of control, and it gives me one method to call it. I find this easier. Content Placement - El Forum - 09-01-2009 [eluser]georgerobbo[/eluser] What structure do you use? I don't want to have a different table for every page? Content Placement - El Forum - 09-05-2009 [eluser]tim1965[/eluser] Sry for late reply been away. I use one row for each page content and select by id so one id and TEXT field.And then call the id for which ever page is required Content Placement - El Forum - 09-05-2009 [eluser]SitesByJoe[/eluser] I put all my page content into a database table named "pages" and I use a structure similar to this: page_id page_meta_title page_meta_description page_meta_keywords page_url page_content page_status (draft or published) page_added page_last_updated One row for each page. It also helps if you build a nice form for page management. Plain text entry is fine - you can use CI's typograhy helper to make things look nice (only simple stuff of course) Using the page_url and/or page_id I can call pages either by their id or matching url, like: mysite.com/pages/the-url-of-my-page This set up works extremely well for both myself and my clients. |