本文整理汇总了PHP中MyView::displayTheInfo方法的典型用法代码示例。如果您正苦于以下问题:PHP MyView::displayTheInfo方法的具体用法?PHP MyView::displayTheInfo怎么用?PHP MyView::displayTheInfo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MyView
的用法示例。
在下文中一共展示了MyView::displayTheInfo方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: MyModel
<?php
/*include_once("myconfig.php");*/
include '.././classes/mymodel.php';
include '.././classes/myview.php';
/*CONTROLLER CREATES THE MODEL*/
$theActualModel = new MyModel();
/*TEST IT IS INSTANCIATED*/
$myTemp = $theActualModel->getQueryValue();
echo $myTemp;
echo "<p></p>";
/*CONTROLLER FINDS OUT THE QUERY STRING APPENDED TO THE URL, REVERSES IT, AND SENDS IT TO THE MODEL*/
/*... BUT MAYBE IT WOULD BE BETTER FOR THE MANIPULATION TO OCCUR INSIDE THE MODEL?*/
$theURLStuff = strrev($_SERVER['QUERY_STRING']);
$theActualModel->setQueryValue($theURLStuff);
/*CONTROLLER CREATES THE VIEW*/
$theActualView = new MyView();
/*TEST THE VIEW WORKS*/
$myTempViewModelText = $theActualView->displayTheInfo();
/*echo $myTempViewModelText ; */
echo "<p>Here is the number at the end of the URL, but reversed.</p>";
/*CONTROLLER GETS TEXT FROM THE MODEL AND SENDS TO THE VIEW*/
$theActualView->setInfoToDisplay($theActualModel->getQueryValue());
/*CONTROLLER TELLS VIEW TO DISPLAY THE TEXT*/
$theActualView->displayTheInfo();