403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/clouds/classes/general/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/clouds/classes/general/util.php
<?php

class CCloudUtil
{
	/**
	 * @param string $str
	 * @param string $charset
	 * @return string
	*/
	public static function URLEncode($str, $charset, $file_name = false)
	{
		$strEncodedURL = '';

		if ($file_name)
		{
			$arUrlComponents = preg_split('#(://|/)#', $str, -1, PREG_SPLIT_DELIM_CAPTURE);
		}
		else
		{
			$arUrlComponents = preg_split('#(://|/|\\?|=|&)#', $str, -1, PREG_SPLIT_DELIM_CAPTURE);
		}

		foreach ($arUrlComponents as $i => $part_of_url)
		{
			if ((intval($i) % 2) == 1)
			{
				$strEncodedURL .= (string)$part_of_url;
			}
			elseif (defined('BX_CLOUD_OLD_URL_ENCODE') && constant('BX_CLOUD_OLD_URL_ENCODE') === true)
			{
				$strEncodedURL .= rawurlencode(\Bitrix\Main\Text\Encoding::convertEncoding(rawurldecode((string)$part_of_url), LANG_CHARSET, $charset));
			}
			else
			{
				$strEncodedURL .= rawurlencode(\Bitrix\Main\Text\Encoding::convertEncoding((string)$part_of_url, LANG_CHARSET, $charset));
			}
		}

		return $strEncodedURL;
	}

	/**
	 * @param string $str
	 * @return \Bitrix\Main\Type\DateTime
	*/
	public static function gmtTimeToDateTime($str)
	{
		$timestamp = strtotime($str . 'Z');
		$datetime = \Bitrix\Main\Type\DateTime::createFromTimestamp($timestamp);
		return $datetime;
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit