2009-06-03 Benjamin Mack <benni@typo3.org>
+ * Fixed #11234: Deprecate formatSize and checkEmail functions
* Followup to #11148: Remove static require_once() to t3lib and tslib and use autoloading instead - re-added require_once() for the services classes
2009-06-03 Francois Suter <francois@typo3.org>
*
* @param integer Bytes to be formated
* @return string Formatted with M,K or appended.
+ * @deprecated since at least TYPO3 4.2 - Use t3lib_div::formatSize() instead
*/
function formatSize($sizeInBytes) {
+ t3lib_div::logDeprecatedFunction();
+
if ($sizeInBytes>900) {
if ($sizeInBytes>900000) { // MB
$val = $sizeInBytes/(1024*1024);
if ($conf['age']){$content=$this->calcAge(time()-$content,$conf['age']);}
if ($conf['case']){$content=$this->HTMLcaseshift($content, $conf['case']);}
- if ($conf['bytes']){$content=$this->bytes($content,$conf['bytes.']['labels']);}
+ if ($conf['bytes']){$content=t3lib_div::formatSize($content, $conf['bytes.']['labels']);}
if ($conf['substring']){$content=$this->substring($content,$conf['substring']);}
if ($conf['removeBadHTML']) {$content = $this->removeBadHTML($content, $conf['removeBadHTML.']);}
if ($conf['stripHtml']){$content = strip_tags($content);}
* @deprecated since TYPO3 3.6 - Use t3lib_div::formatSize() instead
*/
function bytes($sizeInBytes,$labels) {
+ t3lib_div::logDeprecatedFunction();
+
return t3lib_div::formatSize($sizeInBytes,$labels);
}
* @deprecated since TYPO3 3.6 - Use t3lib_div::validEmail() instead
*/
function checkEmail($email) {
+ t3lib_div::logDeprecatedFunction();
+
return t3lib_div::validEmail($email);
}