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


PHP getFieldValue函数代码示例

本文整理汇总了PHP中getFieldValue函数的典型用法代码示例。如果您正苦于以下问题:PHP getFieldValue函数的具体用法?PHP getFieldValue怎么用?PHP getFieldValue使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: generateCouponCode

function generateCouponCode()
{
    $code = "UNI" . substr(date("Y"), 2, 2) . date("m") . date("d") . date("his");
    $code .= mt_rand(11111, 99999);
    $codeExist = getFieldValue("code", "coupon", "WHERE code='" . $code . "'");
    if (empty($codeExist)) {
        return $code;
    } else {
        generateCouponCode();
    }
}
开发者ID:akhtar-husain,项目名称:coupon,代码行数:11,代码来源:config.php

示例2: sendMail

function sendMail()
{
    $to = getFieldValue('email');
    $subject = 'Notification: Your bio was just updated';
    $message = 'Your bio was updated on ' . date('o-m-d') . ' at ' . date('H:m:s') . "\r\n";
    $message .= 'First Name: ' . getFieldValue('firstName') . "\r\n";
    $message .= 'Last Name: ' . getFieldValue('lastName') . "\r\n";
    $message .= 'Age: ' . getFieldValue('age') . "\r\n";
    $message .= 'Email: ' . $to . "\r\n";
    $message .= 'Short Bio: ' . getFieldValue('shortBio') . "\r\n";
    $message = wordwrap($message, 70);
    $headers = array('From: ' . MY_EMAIL, 'X-Priority: 1 (highest)');
    $headers = implode("\r\n", $headers);
    var_dump('$to:' . $to);
    var_dump('$subject:' . $subject);
    var_dump('$message:' . $message);
    var_dump('$headers:' . $headers);
    // email does not work in windows!
    $boolResult = mail($to, $subject, $message, $headers);
    var_dump($boolResult);
    return $boolResult;
}
开发者ID:hoiwanjohnlouis,项目名称:eclipsePrototyping,代码行数:22,代码来源:helper_functions.php

示例3: getMenuAndStatus


//.........这里部分代码省略.........
				if($user->avatar!='' && $user->avatar!=null) {
					$mi = array(); $mi["_UE_MENU_EDIT"]["_UE_DELETE_AVATAR"]=null;
					$this->_addMenuItem( $mi, $menuTexts['_UE_DELETE_AVATAR'],cbSef($ue_deleteavatar_url), "",
					"<img src=\"".$adminimagesdir."delavatar.gif\" alt='' />","", $menuTexts['_UE_MENU_DELETE_AVATAR_DESC'],"" );
				}
			}
		}
		// ----- VIEW MENU - AFTER EDIT IF VIEWING A PROFILE -----
		if ( $_CB_framework->myId() > 0 ) {
			// View My Profile:
			if ( ( $_CB_framework->myId() != $user->id ) && ( $_CB_framework->displayedUser() !== null ) ) {
				$mi = array(); $mi["_UE_MENU_VIEW"]["_UE_MENU_VIEWMYPROFILE"]=null;
				$this->_addMenuItem( $mi, _UE_MENU_VIEWMYPROFILE,cbSef($ue_userprofile_url), "",
				"","", _UE_MENU_VIEWMYPROFILE_DESC,"" );
			}
		}
		// ----- MESSAGES MENU -----
		// Send PMS
		if ( $_CB_framework->myId() != $user->id && $_CB_framework->myId() > 0 ) {
			global $_CB_PMS;
			$resultArray = $_CB_PMS->getPMSlinks($user->id, $_CB_framework->myId(), "", "", 1);
			if (count($resultArray) > 0) {
				foreach ($resultArray as $res) {
				 	if (is_array($res)) {
						$mi = array(); $mi["_UE_MENU_MESSAGES"][$res["caption"]]=null;
						$this->_addMenuItem( $mi, getLangDefinition($res["caption"]),cbSef($res["url"]), "",
						"","", getLangDefinition($res["tooltip"]),"" );
				 	}
				}
			}
		}

		// Send Email
		$emailHtml=getFieldValue('primaryemailaddress',$user->email,$user);
		if ($ueConfig['allow_email_display']!=4 && $_CB_framework->myId() != $user->id && $_CB_framework->myId() > 0) {
			switch ($ueConfig['allow_email_display']) {
				case 1:	// Display Email only
					$caption = $emailHtml;
					$url = "javascript:void(0);";
					$desc = _UE_MENU_USEREMAIL_DESC;
					break;
				case 2:	// Display Email with link:
					$caption = null;
					$url = $emailHtml;
					$desc = _UE_MENU_SENDUSEREMAIL_DESC;
					break;
				case 3:	// Display Email-to text with link to web-form:
					$caption = _UE_MENU_SENDUSEREMAIL;
					$url = $emailHtml;
					$desc = _UE_MENU_SENDUSEREMAIL_DESC;
					break;
			}
			$mi = array(); $mi["_UE_MENU_MESSAGES"]["_UE_MENU_SENDUSEREMAIL"]=null;
			$this->_addMenuItem( $mi, $caption, $url, "", "", "", $desc, "" );
		}
		// ----- CONNECTIONS MENU -----
		IF ($ueConfig['allowConnections'] && $_CB_framework->myId() > 0) {
			$ue_addConnection_url = $ue_base_url."&amp;act=connections&amp;task=addConnection&amp;connectionid=".$user->id;
			$ue_removeConnection_url = $ue_base_url."&amp;act=connections&amp;task=removeConnection&amp;connectionid=".$user->id;
			$ue_manageConnection_url = $ue_base_url."&amp;task=manageConnections";
			
			// Manage My Connections
			$mi = array(); $mi["_UE_MENU_CONNECTIONS"]["_UE_MENU_MANAGEMYCONNECTIONS"]=null;
			$this->_addMenuItem( $mi, _UE_MENU_MANAGEMYCONNECTIONS,cbSef($ue_manageConnection_url), "",
			"","", _UE_MENU_MANAGEMYCONNECTIONS_DESC,"" );
			
开发者ID:rkern21,项目名称:videoeditor,代码行数:66,代码来源:cb.menu.php

示例4: array_unique

        $records_eventreports['order'] = array_unique($records_eventreports['order']);
    }
    if (count($records_eventreports['records']) > 0) {
        foreach ($records_eventreports['order'] as $repID) {
            //getFieldValue($records_eventreports, $repID, DT_ORIGINAL_RECORD_ID)
            //find DA Report name
            $da_report = '';
            $da_repID = getFieldValue($records_eventreports, $repID, DT_REPORT_DALINK);
            if ($da_repID > 0) {
                $da_report = recordSearch_2('ids:' . $da_repID);
                $da_report = getFieldValue($da_report, 0, DT_NAME);
            }
            ?>
                                <li>
                                    (#<?php 
            echo $repID . ')&nbsp;<em>' . getFieldValue($records_eventreports, $repID, 'rec_Title') . '</em>. [' . getFieldValue($records_eventreports, $repID, DT_DATE) . ']. ' . getTermById(getFieldValue($records_eventreports, $repID, DT_REPORT_SOURCE_TYPE)) . '&nbsp' . $da_report . ' ' . getFieldValue($records_eventreports, $repID, DT_REPORT_CITATION);
            ?>
                                </li>
                                <?php 
        }
    } else {
        echo '<li>None recorded</li>';
    }
    ?>
                    </ul>
                </p>

            </div>

        </body></html>
开发者ID:HeuristNetwork,项目名称:heurist,代码行数:30,代码来源:dh_popup_place.php

示例5: update_cateCount

         $sql = "update " . $DBPrefix . "logs set cateId='" . $_POST['move_category'] . "' where {$stritem}";
         $DMC->query($sql);
         update_cateCount($_POST['move_category'], "adding", count($itemlist));
     }
     //更新Cache
     categories_recache();
     recentLogs_recache();
     logsTitle_recache();
     logs_sidebar_recache($arrSideModule);
 }
 //自动截取
 if ($_POST['operation'] == "addautoSplit" and $stritem != "") {
     $autoSplit = $_POST['addautoSplit'];
     for ($i = 0; $i < count($itemlist); $i++) {
         $mark_id = $itemlist[$i];
         $logContent = getFieldValue($DBPrefix . "logs", " id='{$mark_id}'", "logContent");
         //如果日志包含了特殊标签,则不自载截取
         if (strpos(";" . $logContent, "<!--more-->") > 0) {
             $autoSplit = 0;
         }
         if (strpos(";" . $logContent, "<!--nextpage-->") > 0) {
             $autoSplit = 0;
         }
         if (strpos(";" . $logContent, "<!--hideBegin-->") > 0) {
             $autoSplit = 0;
         }
         if (strpos(";" . $logContent, "<!--galleryBegin-->") > 0) {
             $autoSplit = 0;
         }
         //if (strpos(";".$logContent,"<!--fileBegin-->")>0) $autoSplit=0;
         //if (strpos(";".$logContent,"<!--mfileBegin-->")>0) $autoSplit=0;
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:logs.php

示例6: explode

             $tsize = explode('x', strtolower($settingInfo['thumbSize']));
             if ($fileWidth > $tsize[0] || $fileHeight > $tsize[1]) {
                 $attach_thumb = array('filepath' => "../attachments/" . $value, 'filename' => $attachment, 'extension' => $fileType, 'thumbswidth' => $tsize[0], 'thumbsheight' => $tsize[1]);
                 $thumb_data = generate_thumbnail($attach_thumb);
                 $fileWidth = $thumb_data['thumbwidth'];
                 $fileHeight = $thumb_data['thumbheight'];
                 $thumbfile = $thumb_data['thumbfilepath'];
                 $value = str_replace("../attachments/", "", $thumbfile);
             }
         }
     } else {
         $thumbfile = "";
     }
     //写进数据库
     $fileName = $attdesc == "" ? $fileName : encode($attdesc) . "." . $fileType;
     $rsexits = getFieldValue($DBPrefix . "attachments", "attTitle='" . $fileName . "' and fileType='" . $updateStyle . "' and fileSize='" . $fileSize . "' and logId='0'", "name");
     if ($rsexits == "") {
         $sql = "INSERT INTO " . $DBPrefix . "attachments(name,attTitle,fileType,fileSize,fileWidth,fileHeight,postTime,logId) VALUES ('{$value}','{$fileName}','{$updateStyle}','{$fileSize}','{$fileWidth}','{$fileHeight}','" . time() . "',0)";
         $DMC->query($sql);
     } else {
         print_message($strDataExists);
     }
     do_filter("f2_attach", $basefile);
     if (!empty($thumbfile)) {
         do_filter("f2_attach", $thumbfile);
         //縮略圖
     }
     settings_recount("attachments");
     settings_recache();
     $action = "";
 }
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:attach.php

示例7: getFieldValue

    }
    if ($check_info == 1) {
        if ($mark_id != "") {
            //编辑
            $rsexits = getFieldValue($DBPrefix . "filters", "name='" . encode($_POST['name']) . "' and category='" . $_POST['category'] . "'", "id");
            if ($rsexits != $mark_id && $rsexits != "") {
                $ActionMessage = "{$strDataExists}";
                $action = "edit";
            } else {
                $sql = "update " . $DBPrefix . "filters set name='" . encode($_POST['name']) . "',category='" . $_POST['category'] . "' where id='{$mark_id}'";
                $DMC->query($sql);
                $action = "";
            }
        } else {
            //新增
            $rsexits = getFieldValue($DBPrefix . "filters", "name='" . encode($_POST['name']) . "' and category='" . $_POST['category'] . "'", "id");
            if ($rsexits != "") {
                $ActionMessage = "{$strDataExists}";
                $action = "add";
            } else {
                $sql = "INSERT INTO " . $DBPrefix . "filters(name,category) VALUES ('" . encode($_POST['name']) . "','" . $_POST['category'] . "')";
                $DMC->query($sql);
                $action = "";
            }
        }
        if ($action == "") {
            filters_recache();
        }
    }
}
//其它操作行为:编辑、删除等
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:filters.php

示例8: foreach

echo 'END$$<br/>DELIMITER ;';
echo '<br/><br/>';
/* Update Proc */
$tab = '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp';
echo 'USE `' . Config::$database . '`;<br/>';
echo 'DROP procedure IF EXISTS `update' . $class->getName() . '`;<br/><br/>';
echo 'DELIMITER $$<br/>';
echo 'USE `' . Config::$database . '`$$<br/><br/>';
echo 'CREATE PROCEDURE update' . $class->getName() . '(_id int';
$fieldarray = $class->getFields();
$separator = ", ";
foreach ($fieldarray as $field) {
    if ($field[1] != "linkedentities" && $field[1] != "childentities") {
        echo $separator . $field[0] . ' ';
    }
    echo getFieldValue($field);
}
echo ", _tenantid int";
if ($class->hasOwner()) {
    echo ', _userid int';
}
echo ")<br/>";
echo 'BEGIN<br/>';
echo '<br/>';
echo $tab . 'UPDATE ' . lcfirst($class->getName()) . ' SET<br/>';
$separator = $tab . $tab;
foreach ($fieldarray as $field) {
    if ($field[1] != "linkedentities" && $field[1] != "childentities") {
        echo $separator . $field[0] . ' = ' . $field[0];
        $separator = ',<br/>' . $tab . $tab;
    }
开发者ID:robertmoss,项目名称:foodfinder_main,代码行数:31,代码来源:generateSQL.php

示例9: foreach

?>
 </td>
  </tr>
  <tr>
    <td align="left"><img src="images/line2.gif"></td>
  </tr>
  <tr>
    <td align="left" height="5"></td>
  </tr>
<?php 
$j = 1;
foreach ($headHunters as $rec_id => $shortlist_count) {
    if ($j > 4) {
        break;
    }
    $logo = getFieldValue("job_recruiter", "comp_logo", "rec_id", $rec_id);
    $img_exist = 0;
    $directory = "recruiter/logos/";
    $handle = opendir($directory);
    while (FALSE !== ($item = readdir($handle))) {
        if ($item == $logo) {
            $img_exist = 1;
        }
    }
    if ($img_exist == 1) {
        ?>
  <tr>
    <td align="left" height="82"><img src="recruiter/logos/<?php 
        echo $logo;
        ?>
" ></td>
开发者ID:beyondkeysystem,项目名称:testone,代码行数:31,代码来源:right.php

示例10: call_user_func

        $ActionMessage = call_user_func($plugin . "_unstall");
        if ($ActionMessage == "") {
            $ActionMessage = "{$strf2Plugins} <b>{$plugin}</b> {$strUnActive}{$strSuccess}!";
            modules_recache();
            modulesSetting_recache();
        } else {
            $ActionMessage = "{$strf2Plugins} <b>{$plugin}: </b>" . $ActionMessage;
        }
    }
    $action = "";
}
if ($action == "setSave") {
    $plugin = basename($_GET['plugin']);
    $title = "{$strf2Plugins} <b>{$plugin}</b> {$strPluginSetting}";
    include_once F2BLOG_ROOT . "plugins/{$plugin}/setting.php";
    $modId = getFieldValue($DBPrefix . "modules", "name='{$plugin}'", "id");
    $ActionMessage = call_user_func_array($plugin . "_setSave", array($_POST, $modId));
    if ($ActionMessage == "") {
        $ActionMessage = "{$strf2Plugins} <b>{$plugin}</b> {$strPluginSetting}{$strSuccess}!";
        modulesSetting_recache();
    } else {
        $ActionMessage = "{$strf2Plugins} <b>{$plugin}: </b>" . $ActionMessage;
    }
    //Redirect setting
    $action = "set";
}
if ($action == "set") {
    $plugin = basename($_GET['plugin']);
    $title = "{$strf2Plugins} {$plugin} {$strPluginSetting}";
    $arr = getModSet($plugin);
    include_once "../plugins/{$plugin}/setting.php";
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:plugins.php

示例11: addCategory

function addCategory($name)
{
    global $DMC, $DBPrefix;
    $orderno = getFieldValue($DBPrefix . "categories", "parent='0' order by orderNo desc", "orderNo");
    if ($orderno < 1) {
        $orderno = 1;
    } else {
        $orderno++;
    }
    $sql = "INSERT INTO {$DBPrefix}categories(parent,name,orderNo,isHidden,cateIcons) VALUES ('0','{$name}','{$orderno}','0','1')";
    $DMC->query($sql);
    return $DMC->insertId();
}
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:13,代码来源:rss_import.php

示例12: urlencode

    $seektype = "";
}
$seek_url = "{$PHP_SELF}?order={$order}";
//查找用链接
$edit_url = "{$PHP_SELF}?basedir=" . urlencode($basedir) . "&seekname={$seekname}&seektype={$seektype}";
//编辑或新增链接
if ($action == "add") {
    //新增。
    $title = "{$strAttachmentsTitleAdd}";
    include "attachments_add.inc.php";
} else {
    if ($action == "edit" && $_GET['file_id'] != "") {
        //修改文件名。
        $title = "{$strAttachmentsTitleEdit}";
        $file_id = $_GET['file_id'];
        $file_title = getFieldValue($DBPrefix . "attachments", "where name like '%" . $file_id . "'", "attTitle");
        if ($file_title != "") {
            $file_title = substr($file_title, 0, strrpos($file_title, "."));
        }
        include "attachments_edit.inc.php";
    } else {
        //查找和浏览
        $title = "{$strAttachmentsTitle}";
        $handle = opendir("{$basedir}");
        while ($file = readdir($handle)) {
            if (is_file($basedir . $file)) {
                $filetype = getFileType($file);
                if ($seektype != "") {
                    if (strpos(";{$seektype}", $filetype) > 0) {
                        $filelist[] = $file;
                    }
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:attachments.php

示例13: getFieldValue

                 }
                 $orderSQL = ",orderNo='{$orderno}'";
             }
             $sql = "update " . $DBPrefix . "modules set name='{$name}',modTitle=\"{$modTitle}\",disType='{$disType}',isHidden='{$isHidden}',indexOnly='{$indexOnly}',htmlCode=\"{$htmlCode}\",pluginPath='{$pluginPath}',isInstall='{$isInstall}'{$orderSQL} where id='{$mark_id}'";
             $DMC->query($sql);
             $ActionMessage = $strSaveSuccess;
             $action = "";
         }
     } else {
         //新增
         $rsexits = getFieldValue($DBPrefix . "modules", "name='{$name}' and disType='{$disType}'", "id");
         if ($rsexits != "") {
             $ActionMessage = "{$strDataExists}";
             $action = "add";
         } else {
             $orderno = getFieldValue($DBPrefix . "modules", "disType='{$disType}' order by orderNo desc", "orderNo");
             if ($orderno < 1) {
                 $orderno = 1;
             } else {
                 $orderno++;
             }
             $sql = "INSERT INTO " . $DBPrefix . "modules(name,modTitle,disType,isHidden,indexOnly,orderNo,htmlCode,pluginPath,isInstall) VALUES ('{$name}',\"{$modTitle}\",'{$disType}','{$isHidden}','{$indexOnly}','{$orderno}',\"{$htmlCode}\",'{$pluginPath}','{$isInstall}')";
             $DMC->query($sql);
             $ActionMessage = $strSaveSuccess;
             $action = "";
         }
     }
     if ($action == "") {
         modules_recache();
     }
 } else {
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:modules.php

示例14: safe_convert

     //检测验证码
     if (!empty($_POST['validate'])) {
         $_POST['validate'] = safe_convert($_POST['validate']);
     }
     if ($check_info == 1 && (empty($_POST['validate']) || $_POST['validate'] != $_SESSION['backValidate']) && $settingInfo['isValidateCode'] == 1) {
         $ActionMessage = $strGuestBookValidError;
         $check_info = 0;
     } else {
         $_SESSION['backValidate'] = "";
         //把验证码清除
     }
     if ($check_info == 1) {
         $blogName = safe_convert(strip_tags($_POST['blogName']));
         $blogUrl = safe_convert(strip_tags($_POST['blogUrl']));
         $blogLogo = safe_convert(strip_tags($_POST['blogLogo']));
         $rsexits = getFieldValue($DBPrefix . "links", "name='{$blogName}' or blogUrl='{$blogUrl}'", "id");
         if ($rsexits != "") {
             $ActionMessage = $strDataExists;
         } else {
             $sql = "INSERT INTO " . $DBPrefix . "links(name,blogUrl,blogLogo) VALUES ('{$blogName}','{$blogUrl}','{$blogLogo}')";
             $DMC->query($sql);
             $ActionMessage = "{$strApplyWaitApprove}";
             $blogName = $blogUrl = $blogLogo = "";
         }
     }
 }
 if (preg_match("/http:\\/\\//is", $settingInfo['linklogo'])) {
     $logopath = $settingInfo['linklogo'];
 } else {
     $logopath = $settingInfo['blogUrl'] . $settingInfo['linklogo'];
 }
开发者ID:BGCX067,项目名称:f2cont-svn-to-git,代码行数:31,代码来源:applylink.inc.php

示例15: getFieldValue

</td>
                                    </tr>
                                    <?php 
    }
    ?>
                                    <tr>
                                      <td>Country</td>
                                      <td align="left"><?php 
    echo getFieldValue("job_country", "country_name", "country_id", $rsRec->rec_country);
    ?>
</td>
                                    </tr>
                                    <tr>
                                      <td>Province/State</td>
                                      <td align="left"><?php 
    echo getFieldValue("job_state", "state_name", "state_id", $rsRec->rec_state);
    ?>
                                      </td>
                                    </tr>
                                </table></td>
                              </tr>
                              <tr>
                                <td height="10"></td>
                              </tr>
                              <tr>
                                <td class="subhead_gray_small" >Contact Information</td>
                              </tr>
                              <tr>
                                <td><img src="../images/line.gif" width="772"></td>
                              </tr>
                              <tr>
开发者ID:beyondkeysystem,项目名称:testone,代码行数:31,代码来源:view_profile.php


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