I am so clearly off base that no-one seems to understand my question -- and I can't come up with keyword searches that come close to my issue.
I am using PHP5 classes and what I understand as OOP methodolgy to write a simple CRUD application.
My visitor arrives at the index.php where I want to send a screen with the message "Please enter your name and password and select a day or list". The screen contains xhtml input fields for name and password, checkboxes for each day of the week and a group of radio buttons for available lists. The form action sends the user to /menu/post.php
/menu/post.php instantiates a new menu_postgui Class that inherits from (extends) abstract_postgui. Among its tasks is to validate the data entered.
If the data is NOT valid, I want to send back the original screen filled in with what the visitor entered and the message(s) indicating what errors I found (without duplicating the xhtml code).
If the user data passes the menu_postgui Class validation, I want to instantiate the proper class for the selected option (which I do through a switch-case element) which will send its own xhtml form. (which will have the similar requirements for error-reporting).
As of yet, I have not been able to send an xhtml to the screen by imbedding <?php ?> if I try to put it in a CLASS. Nor have I found a way (except through $_SESSION) to pass msgs and such to a pure php (i.e. not a class) script.
Does anyone have a simple example of how to logistically handle user interface with oop validations (without duplicating the XHTML code)?
I could not code the '<link' address to consistently pull in the stylesheet (depending on which parent instantiated the code-generating class). Using an algorithm with $_SESSION didn't work. Neither did __DIR__.
What did work, at least in my test, was to code the href as a literal beginning with "http://localhost/..."