Forum Moderators: coopster

Message Too Old, No Replies

developing small php website with very simple cms

should I use mysql, text files, xml?

         

HelenDev

6:35 pm on Sep 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I'm looking into developing a small website (5 pages or so) in which the user can update the content via their browser. I've developed large product based websites before using php and mysql, and am wondering whether to use a similar approach for this mini site.

I know that you can read and write txt files using php and was wondering if this might be a better way to go? I'm not sure how this would work however in that, would I need loads of individual text files for each page, ie one for a heading say, and one for main page content etc. in which case it might be better to stick with what I know and use a database? Or can I put some sort of markup in the text files to split them into parts?

Or how about xml? Has anyone used xml (with php) for this kind of thing?

Also, I might want to allow the client to perform very basic formatting through a browser based form, such as Headings, bold text etc.

I realise that stuff has already been written for this purpose, such as ready made cms software, text editors etc., and I'm not trying to reinvent the wheel but would quite like to code it simply myself, rather than having to configure something bulky already written.

I haven't got started on this yet but would appreciate any thoughts anyone has on which approach to take, and whether anyone has any experience of the above.

Cheers,

H

henry0

7:12 pm on Sep 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Not 100% sure but if I remember +/- OK
Doesn't CURL come with a ready to use BB style editing function.

dhardisty

10:54 am on Sep 10, 2005 (gmt 0)

10+ Year Member



I would stick with MySQL. If the project is successful, the client will inevitably want the site expanded. You should always allow for scalability when possible.

As for having the client formatting, I'd recommend using a free WYSIWYG editor to edit the html chunks that you'll be storing in MySQL. I've used TinyMCE [tinymce.moxiecode.com...] and FCKeditor [fckeditor.net...] and they both worked just great.