当前位置: 首页>>代码示例>>PHP>>正文


PHP string::sentence方法代码示例

本文整理汇总了PHP中string::sentence方法的典型用法代码示例。如果您正苦于以下问题:PHP string::sentence方法的具体用法?PHP string::sentence怎么用?PHP string::sentence使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在string的用法示例。


在下文中一共展示了string::sentence方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: html_displayXML

    /**
     * @return void
     * @param CoreWorkflowDatPacket $coreWorkflowDataPacket
     * @desc Displays the HTML for the each workflow item
    */
    function html_displayXML($coreWorkflowDataPacket)
    {
        $tdClass = 'helpBod';
        $planGroups = array();
        $formName = '';
        workflowDisplayHTML::workflowState($coreWorkflowDataPacket->getWorkflowId(), $coreWorkflowDataPacket->getData(), false);
        //Fetch plans from the database
        $planGraphList = graphPlanDatabaseAccess::getPlanGraphList($coreWorkflowDataPacket->getworkflowid());
        $possibleActions = actionPacket::processLoop($planGraphList, $coreWorkflowDataPacket->getworkflowid());
        if (sizeof($possibleActions)) {
            //Actions have been fouund
            $possibleActionsSize = sizeof($possibleActions);
            for ($actionPacketIndex = 0; $actionPacketIndex < $possibleActionsSize; $actionPacketIndex++) {
                $currentAction = $possibleActions[$actionPacketIndex]->getAction();
                $data = $currentAction->getData();
                $entryTimepoint = $currentAction->getName();
                $vars = $data[0]->getPredicateValues();
                $formName = $vars[0]->toString();
                $workflowCreator = $vars[1]->toString();
                //Convert into string form
                array_push($planGroups, $vars[2]->toString());
                //Check if this is a loop re-entry point
                if ($possibleActions[$actionPacketIndex]->checkForLoopReentry($entryTimepoint)) {
                    //Check we have not already save the state
                    if (!graphPlanDatabaseAccess::stateAlreadyUpdated($coreWorkflowDataPacket->getworkflowid(), $formName)) {
                        graphPlanDatabaseAccess::savePlanState($planGraphList, $coreWorkflowDataPacket->getworkflowid(), $formName);
                    }
                }
            }
            //Fetch the groups the user is a member of
            $groups = groups::getUserGroupNames($_SESSION['valid_user']);
            $groupString = "";
            $superuser = false;
            //Compare against the groups specified in the plans
            $groupsSize = sizeof($groups);
            for ($index = 0; $index < $groupsSize; $index++) {
                if ($groups[$index] == 'superuser') {
                    $superuser = true;
                } else {
                    $groupString .= $groups[$index];
                }
            }
            if (!$superuser) {
                $match = arrays::searchArray($planGroups, $groups);
            } else {
                $match = $planGroups[0];
            }
            ?>
		
	<td class="<?php 
            echo $tdClass;
            ?>
" width="172"><?php 
            echo string::sentence($formName);
            ?>
</td>
        
	<td class="<?php 
            echo $tdClass;
            ?>
" width="100"> <?php 
            echo string::sentence($workflowCreator);
            ?>
 </td>
        
	<td class="<?php 
            echo $tdClass;
            ?>
"> <?php 
            echo time::arrangedate($coreWorkflowDataPacket->getDate());
            ?>
 </td>

	<?php 
            workflowDisplayHTML::buttons($coreWorkflowDataPacket->getWorkflowId(), $match, $planGroups, $formName);
        }
    }
开发者ID:printedheart,项目名称:iwfms,代码行数:82,代码来源:workflowDisplayHTML.php


注:本文中的string::sentence方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。