本文整理汇总了PHP中FileUpload::GetDBThumbMedium方法的典型用法代码示例。如果您正苦于以下问题:PHP FileUpload::GetDBThumbMedium方法的具体用法?PHP FileUpload::GetDBThumbMedium怎么用?PHP FileUpload::GetDBThumbMedium使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FileUpload
的用法示例。
在下文中一共展示了FileUpload::GetDBThumbMedium方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
} else {
// Article has not been published before
$blnFirstPublish = true;
}
} else {
// Article is not yet published
$blnFirstPublish = false;
}
$CMS->ART->Edit($intContentID, $intAuthorID, $strContTitle, $strContBody, $dteArticleCreated, $intAreaID, $strTagList, $strContURL, $strContStatus, $strGroupList, $strExcerpt, $intCustomOrder);
$CMS->ART->ClearUserlist($intContentID);
}
// Create file
if ($blnHasAttachment) {
if ($blnExistingAttachment) {
$strGroups = "";
$CMS->FL->EditAttachment($intFileID, $FU->GetDBFilePath(), $intUserID, $dteArticleCreated, $strContTitle, $FU->GetDBThumbSmall(), $FU->GetDBThumbMedium(), $FU->GetDBThumbLarge(), $intContentID);
} else {
$intFileID = $CMS->FL->CreateAttachment($FU->GetDBFilePath(), $intUserID, $dteArticleCreated, $strContTitle, $FU->GetDBThumbSmall(), $FU->GetDBThumbMedium(), $FU->GetDBThumbLarge(), $intContentID);
}
}
// Notify admin
if ($strContStatus == C_CONT_REVIEW) {
$CMS->MSG->ReviewArticleNotification($intContentID, $arrCurrentData);
}
if ($blnFirstPublish) {
$CMS->MSG->NewArticleNotification($intContentID, $arrCurrentData);
}
// Build confirmation page
$strAddAnother = "";
if ($strContStatus == C_CONT_PUBLISHED) {
$strItemMsg = "Article published.";
示例2: elseif
if ($FU->IsError()) {
$CMS->Err_MFail($FU->GetErrorDesc(), $FU->GetErrorInfo());
}
}
// Make thumbnails
if ($blnCreate) {
$FU->DoThumbs("");
} elseif ($blnEdit) {
$FU->DoThumbs($intFileID);
}
$strWarnings .= $FU->GetWarnings();
// ** DATABASE WRITE ** //
// Write to DB
if ($blnCreate) {
$dteFileCreated = $CMS->SYS->GetCurrentDateAndTime();
$intFileID = $CMS->FL->Create($FU->GetDBFilePath(), $intUserID, $dteFileCreated, $strTitle, $FU->GetDBThumbSmall(), "N", "Y", $FU->GetDBThumbMedium(), $FU->GetDBThumbLarge());
$strDidWhat = "uploaded";
$strUploadAnother = "<br /><a href=\"{FN_ADM_FILES_SITE_UPLOAD}?action=create\">Upload another file</a> |";
} elseif ($blnEdit) {
$arrFile = $CMS->FL->GetFile($intFileID);
$dteFileCreated = $arrFile['create_date_raw'];
$CMS->FL->Edit($intFileID, $FU->GetDBFilePath(), $strTitle, $dteFileCreated, $FU->GetDBThumbSmall(), $FU->GetDBThumbMedium(), $FU->GetDBThumbLarge());
$strDidWhat = "updated";
$strUploadAnother = "";
}
// Confirmation page
$strHTML = "<h1>{$strPageTitle}</h1>\n\n{$strWarnings}<p>The file was successfully {$strDidWhat}.{$strUploadAnother} <a href=\"{FN_ADM_FILES}?type=site\">View Site Files</a></p>";
$CMS->AP->SetTitle($strPageTitle . " - Results");
$CMS->AP->Display($strHTML);
}
}