The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Need some help

I'm currently having some construction on my website, it now contains only static pages with includes everywhere, but now I'm a database driven with oop.

The thing is, I've thought about the model it should follow, in a functions file I've built a rough function about how I should go about.

Now how do I determine whether which sections need seperate functions, and not use a rough object model? The reason being I need to pull different data, and different sections have different needs, but I see that I could have a workaround by modifying parameters of the function which directly changes the query. But is this good oop practice?

Let's say I've Profiles, Downloads, Rules, Gallery and Site Map sections. How would you determine if each should have its own functions, or use the main one?

Thanks, sorry if I've put it across as very weird, I'd explain more if needed.

Yeah it's just a judgement call on your part. You can mess with your functions forever and add tons of extra parameters and code to get them to work in each area, or you can have separate, slightly different versions for each use. You have to figure out some balance.