Jump to content
View in the app

A better way to browse. Learn more.

IPBMafia.ru - поддержка Invision Community, релизы, темы, плагины и приложения

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Ruskat

Актив
  • Регистрация

  • В сети

Everything posted by Ruskat

  1. Хоть текстовая инфа понятна +/- немного. А графическая, это уже как дополнение.
  2. Так как было самому интересно, то поделюсь информацией об изменениях со всеми... Взято из ОФ сайта и переведено через гугл. Машинный перевод
  3. Вообще, то это ВВ код, и вставлять его в ВВ-коды нужно. Но вот незадача... Так как тег базируется на Iframe, то и <iframe src="__vk.com/video_ext.php?oid={$content['oid']}&id={$content['id']}&hash={$content['hash']}" width="607" height="360" frameborder="0"></iframe> содержимое будет иметь смысл тока при условии, что в форуме разрешен HTML. Иначе ничего не выведет. А если разрешить HTML, то с этого ВВ-кода нет никакого смысла, потому как HTML-код, а с ним и Iframe, можно вставить и без ВВ-кода. Опробовано на версии 3.3.2.
  4. _Dark_, а что ж ты после изменений не проверял? Я не говорю, что это твоя обязанность. Я имею в виду, что после внесения изменений можно было на локале катнуть на проверку ошибок.
  5. Ну, эт логично. Главное совместимость. А доперевести проблем не составит. А как в нём с дырами и прочими уязвимостями? Если они есть.
  6. А русский язык от 3.3.2 для 3.3.3. не подойдёт?
  7. не стаёт... ну то не смертельно. Так же ещё в папке _config (форум/public/style_images/warrior/_config) есть файлик backgrounds.ini, Я его оформил так: [bg1] thumbnail=auto image=bg1.jpg [bg2] thumbnail=auto image=bg2.jpg [bg3] thumbnail=auto image=bg3.jpg [bg4] thumbnail=auto image=bg4.jpg default=on [bg5] thumbnail=auto image=bg0.jpg [bg6] thumbnail=auto image=bg5.jpg а вот повтор, то он в _php/Platform/Backgrounds.php находится. там нужно параметр { $background['repeat'] = false; } заменить на { $background['repeat'] = true; }[/code] . [/b]и будут повторы. У меня изображение в состоянии position: fixed. так больше нравится... Весь код с изменённым парамеиром: [spoiler] [code] <?php class Platform_Backgrounds { public $selector = '#background'; public $put_your_own = false; public $put_your_own_icon = true; protected $_container_type; protected $_trigger_type; protected $_thumbnails = 100; protected $_output; protected $_css; public function __construct() { $this->_thumbnails = Platform::general()->background_picker_thumb_width(); } public function load_backgrounds() { if( $this->_css !== null || $this->_output !== null ) { return; } $settings = Platform::general()->get_background_elements(); $this->selector = $settings['element']; $backgrounds = Platform::settings('backgrounds'); $selected_bg = Platform::client_preference('background'); $this->_output = array(); if( in_array(substr($selected_bg, 0, 7), array('__', 'https:/')) ) { if( $this->put_your_own === false || !Platform::feature('background_put_your_own') ) { $selected_bg = null; } else { if( !IPSText::xssCheckUrl($selected_bg) ) { $selected_bg = null; } else { $this->_css = $this->selector . ' { background-attachment: fixed; background-image: url(' . $selected_bg . '); }'; } } } foreach( $backgrounds as $id => $background ) { if( isset($background['enabled']) && $background['enabled'] == false ) { continue; } if( in_array(substr($background['image'], 0, 7), array('__', 'https:/')) ) { $url = $background['image']; if( $background['thumbnail'] == 'auto' ) { $path = $background['image']; } } else { $url = '{style_images_url}/_bgs/' . $background['image']; if( $background['thumbnail'] == 'auto' ) { $path = Platform::root() . '../_bgs/' . $background['image']; } } if( !isset($background['repeat']) ) { $background['repeat'] = true; } if( $background['repeat'] ) { $background['repeat'] = 'repeat'; } else { $background['repeat'] = 'no-repeat'; } if( !isset($background['fixed']) ) { $background['fixed'] = false; } if( $background['fixed'] ) { $attachment = 'background-attachment: fixed;'; $background['fixed'] = 'fixed'; } else { $attachment = ''; $background['fixed'] = 'scroll'; } if( (isset($background['default']) && $background['default'] && $selected_bg === null) || (('bg-' . $id) == $selected_bg) ) { $this->_css = $this->selector . ' { background-image: url(' . $url . '); ' . $attachment . ' background-repeat: ' . $background['repeat'] . '; }'; } if( $background['thumbnail'] == 'auto' ) { $thumburl = $this->_thumbnail($path); } else if( in_array(substr($background['thumbnail'], 0, 7), array('__', 'https:/')) ) { $thumburl = $background['thumbnail']; } else { $thumburl = '{style_images_url}/_bgs/' . $background['thumbnail']; } if( $thumburl !== null ) { $thumb = '<img src="' . $thumburl . '" />'; } else { $thumb = ''; } if( isset($background['tip']) ) { $background['tip'] = ' data-tip="' . $background['tip'] . '"'; } else { $background['tip'] = ''; } $this->_output[] = '<a id="bg-' . $id . '" href="' . $url . '" class="select_background" data-background data-background-repeat="' . $background['repeat'] . '" data-background-attachment="' . $background['fixed'] . '"' . $background['tip'] . '>' . $thumb . $background['description'] . '</a>'; } if( $this->put_your_own === true && $this->put_your_own_icon === true && Platform::feature('background_put_your_own') ) { $this->_output[] = '<a id="put-your-own" href="#" class="select_background" data-target-layer="putyourown" data-background data-background-attachment="fixed"><img src="{style_images_url}/_bgs/put_your_own.png" alt="Put your own" /></a>'; } if( !Platform::feature('background_picker') ) { $this->_output = array(); } } public function container_start($trigger_type = 'list-item', $label = 'Backgrounds') { if( $this->_container_type === null ) { $this->_container_type = 'dropdown'; if( Platform::feature('backgrounds_in_dropdown', true) ) { $this->_container_type = 'dropdown'; } else if( Platform::feature('backgrounds_in_balloon', true) ) { $this->_container_type = 'balloon'; } else if( Platform::feature('backgrounds_in_overlay', true) ) { $this->_container_type = 'overlay'; } } $this->_trigger_type = $trigger_type; $output = ''; if( $this->_trigger_type === 'list-item' ) { $output .= '<li id="nav_backgrounds" class="right"'; } else if( $this->_trigger_type === 'anchor' ) { $output .= '<a href="#"'; } if( $this->_container_type === 'dropdown' ) { $output .= ' data-dropdown="right"><span><a href="#">' . $label . '</a></span><ul><li id="ptBackgroundPicker">'; } else if( $this->_container_type === 'balloon' ) { $output .= ' data-target-domballoon="bgpicker"><a href="#">' . $label . '</a>' . ($this->_trigger_type === 'anchor' ? '' : '</li>'); $output .= '<div id="ptBackgroundPicker" data-domballoon="bgpicker"><div>'; } else if( $this->_container_type === 'overlay' ) { $output .= ' data-target-layer="bgpicker"><a href="#">' . $label . '</a>' . ($this->_trigger_type === 'anchor' ? '</a>' : '</li>'); $output .= '<div id="ptBackgroundPicker" data-layer="bgpicker"><div>'; } return $output; } public function container_end() { if( $this->_container_type === 'dropdown' ) { return '</li></ul>' . ($this->_trigger_type === 'anchor' ? '</a>' : '</li>'); } else { return '</div></div>'; } } public function backgrounds() { $this->load_backgrounds(); return $this->_output; } public function css() { $this->load_backgrounds(); return $this->_css; } public function js() { $settings = Platform::general()->get_background_elements(); return 'Platform.getCore().setOption('backgrounds', 'element', '' . $settings['element'] . '' );'; } protected function _thumbnail($path) { if( !file_exists($path) ) { return null; } $cacheKey = md5($path); $cachePath = Platform::root() . '../_cache/switcher.' . md5($path) . '.jpg'; if( file_exists($cachePath) ) { if( substr($path, 0, 4) == 'http' ) { if( (filemtime($cachePath) + (24*3600)) > time() ) { return '{style_images_url}/_cache/switcher.' . $cacheKey . '.jpg'; } } else { if( filemtime($cachePath) >= filemtime($path) ) { return '{style_images_url}/_cache/switcher.' . $cacheKey . '.jpg'; } } } $size = getimagesize($path); if( $size[2] == IMAGETYPE_PNG ) { $image = imagecreatefrompng($path); } else if( $size[2] == IMAGETYPE_GIF ) { $image = imagecreatefromgif($path); } else if( $size[2] == IMAGETYPE_JPEG ) { $image = imagecreatefromjpeg($path); } else { return null; } if( $size[0] < $size[1] ) { $coord = 0; } else { $coord = 1; } $thb = array(); $thb[0] = $this->_thumbnails; $thb[1] = $this->_thumbnails; $k = $size[abs($coord-1)] / $size[$coord]; $new = array(); $new[$coord] = $this->_thumbnails; $new[abs($coord-1)] = $this->_thumbnails * $k; $canvas = imagecreatetruecolor($new[0], $new[1]); imagecopyresampled($canvas, $image, 0, 0, 0, 0, $new[0], $new[1], $size[0], $size[1]); $ratio[0] = ($thb[0] / $new[0]); $ratio[1] = ($thb[1] / $new[1]); $canvas2 = imagecreatetruecolor($thb[0], $thb[1]); if( $new[0] > $new[1] ) { $crop[0] = round($new[0] * $ratio[1]); $crop[1] = $thb[1]; $src[0] = ceil(($new[0] / 2) - ($thb[0] / 2)); $src[1] = 0; } else if( $new[0] < $new[1] ) { $crop[1] = round($new[1] * $ratio[0]); $crop[0] = $thb[0]; $src[0] = 0; $src[1] = ceil(($new[1] / 2) - ($thb[1] / 2)); } else { $crop[0] = $thb[0]; $crop[1] = $thb[1]; $src[0] = 0; $src[1] = 0; } imagecopyresampled($canvas2, $canvas, 0 , 0 , $src[0], $src[1], $crop[0], $crop[1], $new[0], $new[1]); imagejpeg($canvas2, $cachePath); return '{style_images_url}/_cache/switcher.' . $cacheKey . '.jpg'; } } [/code] [/spoiler]
  8. Привет всем.Создал на форуме раздел велоклуба. Создал тока некоторые строки: Н это еще немного далековато от совершенства, как здесь: И результат будет таков:. Для этого использовал Topic Template System. Но мне еще нужно реализовать в нём, чтобы создатель темы при её создании мог выбирать своих друзей, и добавлять нужных в список. Так же нужен вывод календаря с датой и временем. Каким кодом в Topic Template System это можно добавить? Может где какие мануалы есть... Так же ещё нужно еще создать календарь, как здесь: Думаю реализовать его на отдельной странице и парсить, куда нужно.
  9. В globalTemplate нет того содержимого, имеющегося в файле skin_platform_global.php. Или это я не прав? 1 - Там нет вины кэша браузера. Это видимо отладочная строка. Чтобы вставив ссылку на изображение можно было подогнать дизайн. Но если там дописать нужные функции, то возможно будет запоминать на сессию. 2 - У меня оно всеравно одиночное (100х100). В каком параметре CSS это нужно указать?
  10. Файл skin_platform_global.php. Находится в Папке форум/cache/skin_cache/cacheid_**номер папки с кэшем темы
  11. А там ещё есть закомментированный параметр <h3>Or put your own</h3> <div id="putyourown"> <form> <input type="text" class="input_text" size="40" name="url" placeholder="URL of your background..." /> <input type="submit" class="input_submit" value="Set" /> </form> </div> , позволяющий вставить свое фоновое изображение. ТОлько вот дальше одной страницы оно не живёт. Как это изправить? И как установить для маленьких размеров фона повтор по горизонтали и вертикали?

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.