Jump to content

Do you use PageClasses/Components?


FeelinMyself

Recommended Posts

Hi Guys,

 

I'm new to this forum, so I don't know how much this has been discussed in the past.

 

With my own pages, I've been making a "pageclass" in each PHP file, like this:

 

NewsList.php:

class NewsList extends Page {

}

 

Also I'm experimenting with sub-pages, or "controls", and integrating them using templates.

 

For example:

 

require_once("Login.control.php")

$login = new Login();

$template->set("login", $login->get_HTML());

 

So I just wanted to share that and see if anyone else is doing the same and if you've come across any difficulties with this?

 

(One difficulty I'm having right now is with Ajaxing. I'm trying to decide how to dynamically update *only* controls whos data has CHANGED during an AJAX request, so that I don't send too much HTML back to the client.)

 

Link to comment
https://forums.phpfreaks.com/topic/37232-do-you-use-pageclassescomponents/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.