Перейти к содержанию

Silence

Актив
  • Постов

    2061
  • Зарегистрирован

  • Посещение

  • Победитель дней

    109

Сообщения, опубликованные Silence

  1. 1 час назад, Silence сказал:
    1. Download the HTMLMinifier file HTMLMinifier.php
    2. Include the following code into the php 
    
    <?php 
      
    // Import the HTMLMinifier 
    require_once 'myfolder/HTMLMinifier.php'; 
      
    // HTML source to be minified 
    $htmlpage = file_get_contents('./mypage.html'); 
      
    // Minified version of the page 
    echo HTMLMinifier::process($htmlpage); 
      
    ?>  

     

    3.Run the php file

    Извинете ... оправено

  2. system/Login/Login.php

    /**
    	 * @brief Force a URL to send to post-login
    	 * @note Useful when you need to redirect the user to another URL that is not local to this installation
    	 */
    	public static $forcedRedirectUrl = NULL;
    
    	/**
    	 * Fetch the URL to redirect to
    	 *
    	 * @return	\IPS\Http\Url
    	 */
    	public static function getDestination()
    	{
    		/* Try and get a referrer... */
    		try
    		{
    			/* Are we forcing the user to be sent to a specific URL? */
    			if( static::$forcedRedirectUrl !== NULL )
    			{
    				return static::$forcedRedirectUrl;
    			}

    If you're dev you should know what to do

  3.  

    1. Download the HTMLMinifier file HTMLMinifier.php
    2. Include the following code into the php 
    <?php 
      
    // Import the HTMLMinifier 
    require_once 'myfolder/HTMLMinifier.php'; 
      
    // HTML source to be minified 
    $htmlpage = file_get_contents('./mypage.html'); 
      
    // Minified version of the page 
    echo HTMLMinifier::process($htmlpage); 
      
    ?>  

     

    3.Run the php file

     

    or this:

    function Minify_Html($Html)
    {
       $Search = array(
        '/(\n|^)(\x20+|\t)/',
        '/(\n|^)\/\/(.*?)(\n|$)/',
        '/\n/',
        '/\<\!--.*?-->/',
        '/(\x20+|\t)/', # Delete multispace (Without \n)
        '/\>\s+\</', # strip whitespaces between tags
        '/(\"|\')\s+\>/', # strip whitespaces between quotation ("') and end tags
        '/=\s+(\"|\')/'); # strip whitespaces between = "'
    
       $Replace = array(
        "\n",
        "\n",
        " ",
        "",
        " ",
        "><",
        "$1>",
        "=$1");
    
    $Html = preg_replace($Search,$Replace,$Html);
    return $Html;
    }

    or this:

    <?php 
    ob_start("minifier"); 
    function minifier($code) { 
        $search = array( 
              
            // Remove whitespaces after tags 
            '/\>[^\S ]+/s', 
              
            // Remove whitespaces before tags 
            '/[^\S ]+\</s', 
              
            // Remove multiple whitespace sequences 
            '/(\s)+/s', 
              
            // Removes comments 
            '/<!--(.|\s)*?-->/'
        ); 
        $replace = array('>', '<', '\\1'); 
        $code = preg_replace($search, $replace, $code); 
        return $code; 
    } 
    ?> 

     

    HTMLMinifier.php

  4. 1 час назад, Litesm сказал:

    Подскажите пожалуйста как убрать копирайт и ссылку на сайт автора? Это раздел Футер

     

      Скрыть контент

    Снимок экрана 2021-01-20 в 19.05.10.png

     

    Перейти > корен фаш форум > upload > set_resources_6 (6 id тема в админ) , найти   ......_swiper.min.js и отредактировай  

  5. You can create a new group .. for newly registered users, then allow this group to be promoted in the settings ... but not to download ... after a certain number of posts, the user will be automatically moved to another group that has permission to download ... P.S. sorry for the bad translation .. 

    Вы можете создать новую группу .. для недавно зарегистрированных пользователей, а затем разрешить продвижение этой группы в настройках ... но не для загрузки ... после определенного количества сообщений пользователь будет автоматически перемещен в другую группу, в которой разрешение на скачивание ... P.S. извините за плохой перевод ...

    GP1.thumb.png.ef8a613297ad42361993c31e68f78255.png

    GP.thumb.png.74b471f24c52335cf500400b6703e310.png

  6. Или просто измеите и использовать ето код

    {{$firstPage = $baseUrl->setPage( $pageParam );}}
    {{if $activePage > 1 || $pages > 1}}
    	{{$uniqId = mt_rand();}}
    	<ul class='ipsPagination' id='elPagination_{expression="md5($baseUrl)"}_{$uniqId}' data-ipsPagination-seoPagination='{{if $firstPage->seoPagination}}true{{else}}false{{endif}}' data-pages='{$pages}' {{if $ajax and ( theme.ajax_pagination or \IPS\Request::i()->isAjax())}}data-ipsPagination {{if $pageParam != 'page'}}data-ipsPagination-pageParam='{$pageParam}'{{endif}} data-ipsPagination-pages="{$pages}" data-ipsPagination-perPage='{$perPage}'{{endif}}>
    		{{if $simple}}
    			{{if $activePage > 1}}
    				<li class='ipsPagination_prev'><a href='{$baseUrl->setPage( $pageParam, $activePage - 1 )}' rel="prev" data-page='{expression="$activePage - 1"}' data-ipsTooltip title='{lang="prev_page"}'>{lang="prev"}</a></li>
    			{{endif}}
    			{{if $activePage < $pages}}
    				<li class='ipsPagination_next'><a href='{$baseUrl->setPage( $pageParam, $activePage + 1 )}' rel="next" data-page='{expression="$activePage + 1"}' data-ipsTooltip title='{lang="next_page"}'>{lang="next"}</a></li>
    			{{endif}}
    		{{else}}
    			{{if $activePage != 1}}
    				<li class='ipsPagination_first'><a href='{$firstPage}' rel="first" data-page='1' data-ipsTooltip title='{lang="first_page"}'><i class='fa fa-angle-double-left'></i></a></li>
    				<li class='ipsPagination_prev'><a href='{$baseUrl->setPage( $pageParam, $activePage - 1 )}' rel="prev" data-page='{expression="$activePage - 1"}' data-ipsTooltip title='{lang="prev_page"}'>{lang="prev"}</a></li>
    				{{foreach range( ( ( $activePage - 5 ) > 0 ) ? ( $activePage - 5 ) : 1, $activePage - 1 ) as $idx => $i}}
    					<li class='ipsPagination_page'><a href='{$baseUrl->setPage( $pageParam, $i )}' data-page='{$i}'>{$i}</a></li>
    				{{endforeach}}
    			{{else}}
    				<li class='ipsPagination_first ipsPagination_inactive'><a href='{$firstPage}' rel="first" data-page='1' data-ipsTooltip title='{lang="first_page"}'><i class='fa fa-angle-double-left'></i></a></li>
    				<li class='ipsPagination_prev ipsPagination_inactive'><a href='{$baseUrl->setPage( $pageParam, $activePage - 1 )}' rel="prev" data-page='{expression="$activePage - 1"}' data-ipsTooltip title='{lang="prev_page"}'>{lang="prev"}</a></li>
    			{{endif}}
    			<li class='ipsPagination_page ipsPagination_active'><a href='{$baseUrl->setPage( $pageParam, $activePage )}' data-page='{$activePage}'>{$activePage}</a></li>
    			{{if $activePage != $pages}}
    				{{foreach range( $activePage + 1, ( ( $activePage + 5 ) > $pages ) ? $pages : ( $activePage + 5 ) ) as $idx => $i}}
    					<li class='ipsPagination_page'><a href='{$baseUrl->setPage( $pageParam, $i )}' data-page='{$i}'>{$i}</a></li>
    				{{endforeach}}
    				<li class='ipsPagination_next'><a href='{$baseUrl->setPage( $pageParam, $activePage + 1 )}' rel="next" data-page='{expression="$activePage + 1"}' data-ipsTooltip title='{lang="next_page"}'>{lang="next"}</a></li>
    				<li class='ipsPagination_last'><a href='{$baseUrl->setPage( $pageParam, $pages )}' rel="last" data-page='{$pages}' data-ipsTooltip title='{lang="last_page"}'><i class='fa fa-angle-double-right'></i></a></li>
    			{{else}}
    				<li class='ipsPagination_next ipsPagination_inactive'><a href='{$baseUrl->setPage( $pageParam, ( $activePage + 1 > $pages ) ? $pages : $activePage + 1 )}' rel="next" data-page='{expression="( $activePage + 1 > $pages ) ? $pages : $activePage + 1"}' data-ipsTooltip title='{lang="next_page"}'>{lang="next"}</a></li>
    				<li class='ipsPagination_last ipsPagination_inactive'><a href='{$baseUrl->setPage( $pageParam, $pages )}' rel="last" data-page='{$pages}' data-ipsTooltip title='{lang="last_page"}'><i class='fa fa-angle-double-right'></i></a></li>
    			{{endif}}
    			{{if $pages > 1}}
    				<li class='ipsPagination_pageJump'>
    					<a href='#' data-ipsMenu data-ipsMenu-closeOnClick='false' data-ipsMenu-appendTo='#elPagination_{expression="md5($baseUrl)"}_{$uniqId}' id='elPagination_{expression="md5($baseUrl)"}_{$uniqId}_jump'>{lang="pagination" sprintf="$activePage, $pages"} &nbsp;<i class='fa fa-caret-down'></i></a>
    					<div class='ipsMenu ipsMenu_narrow ipsPadding ipsHide' id='elPagination_{expression="md5($baseUrl)"}_{$uniqId}_jump_menu'>
    						<form accept-charset='utf-8' method='post' action='{$baseUrl->setPage( 'page', NULL )}' data-role="pageJump">
    							<ul class='ipsForm ipsForm_horizontal'>
    								<li class='ipsFieldRow'>
    									<input type='number' min='1' max='{$pages}' placeholder='{lang="page_number"}' class='ipsField_fullWidth' name='{$pageParam}'>
    								</li>
    								<li class='ipsFieldRow ipsFieldRow_fullWidth'>
    									<input type='submit' class='ipsButton_fullWidth ipsButton ipsButton_verySmall ipsButton_primary' value='{lang="go"}'>
    								</li>
    							</ul>
    						</form>
    					</div>
    				</li>
    			{{endif}}
    		{{endif}}
    	</ul>
    {{endif}}

     

×
×
  • Создать...