开发者

PHP framework class - How to initiate classes via class

I usually setup a initial class on a website called something like baseFrame, which holds all the basics functions. (MVC style)

Now, I realized I was having issues calling the baseFrame from classes called throughout the website (the baseFrame has a function called callClass, which I was using to include and running the new class that extends from the base. I realized that you can't call a extended class under a function, because it's unable to read the parent class.

So, I wrote a new script called "callfunction.php" which was not a class base it self, it was a straight function that called the extended class, which calls the baseFrame correctly. Now this method worked, I however am not used to not using classes. Is there something I'm missing? Would I rather call a new class from within the baseFrame class? Is that possible? Again, running a class within the ba开发者_运维知识库seFrame class didn't allow me to call the extended at all...So I'm guessing that isn't technically possible?


may be this resources help. there are many frameworks to build secure and reliable systems.

note: mvc is just one solution.

http://framework.zend.com/

http://wordpress.com (extensible via plugins)

http://www.codeigniter.com/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜