├── README.md ├── _build ├── build.class.php ├── build.transport.php ├── data │ ├── transport.chunks.php │ ├── transport.plugins.php │ ├── transport.snippets.php │ └── transport.templates.php ├── includes │ ├── functions.php │ └── setup.options.php └── resolvers │ ├── resolve.addons.php │ ├── resolve.cache_options.php │ ├── resolve.ckeditor.php │ ├── resolve.client_config.php │ ├── resolve.content_type.php │ ├── resolve.fix_directresize.php │ ├── resolve.fix_fastuploadtv.php │ ├── resolve.fix_file_permissions.php │ ├── resolve.fix_translit.php │ ├── resolve.manager_customisation.php │ ├── resolve.providers.php │ ├── resolve.remove_changelog.php │ ├── resolve.rename_htaccess.php │ ├── resolve.resources.php │ ├── resolve.sample.php │ ├── resolve.set_start_year.php │ ├── resolve.settings.php │ ├── resolve.template.php │ └── resolve.tvs.php ├── assets └── components │ └── site │ ├── bootstrap │ ├── css │ │ ├── bootstrap-theme.css │ │ ├── bootstrap-theme.css.map │ │ ├── bootstrap-theme.min.css │ │ ├── bootstrap-theme.min.css.map │ │ ├── bootstrap.css │ │ ├── bootstrap.css.map │ │ ├── bootstrap.min.css │ │ └── bootstrap.min.css.map │ ├── fonts │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ ├── glyphicons-halflings-regular.woff │ │ └── glyphicons-halflings-regular.woff2 │ └── js │ │ ├── bootstrap.js │ │ ├── bootstrap.min.js │ │ └── npm.js │ ├── fancybox │ └── source │ │ ├── blank.gif │ │ ├── fancybox_loading.gif │ │ ├── fancybox_loading@2x.gif │ │ ├── fancybox_overlay.png │ │ ├── fancybox_sprite.png │ │ ├── fancybox_sprite@2x.png │ │ ├── helpers │ │ ├── fancybox_buttons.png │ │ ├── jquery.fancybox-buttons.css │ │ ├── jquery.fancybox-buttons.js │ │ ├── jquery.fancybox-media.js │ │ ├── jquery.fancybox-thumbs.css │ │ └── jquery.fancybox-thumbs.js │ │ ├── jquery.fancybox.css │ │ ├── jquery.fancybox.js │ │ └── jquery.fancybox.pack.js │ ├── mgr │ └── style.css │ └── web │ ├── img │ ├── favicon.ico │ ├── gal1.jpg │ ├── gal2.jpg │ ├── gal3.jpg │ ├── gal4.jpg │ ├── gal5.jpg │ ├── gal6.jpg │ ├── spec1.png │ ├── spec2.png │ ├── spec3.png │ ├── spec4.png │ └── spec5.png │ ├── js │ └── script.js │ └── vendor │ └── jquery.min.js └── core └── components └── site ├── docs ├── changelog.txt ├── friendly_alias_restrict_chars_pattern.txt ├── license.txt └── readme.txt └── elements ├── chunks ├── chunk.aside.html ├── chunk.block_gallery.html ├── chunk.child_list.html ├── chunk.contact_form.html ├── chunk.content.html ├── chunk.content_default.html ├── chunk.content_main.html ├── chunk.content_spec.html ├── chunk.content_spec_list.html ├── chunk.footer.html ├── chunk.form_contact_form.html ├── chunk.gallery.html ├── chunk.head.html ├── chunk.header.html ├── chunk.menu.html ├── chunk.scripts.html └── chunk.tpl_contact_form.html ├── plugins ├── plugin.addmanagercss.php ├── plugin.convertbase64images.php └── plugin.siteredirect.php ├── snippets └── snippet.rtrim.php └── templates └── template.sitetemplate.html /README.md: -------------------------------------------------------------------------------- 1 | # siteExtra 2 | 3 | Заготовка для разработки сайтов на MODX -------------------------------------------------------------------------------- /_build/build.class.php: -------------------------------------------------------------------------------- 1 | 'site', 7 | 'PACKAGE_VERSION' => '1.0.0', 8 | 'PACKAGE_RELEASE' => 'beta', 9 | 'BUILD_RESOLVERS' => array() 10 | ); 11 | public $category_attr = array(); 12 | public $modx; 13 | 14 | public function __construct($PACKAGE_NAME, $PACKAGE_VERSION, $PACKAGE_RELEASE, $BUILD_RESOLVERS, $ADDONS) { 15 | if (!empty($PACKAGE_NAME)) { 16 | $this->config['PACKAGE_NAME'] = $PACKAGE_NAME; 17 | } 18 | if (!empty($PACKAGE_VERSION)) { 19 | $this->config['PACKAGE_VERSION'] = $PACKAGE_VERSION; 20 | } 21 | if (!empty($PACKAGE_RELEASE)) { 22 | $this->config['PACKAGE_RELEASE'] = $PACKAGE_RELEASE; 23 | } 24 | if (!empty($BUILD_RESOLVERS) || is_array($BUILD_RESOLVERS)) { 25 | $this->config['BUILD_RESOLVERS'] = $BUILD_RESOLVERS; 26 | } 27 | if (!empty($ADDONS) || is_array($ADDONS)) { 28 | $this->config['ADDONS'] = $ADDONS; 29 | } 30 | } 31 | 32 | public function build() { 33 | set_time_limit(0); 34 | header('Content-Type:text/html;charset=utf-8'); 35 | 36 | $builder = $this->prepareBuilder(); 37 | $vehicle = $this->prepareVehicle($builder); 38 | $this->pack($builder); 39 | } 40 | 41 | public function prepareBuilder() { 42 | /* define paths */ 43 | $this->config['PACKAGE_ROOT'] = dirname(dirname(__FILE__)) . '/'; 44 | if (file_exists(dirname(dirname(dirname(__FILE__))) . '/core')) { 45 | $this->config['MODX_BASE_PATH'] = dirname($this->config['PACKAGE_ROOT']) . '/'; 46 | } else { 47 | $this->config['MODX_BASE_PATH'] = dirname(dirname($this->config['PACKAGE_ROOT'])) . '/'; 48 | } 49 | 50 | $this->renameDirs(); 51 | 52 | /* modx connection */ 53 | define('MODX_API_MODE', true); 54 | require $this->config['MODX_BASE_PATH'] . 'index.php'; 55 | require $this->config['PACKAGE_ROOT'] . '_build/includes/functions.php'; 56 | $this->modx = &$modx; 57 | $this->modx->setLogLevel(modX::LOG_LEVEL_INFO); 58 | $this->modx->setLogTarget('ECHO'); 59 | $this->modx->getService('error', 'error.modError'); 60 | $this->modx->loadClass('transport.modPackageBuilder', '', false, true); 61 | if (!XPDO_CLI_MODE) { 62 | echo '
';
 63 |         }
 64 |         
 65 |         /* create builder */
 66 |         $builder = new modPackageBuilder($this->modx);
 67 |         $builder->createPackage(strtolower($this->config['PACKAGE_NAME']),
 68 |                                 $this->config['PACKAGE_VERSION'],
 69 |                                 $this->config['PACKAGE_RELEASE']);
 70 |         $this->modx->log(modX::LOG_LEVEL_INFO, 'Created Transport Package.');
 71 |         return $builder;
 72 |     }
 73 |     
 74 |     public function renameDirs() {
 75 |         /* assets */
 76 |         $assets_dir = $this->config['PACKAGE_ROOT'] . 'assets/components/' . strtolower($this->config['PACKAGE_NAME']);
 77 |         $assets_old = $this->config['PACKAGE_ROOT'] . 'assets/components/site';
 78 |         if (!file_exists($assets_dir) &&
 79 |             file_exists($assets_old)) {
 80 |             rename($assets_old, $assets_dir);
 81 |         }
 82 |         
 83 |         /* core */
 84 |         $core_dir = $this->config['PACKAGE_ROOT'] . 'core/components/' . strtolower($this->config['PACKAGE_NAME']);
 85 |         $core_old = $this->config['PACKAGE_ROOT'] . 'core/components/site';
 86 |         if (!file_exists($core_dir) &&
 87 |             file_exists($core_old)) {
 88 |             rename($core_old, $core_dir);
 89 |         }
 90 |     }
 91 |     
 92 |     public function prepareVehicle(&$builder) {
 93 |         /* create category */
 94 |         $this->modx->log(xPDO::LOG_LEVEL_INFO, 'Created category.');
 95 |         $category = $this->modx->newObject('modCategory');
 96 |         $category->set('category', $this->config['PACKAGE_NAME']);
 97 |         
 98 |         $this->category_attr[xPDOTransport::UNIQUE_KEY] = 'category';
 99 |         $this->category_attr[xPDOTransport::PRESERVE_KEYS] = false;
100 |         $this->category_attr[xPDOTransport::UPDATE_OBJECT] = true;
101 |         $this->category_attr[xPDOTransport::RELATED_OBJECTS] = true;
102 |         
103 |         $this->addPlugins($category);
104 |         $this->addSnippets($category);
105 |         $this->addTemplates($category);
106 |         $this->addChunks($category);
107 |         
108 |         $builder->setPackageAttributes(array(
109 |             'site_category' => $this->config['PACKAGE_NAME'],
110 |             'site_template_name' => $this->config['site_template_name'],
111 |             'ADDONS' => $this->config['ADDONS']
112 |         ));
113 |         $vehicle = $builder->createVehicle($category, $this->category_attr);
114 |         $this->addResolvers($vehicle);
115 |         $builder->putVehicle($vehicle);
116 |         return $vehicle;
117 |     }
118 |     
119 |     public function addPlugins(&$category) {
120 |         $this->category_attr[xPDOTransport::RELATED_OBJECT_ATTRIBUTES]['Plugins'] = array(
121 |             xPDOTransport::PRESERVE_KEYS => false,
122 |             xPDOTransport::UPDATE_OBJECT => false,
123 |             xPDOTransport::UNIQUE_KEY => 'name',
124 |         );
125 |         $this->category_attr[xPDOTransport::RELATED_OBJECT_ATTRIBUTES]['PluginEvents'] = array(
126 |             xPDOTransport::PRESERVE_KEYS => true,
127 |             xPDOTransport::UPDATE_OBJECT => false,
128 |             xPDOTransport::UNIQUE_KEY => array('pluginid', 'event'),
129 |         );
130 |         $modx = &$this->modx;
131 |         $plugins = include $this->config['PACKAGE_ROOT'] . '_build/data/transport.plugins.php';
132 |         if (!is_array($plugins)) {
133 |             $this->modx->log(modX::LOG_LEVEL_ERROR, 'Could not package in plugins.');
134 |         } else {
135 |             $category->addMany($plugins);
136 |             $this->modx->log(modX::LOG_LEVEL_INFO, 'Packaged in ' . count($plugins) . ' plugins.');
137 |         }
138 |     }
139 |     
140 |     public function addSnippets(&$category) {
141 |         $this->category_attr[xPDOTransport::RELATED_OBJECT_ATTRIBUTES]['Snippets'] = array(
142 |             xPDOTransport::PRESERVE_KEYS => false,
143 |             xPDOTransport::UPDATE_OBJECT => false,
144 |             xPDOTransport::UNIQUE_KEY => 'name',
145 |         );
146 |         $modx = &$this->modx;
147 |         $snippets = include $this->config['PACKAGE_ROOT'] . '_build/data/transport.snippets.php';
148 |         if (!is_array($snippets)) {
149 |             $this->modx->log(modX::LOG_LEVEL_ERROR, 'Could not package in snippets.');
150 |         } else {
151 |             $category->addMany($snippets);
152 |             $this->modx->log(modX::LOG_LEVEL_INFO, 'Packaged in ' . count($snippets) . ' snippets.');
153 |         }
154 |     }
155 |     
156 |     public function addTemplates(&$category) {
157 |         $this->category_attr[xPDOTransport::RELATED_OBJECT_ATTRIBUTES]['Templates'] = array(
158 |             xPDOTransport::PRESERVE_KEYS => false,
159 |             xPDOTransport::UPDATE_OBJECT => false,
160 |             xPDOTransport::UNIQUE_KEY => 'templatename',
161 |         );
162 |         $modx = &$this->modx;
163 |         $templates = include $this->config['PACKAGE_ROOT'] . '_build/data/transport.templates.php';
164 |         if (!is_array($templates)) {
165 |             $this->modx->log(modX::LOG_LEVEL_ERROR, 'Could not package in templates.');
166 |         } else {
167 |             $category->addMany($templates);
168 |             $this->modx->log(modX::LOG_LEVEL_INFO, 'Packaged in ' . count($templates) . ' templates.');
169 |             $this->config['site_template_name'] = $this->config['PACKAGE_NAME'];
170 |         }
171 |     }
172 |     
173 |     public function addChunks(&$category) {
174 |         $this->category_attr[xPDOTransport::RELATED_OBJECT_ATTRIBUTES]['Chunks'] = array(
175 |             xPDOTransport::PRESERVE_KEYS => false,
176 |             xPDOTransport::UPDATE_OBJECT => false,
177 |             xPDOTransport::UNIQUE_KEY => 'name',
178 |         );
179 |         $modx = &$this->modx;
180 |         $chunks = include $this->config['PACKAGE_ROOT'] . '_build/data/transport.chunks.php';
181 |         if (!is_array($chunks)) {
182 |             $this->modx->log(modX::LOG_LEVEL_ERROR, 'Could not package in chunks.');
183 |         } else {
184 |             $category->addMany($chunks);
185 |             $this->modx->log(modX::LOG_LEVEL_INFO, 'Packaged in ' . count($chunks) . ' chunks.');
186 |         }
187 |     }
188 |     
189 |     public function addResolvers(&$vehicle) {
190 |         /* now pack in resolvers */
191 |         $vehicle->resolve('file', array(
192 |         	'source' => $this->config['PACKAGE_ROOT'] . 'assets/components/' . strtolower($this->config['PACKAGE_NAME']),
193 |         	'target' => "return MODX_ASSETS_PATH . 'components/';",
194 |         ));
195 |         $vehicle->resolve('file', array(
196 |         	'source' => $this->config['PACKAGE_ROOT'] . 'core/components/' . strtolower($this->config['PACKAGE_NAME']),
197 |         	'target' => "return MODX_CORE_PATH . 'components/';",
198 |         ));
199 |         foreach ($this->config['BUILD_RESOLVERS'] as $resolver) {
200 |         	if ($vehicle->resolve('php', array('source' => $this->config['PACKAGE_ROOT'] . '_build/resolvers/' . 'resolve.' . $resolver . '.php'))) {
201 |         		$this->modx->log(modX::LOG_LEVEL_INFO, 'Added resolver "' . $resolver . '" to category.');
202 |         	}
203 |         	else {
204 |         		$this->modx->log(modX::LOG_LEVEL_INFO, 'Could not add resolver "' . $resolver . '" to category.');
205 |         	}
206 |         }
207 |         
208 |         flush();
209 |     }
210 |     
211 |     public function pack(&$builder) {
212 |         /* now pack in the license file, readme and setup options */
213 |         $builder->setPackageAttributes(array(
214 |         	'changelog' => file_get_contents($this->config['PACKAGE_ROOT'] . 'core/components/' . strtolower($this->config['PACKAGE_NAME']) . '/docs/' . 'changelog.txt'),
215 |         	'license' => file_get_contents($this->config['PACKAGE_ROOT'] . 'core/components/' . strtolower($this->config['PACKAGE_NAME']) . '/docs/' . 'license.txt'),
216 |         	'readme' => file_get_contents($this->config['PACKAGE_ROOT'] . 'core/components/' . strtolower($this->config['PACKAGE_NAME']) . '/docs/' . 'readme.txt'),
217 |         	'setup-options' => array(
218 |                 'source' => $this->config['PACKAGE_ROOT'] . '_build/includes/setup.options.php',
219 |         	),
220 |         ));
221 |         $this->modx->log(modX::LOG_LEVEL_INFO, 'Added package attributes.');
222 |         
223 |         /* zip up package */
224 |         $this->modx->log(modX::LOG_LEVEL_INFO, 'Packing up transport package zip...');
225 |         $builder->pack();
226 |         
227 |         $signature = $builder->getSignature();
228 |         if (!empty($_GET['download'])) {
229 |         	echo '';
230 |         }
231 |         
232 |         $this->modx->log(modX::LOG_LEVEL_INFO, "Done.\n
Completed\n"); 233 | if (!XPDO_CLI_MODE) { 234 | echo '
'; 235 | } 236 | } 237 | } 238 | return 'siteBuilder'; 239 | -------------------------------------------------------------------------------- /_build/build.transport.php: -------------------------------------------------------------------------------- 1 | '', 'packages' => array( 22 | 'simpleUpdater' => '2.1.4-rc', 23 | 'FormIt' => '4.2.1-pl', 24 | 'CKEditor' => '1.4.0-pl', 25 | 'ClientConfig' => '2.1.0-pl', 26 | 'TinyMCE Rich Text Editor' => '1.2.1-pl', 27 | 'Collections' => '3.6.0-pl', 28 | 'Console' => '2.2.2-pl', 29 | 'MIGX' => '2.12.0-pl', 30 | 'translit' => '1.0.0-beta', 31 | 'VersionX' => '2.2.1-pl', 32 | 'SmushIt' => '1.0.0-beta' 33 | )), 34 | array('name' => 'modstore.pro', 'packages' => array( 35 | 'Ace' => '1.8.0-pl', 36 | 'autoRedirector' => '1.0.0-rc', 37 | 'pdoTools' => '2.12.1-pl', 38 | 'AjaxForm' => '1.1.9-pl', 39 | 'MinifyX' => '1.7.0-pl', 40 | 'phpThumbOn' => '1.3.5-beta', 41 | 'tagElementPlugin' => '1.3.0-pl', 42 | 'frontendManager' => '1.1.1-beta', 43 | 'FastUploadTV' => '1.0.1-pl', 44 | 'logRotation' => '1.0.0-beta', 45 | 'controlErrorLog' => '1.3.1-pl' 46 | )), 47 | ); 48 | $builder = new siteBuilder('site', '1.5.3', 'pl', $resolvers, $addons); 49 | $builder->build(); 50 | -------------------------------------------------------------------------------- /_build/data/transport.chunks.php: -------------------------------------------------------------------------------- 1 | modx */ 3 | /** @var array $sources */ 4 | 5 | $chunks = array(); 6 | 7 | $tmp = array( 8 | 'head' => array( 9 | 'file' => 'head', 10 | 'description' => '' 11 | ), 12 | 'menu' => array( 13 | 'file' => 'menu', 14 | 'description' => '' 15 | ), 16 | 'child_list' => array( 17 | 'file' => 'child_list', 18 | 'description' => '' 19 | ), 20 | 'header' => array( 21 | 'file' => 'header', 22 | 'description' => '' 23 | ), 24 | 'content' => array( 25 | 'file' => 'content', 26 | 'description' => '' 27 | ), 28 | 'content_default' => array( 29 | 'file' => 'content_default', 30 | 'description' => '' 31 | ), 32 | 'content_main' => array( 33 | 'file' => 'content_main', 34 | 'description' => '' 35 | ), 36 | 'content_spec' => array( 37 | 'file' => 'content_spec', 38 | 'description' => '' 39 | ), 40 | 'content_spec_list' => array( 41 | 'file' => 'content_spec_list', 42 | 'description' => '' 43 | ), 44 | 'aside' => array( 45 | 'file' => 'aside', 46 | 'description' => '' 47 | ), 48 | 'footer' => array( 49 | 'file' => 'footer', 50 | 'description' => '' 51 | ), 52 | 'contact_form' => array( 53 | 'file' => 'contact_form', 54 | 'description' => '' 55 | ), 56 | 'form.contact_form' => array( 57 | 'file' => 'form_contact_form', 58 | 'description' => '' 59 | ), 60 | 'tpl.contact_form' => array( 61 | 'file' => 'tpl_contact_form', 62 | 'description' => '' 63 | ), 64 | 'gallery' => array( 65 | 'file' => 'gallery', 66 | 'description' => '' 67 | ), 68 | 'block.gallery' => array( 69 | 'file' => 'block_gallery', 70 | 'description' => '' 71 | ), 72 | 'scripts' => array( 73 | 'file' => 'scripts', 74 | 'description' => '' 75 | ), 76 | ); 77 | $setted = false; 78 | foreach ($tmp as $k => $v) { 79 | 80 | /** @var modchunk $chunk */ 81 | $chunk = $this->modx->newObject('modChunk'); 82 | $chunk->fromArray(array( 83 | 'name' => $k, 84 | 'category' => 0, 85 | 'description' => @$v['description'], 86 | 'content' => file_get_contents($this->config['PACKAGE_ROOT'] . 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/chunks/chunk.' . $v['file'] . '.html'), 87 | 'static' => false, 88 | //'source' => 1, 89 | //'static_file' => 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/chunks/chunk.' . $v['file'] . '.html', 90 | ), '', true, true); 91 | $chunks[] = $chunk; 92 | } 93 | unset($tmp, $properties); 94 | 95 | return $chunks; -------------------------------------------------------------------------------- /_build/data/transport.plugins.php: -------------------------------------------------------------------------------- 1 | modx */ 3 | /** @var array $sources */ 4 | 5 | $plugins = array(); 6 | 7 | $tmp = array( 8 | 'addManagerCss' => array( 9 | 'file' => 'addmanagercss', 10 | 'description' => '', 11 | 'events' => array( 12 | 'OnManagerPageInit' => array() 13 | ) 14 | ), 15 | 'siteRedirect' => array( 16 | 'file' => 'siteredirect', 17 | 'description' => '', 18 | 'events' => array( 19 | 'OnHandleRequest' => array() 20 | ) 21 | ), 22 | 'convertBase64Images' => array( 23 | 'file' => 'convertbase64images', 24 | 'description' => '', 25 | 'events' => array( 26 | 'OnDocFormSave' => array() 27 | ) 28 | ) 29 | ); 30 | 31 | foreach ($tmp as $k => $v) { 32 | /** @var modplugin $plugin */ 33 | $plugin = $this->modx->newObject('modPlugin'); 34 | $plugin->fromArray(array( 35 | 'name' => $k, 36 | 'category' => 0, 37 | 'disabled' => $k == 'siteRedirect' ? 1 : 0, 38 | 'description' => @$v['description'], 39 | 'plugincode' => getSnippetContent($this->config['PACKAGE_ROOT'] . 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/plugins/plugin.' . $v['file'] . '.php'), 40 | 'static' => false, 41 | //'source' => 1, 42 | //'static_file' => 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/plugins/plugin.' . $v['file'] . '.php', 43 | ), '', true, true); 44 | 45 | $events = array(); 46 | if (!empty($v['events'])) { 47 | foreach ($v['events'] as $k2 => $v2) { 48 | /** @var modPluginEvent $event */ 49 | $event = $this->modx->newObject('modPluginEvent'); 50 | $event->fromArray(array_merge( 51 | array( 52 | 'event' => $k2, 53 | 'priority' => 0, 54 | 'propertyset' => 0, 55 | ), $v2 56 | ), '', true, true); 57 | $events[] = $event; 58 | } 59 | unset($v['events']); 60 | } 61 | 62 | if (!empty($events)) { 63 | $plugin->addMany($events); 64 | } 65 | $plugins[] = $plugin; 66 | } 67 | unset($tmp, $properties); 68 | 69 | return $plugins; -------------------------------------------------------------------------------- /_build/data/transport.snippets.php: -------------------------------------------------------------------------------- 1 | modx */ 3 | /** @var array $sources */ 4 | 5 | $snippets = array(); 6 | 7 | $tmp = array( 8 | 'rtrim' => array( 9 | 'file' => 'rtrim', 10 | 'description' => '' 11 | ), 12 | ); 13 | 14 | foreach ($tmp as $k => $v) { 15 | /** @var modsnippet $snippet */ 16 | $snippet = $this->modx->newObject('modSnippet'); 17 | $snippet->fromArray(array( 18 | 'name' => $k, 19 | 'category' => 0, 20 | 'description' => @$v['description'], 21 | 'snippet' => getSnippetContent($this->config['PACKAGE_ROOT'] . 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/snippets/snippet.' . $v['file'] . '.php'), 22 | 'static' => false, 23 | //'source' => 1, 24 | //'static_file' => 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/snippets/snippet.' . $v['file'] . '.php', 25 | ), '', true, true); 26 | 27 | $snippets[] = $snippet; 28 | } 29 | unset($tmp, $properties); 30 | 31 | return $snippets; 32 | -------------------------------------------------------------------------------- /_build/data/transport.templates.php: -------------------------------------------------------------------------------- 1 | modx */ 3 | /** @var array $sources */ 4 | 5 | $templates = array(); 6 | 7 | $tmp = array( 8 | $this->config['PACKAGE_NAME'] => array( 9 | 'file' => 'sitetemplate', 10 | 'description' => '' 11 | ) 12 | ); 13 | $setted = false; 14 | foreach ($tmp as $k => $v) { 15 | 16 | /** @var modtemplate $template */ 17 | $template = $this->modx->newObject('modTemplate'); 18 | $template->fromArray(array( 19 | 'templatename' => $k, 20 | 'category' => 0, 21 | 'description' => @$v['description'], 22 | 'content' => file_get_contents($this->config['PACKAGE_ROOT'] . 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/templates/template.' . $v['file'] . '.html'), 23 | 'static' => false, 24 | //'source' => 1, 25 | //'static_file' => 'core/components/'.strtolower($this->config['PACKAGE_NAME']).'/elements/templates/template.' . $v['file'] . '.html', 26 | ), '', true, true); 27 | $templates[] = $template; 28 | } 29 | unset($tmp, $properties); 30 | 31 | return $templates; -------------------------------------------------------------------------------- /_build/includes/functions.php: -------------------------------------------------------------------------------- 1 | ')); 14 | } 15 | 16 | 17 | /** 18 | * Recursive directory remove 19 | * 20 | * @param $dir 21 | */ 22 | function rrmdir($dir) 23 | { 24 | if (is_dir($dir)) { 25 | $objects = scandir($dir); 26 | 27 | foreach ($objects as $object) { 28 | if ($object != "." && $object != "..") { 29 | if (filetype($dir . "/" . $object) == "dir") { 30 | rrmdir($dir . "/" . $object); 31 | } else { 32 | unlink($dir . "/" . $object); 33 | } 34 | } 35 | } 36 | reset($objects); 37 | rmdir($dir); 38 | } 39 | } -------------------------------------------------------------------------------- /_build/includes/setup.options.php: -------------------------------------------------------------------------------- 1 | $addons) { 11 | if (isset($addons['packages']) && !empty($addons['packages'])) { 12 | foreach($addons['packages'] as $k => $v) { 13 | $checkboxes[] = $k; 14 | } 15 | } 16 | } 17 | sort($checkboxes, SORT_NATURAL | SORT_FLAG_CASE); 18 | $chunks = ''; 55 | } 56 | break; 57 | 58 | case xPDOTransport::ACTION_UPGRADE: 59 | break; 60 | 61 | case xPDOTransport::ACTION_UNINSTALL: 62 | break; 63 | } 64 | 65 | $output = ''; 66 | if ($chunks) { 67 | 68 | switch ($modx->getOption('cultureKey')) { 69 | case 'ru': 70 | $output .= 'Выберите дополнения, которые нужно установить:
71 | 72 | отметить все | 73 | cнять отметки 74 | 75 | '; 76 | break; 77 | default: 78 | $output .= 'Select addons, which need to install:
79 | 80 | select all | 81 | deselect all 82 | 83 | '; 84 | } 85 | 86 | $output .= $chunks; 87 | } 88 | return $output; -------------------------------------------------------------------------------- /_build/resolvers/resolve.addons.php: -------------------------------------------------------------------------------- 1 | getObject('transport.modTransportProvider', array('service_url:LIKE' => '%' . $provider_name . '%'))) { 9 | $provider = $modx->getObject('transport.modTransportProvider', 1); 10 | } 11 | 12 | $modx->getVersionData(); 13 | $productVersion = $modx->version['code_name'] . '-' . $modx->version['full_version']; 14 | 15 | $response = $provider->request('package', 'GET', array( 16 | 'supports' => $productVersion, 17 | 'query' => $packageName 18 | )); 19 | 20 | if (!empty($response)) { 21 | $foundPackages = simplexml_load_string($response->response); 22 | foreach ($foundPackages as $foundPackage) { 23 | /* @var modTransportPackage $foundPackage */ 24 | if ($foundPackage->name == $packageName) { 25 | $sig = explode('-', $foundPackage->signature); 26 | $versionSignature = explode('.', $sig[1]); 27 | $url = $foundPackage->location; 28 | 29 | if (!downloadPackage($url, $modx->getOption('core_path') . 'packages/' . $foundPackage->signature . '.transport.zip')) { 30 | return array( 31 | 'success' => 0, 32 | 'message' => "Could not download package {$packageName}.", 33 | ); 34 | } 35 | 36 | /* add in the package as an object so it can be upgraded */ 37 | /** @var modTransportPackage $package */ 38 | $package = $modx->newObject('transport.modTransportPackage'); 39 | $package->set('signature', $foundPackage->signature); 40 | $package->fromArray(array( 41 | 'created' => date('Y-m-d h:i:s'), 42 | 'updated' => null, 43 | 'state' => 1, 44 | 'workspace' => 1, 45 | 'provider' => $provider->id, 46 | 'source' => $foundPackage->signature . '.transport.zip', 47 | 'package_name' => $packageName, 48 | 'version_major' => $versionSignature[0], 49 | 'version_minor' => !empty($versionSignature[1]) ? $versionSignature[1] : 0, 50 | 'version_patch' => !empty($versionSignature[2]) ? $versionSignature[2] : 0, 51 | )); 52 | 53 | if (!empty($sig[2])) { 54 | $r = preg_split('/([0-9]+)/', $sig[2], -1, PREG_SPLIT_DELIM_CAPTURE); 55 | if (is_array($r) && !empty($r)) { 56 | $package->set('release', $r[0]); 57 | $package->set('release_index', (isset($r[1]) ? $r[1] : '0')); 58 | } 59 | else { 60 | $package->set('release', $sig[2]); 61 | } 62 | } 63 | 64 | if ($package->save() && $package->install()) { 65 | return array( 66 | 'success' => 1, 67 | 'message' => "{$packageName} was successfully installed", 68 | ); 69 | } 70 | else { 71 | return array( 72 | 'success' => 0, 73 | 'message' => "Could not save package {$packageName}", 74 | ); 75 | } 76 | break; 77 | } 78 | } 79 | } 80 | else { 81 | return array( 82 | 'success' => 0, 83 | 'message' => "Could not find {$packageName} in MODX repository", 84 | ); 85 | } 86 | return true; 87 | } 88 | } 89 | 90 | if (!function_exists('downloadPackage')) { 91 | function downloadPackage($src, $dst) { 92 | if (ini_get('allow_url_fopen')) { 93 | $file = @file_get_contents($src); 94 | } 95 | else { 96 | if (function_exists('curl_init')) { 97 | $ch = curl_init(); 98 | curl_setopt($ch, CURLOPT_URL, $src); 99 | curl_setopt($ch, CURLOPT_HEADER, 0); 100 | curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); 101 | curl_setopt($ch, CURLOPT_TIMEOUT, 180); 102 | $safeMode = @ini_get('safe_mode'); 103 | $openBasedir = @ini_get('open_basedir'); 104 | if (empty($safeMode) && empty($openBasedir)) { 105 | curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); 106 | } 107 | 108 | $file = curl_exec($ch); 109 | curl_close($ch); 110 | } 111 | else { 112 | return false; 113 | } 114 | } 115 | file_put_contents($dst, $file); 116 | 117 | return file_exists($dst); 118 | } 119 | } 120 | 121 | 122 | $success = false; 123 | switch (@$options[xPDOTransport::PACKAGE_ACTION]) { 124 | case xPDOTransport::ACTION_INSTALL: 125 | case xPDOTransport::ACTION_UPGRADE: 126 | /* @var modX $modx */ 127 | $modx = &$object->xpdo; 128 | /* Checking and installing required packages */ 129 | $providers = $options['ADDONS']; 130 | 131 | foreach ($providers as $provider) { 132 | foreach ($provider['packages'] as $package_name => $version) { 133 | if (!in_array($package_name, $options['install_addons'])) continue; 134 | $installed = $modx->getIterator('transport.modTransportPackage', array('package_name' => $package_name)); 135 | /** @var modTransportPackage $package */ 136 | foreach ($installed as $package) { 137 | if ($package->compareVersion($version, '<=')) { 138 | continue(2); 139 | } 140 | } 141 | $modx->log(modX::LOG_LEVEL_INFO, "Trying to install {$package_name}. Please wait..."); 142 | $response = installPackage($package_name, $provider['name']); 143 | $level = $response['success'] 144 | ? modX::LOG_LEVEL_INFO 145 | : modX::LOG_LEVEL_ERROR; 146 | $modx->log($level, $response['message']); 147 | } 148 | } 149 | 150 | $success = true; 151 | break; 152 | 153 | case xPDOTransport::ACTION_UNINSTALL: 154 | $success = true; 155 | break; 156 | } 157 | 158 | return $success; -------------------------------------------------------------------------------- /_build/resolvers/resolve.cache_options.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $file = $modx->getOption('core_path') . 'config/' . MODX_CONFIG_KEY.'.inc.php'; 8 | 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (file_exists($file)) { 13 | $content = file_get_contents($file); 14 | if (strpos($content, 'cache_handler') === false) { 15 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Cache options'); 16 | $fp = fopen($file, "w"); 17 | $prefix = substr(md5(time()), 0, 8) . '_'; 18 | $_SESSION['setting_cache_prefix'] = $prefix; 19 | $content = str_replace( 20 | '$config_options = array ('. PHP_EOL .');', 21 | 22 | '$config_options = array ('. PHP_EOL . 23 | '//"cache_prefix" => "' . $prefix . '",'. PHP_EOL . 24 | '//"cache_handler" => "cache.xPDOMemCached"' . PHP_EOL . 25 | ');', 26 | 27 | $content); 28 | fwrite($fp, $content); 29 | fclose($fp); 30 | } 31 | } 32 | break; 33 | 34 | case xPDOTransport::ACTION_UNINSTALL: 35 | break; 36 | } 37 | } 38 | return true; 39 | -------------------------------------------------------------------------------- /_build/resolvers/resolve.ckeditor.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | case xPDOTransport::ACTION_UPGRADE: 10 | if (!in_array('CKEditor', $options['install_addons'])) return true; 11 | 12 | $path = MODX_MANAGER_PATH . 'assets/components/ckeditor/ckeditor/plugins/'; 13 | $file = 'base64image.zip'; 14 | 15 | if (!file_exists($path . 'base64image')) { 16 | $modx->log(modX::LOG_LEVEL_INFO, 'Run CKEditor setup'); 17 | if (!file_exists($path . $file)) { 18 | $contents = file_get_contents('https://github.com/nmmf/base64image/archive/master.zip'); 19 | file_put_contents($path . $file, $contents); 20 | } 21 | 22 | $zip = new ZipArchive; 23 | $res = $zip->open($path . $file); 24 | if ($res === TRUE) { 25 | $zip->extractTo($path); 26 | $zip->close(); 27 | if (file_exists($path . 'base64image-master')) { 28 | rename($path . 'base64image-master', $path . 'base64image'); 29 | } 30 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'ckeditor.toolbar'))) { 31 | $tmp = $modx->newObject('modSystemSetting'); 32 | } 33 | $tmp->fromArray(array( 34 | 'namespace' => 'ckeditor', 35 | 'area' => 'general', 36 | 'xtype' => 'textfield', 37 | 'value' => '[["Source"],["Bold","Italic","Underline","Striketrough","Subscript","Superscript"],["NumberedList","BulletedList","Blockquote"],["JustifyLeft","JustifyCenter","JustifyRight"],["Link","Unlink"],["base64image","Table","HorizontalRule"],["Format","TextColor","Maximize"]]', 38 | 'key' => 'ckeditor.toolbar', 39 | ), '', true, true); 40 | $tmp->save(); 41 | 42 | $plugins = ['base64image']; 43 | if ($tmp = $modx->getObject('modSystemSetting', array('key' => 'ckeditor.extra_plugins'))) { 44 | if ($tmp->get('value')) { 45 | $value = explode(',', $tmp->get('value')); 46 | if (!empty($value)) { 47 | $plugins = array_unique(array_merge($value, $plugins)); 48 | } 49 | } 50 | } 51 | $tmp->fromArray(array( 52 | 'namespace' => 'ckeditor', 53 | 'area' => 'general', 54 | 'xtype' => 'textfield', 55 | 'value' => implode(',', $plugins), 56 | 'key' => 'ckeditor.extra_plugins', 57 | ), '', true, true); 58 | $tmp->save(); 59 | } 60 | } 61 | break; 62 | 63 | case xPDOTransport::ACTION_UNINSTALL: 64 | break; 65 | } 66 | } 67 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.client_config.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | case xPDOTransport::ACTION_UPGRADE: 10 | $path = $modx->getOption('clientconfig.core_path', null, $modx->getOption('core_path') . 'components/clientconfig/'); 11 | $path .= 'model/clientconfig/'; 12 | $clientConfig = $modx->getService('clientconfig','ClientConfig', $path); 13 | 14 | if ($clientConfig instanceof ClientConfig) { 15 | if (!$groups = $modx->getCollection('cgGroup')) { 16 | $modx->log(modX::LOG_LEVEL_INFO, 'Run client_config resolver'); 17 | $group = $modx->newObject('cgGroup'); 18 | if ($modx->getOption('cultureKey') == 'ru') { 19 | $group->set('label', 'Контактная информация'); 20 | } else { 21 | $group->set('label', 'Contacts'); 22 | } 23 | $group->set('description', ''); 24 | $group->save(); 25 | 26 | 27 | if ($modx->getOption('cultureKey') == 'ru') { 28 | $settings = [ 29 | ['key' => 'address', 'label' => 'Адрес', 'value' => 'г. Москва, ул. Печатников, д. 17, оф. 350'], 30 | ['key' => 'phone', 'label' => 'Телефон', 'value' => '+7 (499) 150-22-22'], 31 | ['key' => 'email', 'label' => 'E-mail', 'value' => 'info@company.ru'], 32 | ['key' => 'emailto', 'label' => 'E-mail для заявок', 'value' => $modx->getOption('emailsender')], 33 | ]; 34 | } else { 35 | $settings = [ 36 | ['key' => 'address', 'label' => 'Address', 'value' => '6358 Belmont St Hamtramck, MI 48212, USA'], 37 | ['key' => 'phone', 'label' => 'Phone', 'value' => '+1 313-150-2222'], 38 | ['key' => 'email', 'label' => 'Display E-mail', 'value' => 'info@company.com'], 39 | ['key' => 'emailto', 'label' => 'E-mail receiver', 'value' => $modx->getOption('emailsender')], 40 | ]; 41 | } 42 | 43 | foreach ($settings as $idx => $data) { 44 | $setting = $modx->newObject('cgSetting'); 45 | $setting->set('key', $data['key']); 46 | $setting->set('label', $data['label']); 47 | $setting->set('value', $data['value']); 48 | $setting->set('xtype', 'textfield'); 49 | $setting->set('description', ''); 50 | $setting->set('is_required', true); 51 | $setting->set('sortorder', $idx); 52 | $setting->set('group', $group->id); 53 | $setting->save(); 54 | } 55 | 56 | if ($menu = $modx->getObject('modMenu', ['namespace' => 'clientconfig', 'action' => 'home'])) { 57 | if ($menu->get('parent') != 'topnav') { 58 | $data = $menu->toArray(); 59 | $data['previous_text'] = $menu->get('text'); 60 | if ($modx->getOption('cultureKey') == 'ru') { 61 | $data['text'] = 'Контакты'; 62 | } else { 63 | $data['text'] = 'Contacts'; 64 | } 65 | $data['parent'] = 'topnav'; 66 | $data['description'] = ''; 67 | $data['icon'] = ''; 68 | $data['menuindex'] = 99; 69 | $data['action_id'] = $data['action']; 70 | $response = $modx->runProcessor('system/menu/update', $data); 71 | if ($response->isError()) { 72 | $modx->log(modX::LOG_LEVEL_INFO, print_r($modx->error->failure($response->getMessage()), true)); 73 | } 74 | $modx->error->reset(); 75 | } 76 | } 77 | } 78 | } 79 | break; 80 | 81 | case xPDOTransport::ACTION_UNINSTALL: 82 | break; 83 | } 84 | } 85 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.content_type.php: -------------------------------------------------------------------------------- 1 | xpdo AND !$object->xpdo instanceof modX) { 5 | return true; 6 | } 7 | 8 | /** @var $options */ 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | 13 | if ($contentType = $modx->getObject('modContentType', array('name' => 'HTML'))) { 14 | $contentType->set('file_extensions', ''); 15 | $contentType->save(); 16 | } 17 | 18 | break; 19 | 20 | case xPDOTransport::ACTION_UNINSTALL: 21 | break; 22 | } 23 | 24 | return true; 25 | -------------------------------------------------------------------------------- /_build/resolvers/resolve.fix_directresize.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | case xPDOTransport::ACTION_UPGRADE: 10 | $plugin = $modx->getObject('modPlugin', array('name' => 'DirectResize2')); 11 | if ($plugin) { 12 | $content = $plugin->get('plugincode'); 13 | if (strpos($content, 'if (strpos("")) $html5=true;') !== false) { 14 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Fix DirectResize2'); 15 | $content = str_replace('if (strpos("")) $html5=true;', '$html5=false;', $content); 16 | $plugin->set('plugincode', $content); 17 | $plugin->save(); 18 | } 19 | } 20 | break; 21 | 22 | case xPDOTransport::ACTION_UNINSTALL: 23 | break; 24 | } 25 | } 26 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.fix_fastuploadtv.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $file = $modx->getOption('base_path') . 'assets/components/fastuploadtv/mgr/js/FastUploadTV.form.FastUploadTVField.js'; 8 | 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (file_exists($file)) { 13 | $content = file_get_contents($file); 14 | if ($modx->getOption('connectors_url') != '/connectors/' && strpos($content, '/connectors/') !== false) { 15 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Fix FastUploadTV'); 16 | $fp = fopen($file, "w"); 17 | $content = str_replace('/connectors/', $modx->getOption('connectors_url'), $content); 18 | fwrite($fp, $content); 19 | fclose($fp); 20 | } 21 | if (strpos($content, 'phpthumb.php?w=94&zc=0') !== false) { 22 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Fix FastUploadTV'); 23 | $fp = fopen($file, "w"); 24 | $content = str_replace('phpthumb.php?w=94&zc=0', 'phpthumb.php?w=130&h=73&zc=1', $content); 25 | fwrite($fp, $content); 26 | fclose($fp); 27 | } 28 | } 29 | break; 30 | 31 | case xPDOTransport::ACTION_UNINSTALL: 32 | break; 33 | } 34 | } 35 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.fix_file_permissions.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $file = $modx->getOption('core_path') . 'xpdo/cache/xpdocachemanager.class.php'; 8 | 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (file_exists($file)) { 13 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Fix file permissions'); 14 | $content = file_get_contents($file); 15 | $fp = fopen($file, "w"); 16 | $content = str_replace('(0666 - $this->_umask)', '(0777 - $this->_umask)', $content); 17 | fwrite($fp, $content); 18 | fclose($fp); 19 | } 20 | break; 21 | 22 | case xPDOTransport::ACTION_UNINSTALL: 23 | break; 24 | } 25 | } 26 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.fix_translit.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $table = $modx->getOption('core_path') . 'components/translit/model/modx/translit/tables/fixed_russian.php'; 8 | 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (!in_array('translit', $options['install_addons'])) return true; 13 | if (!file_exists($table)) { 14 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Fix transliteration'); 15 | $content = "'and','%'=>'','\''=>'','À'=>'A','À'=>'A','Á'=>'A','Á'=>'A','Â'=>'A','Â'=>'A','Ã'=>'A', 21 | 'Ã'=>'A','Ä'=>'e','Ä'=>'A','Å'=>'A','Å'=>'A','Æ'=>'e','Æ'=>'E','Ā'=>'A','Ą'=>'A','Ă'=>'A', 22 | 'Ç'=>'C','Ç'=>'C','Ć'=>'C','Č'=>'C','Ĉ'=>'C','Ċ'=>'C','Ď'=>'D','Đ'=>'D','È'=>'E','È'=>'E', 23 | 'É'=>'E','É'=>'E','Ê'=>'E','Ê'=>'E','Ë'=>'E','Ë'=>'E','Ē'=>'E','Ę'=>'E','Ě'=>'E','Ĕ'=>'E', 24 | 'Ė'=>'E','Ĝ'=>'G','Ğ'=>'G','Ġ'=>'G','Ģ'=>'G','Ĥ'=>'H','Ħ'=>'H','Ì'=>'I','Ì'=>'I','Í'=>'I', 25 | 'Í'=>'I','Î'=>'I','Î'=>'I','Ï'=>'I','Ï'=>'I','Ī'=>'I','Ĩ'=>'I','Ĭ'=>'I','Į'=>'I','İ'=>'I', 26 | 'IJ'=>'J','Ĵ'=>'J','Ķ'=>'K','Ľ'=>'K','Ĺ'=>'K','Ļ'=>'K','Ŀ'=>'K','Ñ'=>'N','Ñ'=>'N','Ń'=>'N', 27 | 'Ň'=>'N','Ņ'=>'N','Ŋ'=>'N','Ò'=>'O','Ò'=>'O','Ó'=>'O','Ó'=>'O','Ô'=>'O','Ô'=>'O','Õ'=>'O', 28 | 'Õ'=>'O','Ö'=>'e','Ö'=>'e','Ø'=>'O','Ø'=>'O','Ō'=>'O','Ő'=>'O','Ŏ'=>'O','Œ'=>'E','Ŕ'=>'R', 29 | 'Ř'=>'R','Ŗ'=>'R','Ś'=>'S','Ş'=>'S','Ŝ'=>'S','Ș'=>'S','Ť'=>'T','Ţ'=>'T','Ŧ'=>'T','Ț'=>'T', 30 | 'Ù'=>'U','Ù'=>'U','Ú'=>'U','Ú'=>'U','Û'=>'U','Û'=>'U','Ü'=>'e','Ū'=>'U','Ü'=>'e','Ů'=>'U', 31 | 'Ű'=>'U','Ŭ'=>'U','Ũ'=>'U','Ų'=>'U','Ŵ'=>'W','Ŷ'=>'Y','Ÿ'=>'Y','Ź'=>'Z','Ż'=>'Z','à'=>'a', 32 | 'á'=>'a','â'=>'a','ã'=>'a','ä'=>'e','ä'=>'e','å'=>'a','ā'=>'a','ą'=>'a','ă'=>'a','å'=>'a', 33 | 'æ'=>'e','ç'=>'c','ć'=>'c','č'=>'c','ĉ'=>'c','ċ'=>'c','ď'=>'d','đ'=>'d','è'=>'e','é'=>'e', 34 | 'ê'=>'e','ë'=>'e','ē'=>'e','ę'=>'e','ě'=>'e','ĕ'=>'e','ė'=>'e','ƒ'=>'f','ĝ'=>'g','ğ'=>'g', 35 | 'ġ'=>'g','ģ'=>'g','ĥ'=>'h','ħ'=>'h','ì'=>'i','í'=>'i','î'=>'i','ï'=>'i','ī'=>'i','ĩ'=>'i', 36 | 'ĭ'=>'i','į'=>'i','ı'=>'i','ij'=>'j','ĵ'=>'j','ķ'=>'k','ĸ'=>'k','ł'=>'l','ľ'=>'l','ĺ'=>'l', 37 | 'ļ'=>'l','ŀ'=>'l','ñ'=>'n','ń'=>'n','ň'=>'n','ņ'=>'n','ʼn'=>'n','ŋ'=>'n','ò'=>'o','ó'=>'o', 38 | 'ô'=>'o','õ'=>'o','ö'=>'e','ö'=>'e','ø'=>'o','ō'=>'o','ő'=>'o','ŏ'=>'o','œ'=>'e','ŕ'=>'r', 39 | 'ř'=>'r','ŗ'=>'r','ù'=>'u','ú'=>'u','û'=>'u','ü'=>'e','ū'=>'u','ü'=>'e','ů'=>'u','ű'=>'u', 40 | 'ŭ'=>'u','ũ'=>'u','ų'=>'u','ŵ'=>'w','ÿ'=>'y','ŷ'=>'y','ż'=>'z','ź'=>'z','ß'=>'s','ſ'=>'s', 41 | 'Α'=>'A','Ά'=>'A','Β'=>'B','Γ'=>'G','Δ'=>'D','Ε'=>'E','Έ'=>'E','Ζ'=>'Z','Η'=>'I','Ή'=>'I', 42 | 'Θ'=>'TH','Ι'=>'I','Ί'=>'I','Ϊ'=>'I','Κ'=>'K','Λ'=>'L','Μ'=>'M','Ν'=>'N','Ξ'=>'KS','Ο'=>'O', 43 | 'Ό'=>'O','Π'=>'P','Ρ'=>'R','Σ'=>'S','Τ'=>'T','Υ'=>'Y','Ύ'=>'Y','Ϋ'=>'Y','Φ'=>'F','Χ'=>'X', 44 | 'Ψ'=>'PS','Ω'=>'O','Ώ'=>'O','α'=>'a','ά'=>'a','β'=>'b','γ'=>'g','δ'=>'d','ε'=>'e','έ'=>'e', 45 | 'ζ'=>'z','η'=>'i','ή'=>'i','θ'=>'th','ι'=>'i','ί'=>'i','ϊ'=>'i','ΐ'=>'i','κ'=>'k','λ'=>'l', 46 | 'μ'=>'m','ν'=>'n','ξ'=>'ks','ο'=>'o','ό'=>'o','π'=>'p','ρ'=>'r','σ'=>'s','τ'=>'t','υ'=>'y', 47 | 'ύ'=>'y','ϋ'=>'y','ΰ'=>'y','φ'=>'f','χ'=>'x','ψ'=>'ps','ω'=>'o','ώ'=>'o','А'=>'a','Б'=>'b', 48 | 'В'=>'v','Г'=>'g','Д'=>'d','Е'=>'e','Ё'=>'yo','Ж'=>'zh','З'=>'z','И'=>'i','Й'=>'j','К'=>'k', 49 | 'Л'=>'l','М'=>'m','Н'=>'n','О'=>'o','П'=>'p','Р'=>'r','С'=>'s','Т'=>'t','У'=>'u','Ф'=>'f', 50 | 'Х'=>'h','Ц'=>'c','Ч'=>'ch','Ш'=>'sh','Щ'=>'sch','Ъ'=>'','Ы'=>'y','Ь'=>'','Э'=>'e','Ю'=>'yu', 51 | 'Я'=>'ya','а'=>'a','б'=>'b','в'=>'v','г'=>'g','д'=>'d','е'=>'e','ё'=>'yo','ж'=>'zh','з'=>'z', 52 | 'и'=>'i','й'=>'j','к'=>'k','л'=>'l','м'=>'m','н'=>'n','о'=>'o','п'=>'p','р'=>'r','с'=>'s', 53 | 'т'=>'t','у'=>'u','ф'=>'f','х'=>'h','ц'=>'c','ч'=>'ch','ш'=>'sh','щ'=>'sch','ъ'=>'','ы'=>'y', 54 | 'ь'=>'','э'=>'e','ю'=>'yu','я'=>'ya','№'=>'no' 55 | ); 56 | "; 57 | $fp = fopen($table, "w"); 58 | fwrite($fp, $content); 59 | fclose($fp); 60 | 61 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_alias_translit'))) { 62 | $tmp = $modx->newObject('modSystemSetting'); 63 | } 64 | $tmp->fromArray(array( 65 | 'namespace' => 'core', 66 | 'area' => 'furls', 67 | 'xtype' => 'textfield', 68 | 'value' => 'fixed_russian', 69 | 'key' => 'friendly_alias_translit', 70 | ), '', true, true); 71 | $tmp->save(); 72 | } 73 | break; 74 | 75 | case xPDOTransport::ACTION_UNINSTALL: 76 | if ($tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_alias_translit'))) { 77 | $tmp->fromArray(array( 78 | 'namespace' => 'core', 79 | 'area' => 'furls', 80 | 'xtype' => 'textfield', 81 | 'value' => 'russian', 82 | 'key' => 'friendly_alias_translit', 83 | ), '', true, true); 84 | $tmp->save(); 85 | } 86 | if (file_exists($table)) unlink($table); 87 | break; 88 | } 89 | } 90 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.manager_customisation.php: -------------------------------------------------------------------------------- 1 | xpdo AND !$object->xpdo instanceof modX) { 5 | return true; 6 | } 7 | 8 | /** @var $options */ 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (!$profile = $modx->getObject('modFormCustomizationProfile', array('name' => 'Site'))) { 13 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Form customisation'); 14 | $profile = $modx->newObject('modFormCustomizationProfile', array('name' => 'Site', 'active' => true)); 15 | $profile->save(); 16 | } 17 | $set = array('profile' => $profile->id); 18 | $set_list = array(); 19 | if (!$set_list['create_set'] = $modx->getObject('modFormCustomizationSet', array_merge(array('action' => 'resource/create'), $set))) { 20 | if ($modx->getOption('cultureKey') == 'ru') { 21 | $description = 'Правила для новых страниц'; 22 | } else { 23 | $description = 'Crating pages'; 24 | } 25 | $set_list['create_set'] = $modx->newObject('modFormCustomizationSet', array_merge(array('action' => 'resource/create', 'description' => $description, 'active' => true), $set)); 26 | $set_list['create_set']->save(); 27 | } 28 | if (!$set_list['update_set'] = $modx->getObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update'), $set))) { 29 | if ($modx->getOption('cultureKey') == 'ru') { 30 | $description = 'Правила для редактирования'; 31 | } else { 32 | $description = 'Updating pages'; 33 | } 34 | $set_list['update_set'] = $modx->newObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update', 'description' => $description, 'active' => true), $set)); 35 | $set_list['update_set']->save(); 36 | } 37 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'img'))) { 38 | foreach ($set_list as $set) { 39 | $rule_data = array( 40 | 'set' => $set->id, 41 | 'action' => $set->action, 42 | 'name' => 'tv' . $tv->id, 43 | 'container' => 'modx-panel-resource', 44 | 'rule' => 'tvMove', 45 | 'value' => 'modx-resource-main-right', 46 | 'constraint_class' => 'modResource' 47 | ); 48 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 49 | $rule_data['active'] = true; 50 | $rule = $modx->newObject('modActionDom', $rule_data); 51 | $rule->save(); 52 | } 53 | } 54 | } 55 | 56 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'show_on_page'))) { 57 | foreach ($set_list as $set) { 58 | $rule_data = array( 59 | 'set' => $set->id, 60 | 'action' => $set->action, 61 | 'name' => 'tv' . $tv->id, 62 | 'container' => 'modx-panel-resource', 63 | 'rule' => 'tvMove', 64 | 'value' => 'modx-resource-main-right', 65 | 'constraint_class' => 'modResource' 66 | ); 67 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 68 | $rule_data['active'] = true; 69 | $rule = $modx->newObject('modActionDom', $rule_data); 70 | $rule->save(); 71 | } 72 | } 73 | } 74 | 75 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'keywords'))) { 76 | foreach ($set_list as $set) { 77 | $rule_data = array( 78 | 'set' => $set->id, 79 | 'action' => $set->action, 80 | 'name' => 'tv' . $tv->id, 81 | 'container' => 'modx-panel-resource', 82 | 'rule' => 'tvMove', 83 | 'value' => 'modx-resource-main-left', 84 | 'constraint_class' => 'modResource' 85 | ); 86 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 87 | $rule_data['active'] = true; 88 | $rule = $modx->newObject('modActionDom', $rule_data); 89 | $rule->save(); 90 | } 91 | } 92 | } 93 | 94 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'subtitle'))) { 95 | foreach ($set_list as $set) { 96 | $rule_data = array( 97 | 'set' => $set->id, 98 | 'action' => $set->action, 99 | 'name' => 'tv' . $tv->id, 100 | 'container' => 'modx-panel-resource', 101 | 'rule' => 'tvMove', 102 | 'value' => 'modx-resource-main-left', 103 | 'constraint_class' => 'modResource' 104 | ); 105 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 106 | $rule_data['active'] = true; 107 | $rule = $modx->newObject('modActionDom', $rule_data); 108 | $rule->save(); 109 | } 110 | } 111 | } 112 | 113 | /* Перенесено в ClientConfig 114 | if ($contacts = $modx->getObject('modResource', array('alias' => 'contacts', 'parent' => 0))) { 115 | $res_id = $contacts->get('id'); 116 | $set_list = array(); 117 | $set = array('profile' => $profile->id); 118 | if (!$set_list['update_set'] = $modx->getObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update', 'constraint' => $res_id, 'constraint_field' => 'id', 'constraint_class' => 'modResource'), $set))) { 119 | $set_list['update_set'] = $modx->newObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update', 'constraint' => $res_id, 'constraint_field' => 'id', 'constraint_class' => 'modResource', 'description' => 'Правила для страницы контактов', 'active' => true), $set)); 120 | $set_list['update_set']->save(); 121 | } 122 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'phone'))) { 123 | foreach ($set_list as $set) { 124 | $rule_data = array( 125 | 'set' => $set->id, 126 | 'action' => $set->action, 127 | 'name' => 'tv' . $tv->id, 128 | 'container' => 'modx-panel-resource', 129 | 'rule' => 'tvMove', 130 | 'value' => 'modx-resource-main-right', 131 | 'constraint_class' => 'modResource' 132 | ); 133 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 134 | $rule_data['active'] = true; 135 | $rule = $modx->newObject('modActionDom', $rule_data); 136 | $rule->save(); 137 | } 138 | } 139 | } 140 | 141 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'address'))) { 142 | foreach ($set_list as $set) { 143 | $rule_data = array( 144 | 'set' => $set->id, 145 | 'action' => $set->action, 146 | 'name' => 'tv' . $tv->id, 147 | 'container' => 'modx-panel-resource', 148 | 'rule' => 'tvMove', 149 | 'value' => 'modx-resource-main-left', 150 | 'constraint_class' => 'modResource' 151 | ); 152 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 153 | $rule_data['active'] = true; 154 | $rule = $modx->newObject('modActionDom', $rule_data); 155 | $rule->save(); 156 | } 157 | } 158 | } 159 | 160 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'email'))) { 161 | foreach ($set_list as $set) { 162 | $rule_data = array( 163 | 'set' => $set->id, 164 | 'action' => $set->action, 165 | 'name' => 'tv' . $tv->id, 166 | 'container' => 'modx-panel-resource', 167 | 'rule' => 'tvMove', 168 | 'value' => 'modx-resource-main-left', 169 | 'constraint_class' => 'modResource' 170 | ); 171 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 172 | $rule_data['active'] = true; 173 | $rule = $modx->newObject('modActionDom', $rule_data); 174 | $rule->save(); 175 | } 176 | } 177 | } 178 | } 179 | */ 180 | 181 | if (in_array('MIGX', $options['install_addons'])) { 182 | $set_list = array(); 183 | $set = array('profile' => $profile->id); 184 | if (!$set_list['update_set'] = $modx->getObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update', 'constraint' => 0, 'constraint_field' => 'parent', 'constraint_class' => 'modResource'), $set))) { 185 | if ($modx->getOption('cultureKey') == 'ru') { 186 | $description = 'Правила для страниц в корне сайта'; 187 | } else { 188 | $description = 'Root pages'; 189 | } 190 | $set_list['update_set'] = $modx->newObject('modFormCustomizationSet', array_merge(array('action' => 'resource/update', 'constraint' => 0, 'constraint_field' => 'parent', 'constraint_class' => 'modResource', 'description' => $description, 'active' => true), $set)); 191 | $set_list['update_set']->save(); 192 | } 193 | if ($tv = $modx->getObject('modTemplateVar', array('name' => 'elements'))) { 194 | foreach ($set_list as $set) { 195 | $rule_data = array( 196 | 'set' => $set->id, 197 | 'action' => $set->action, 198 | 'name' => 'tv' . $tv->id, 199 | 'container' => 'modx-panel-resource', 200 | 'rule' => 'tvMove', 201 | 'value' => 'modx-resource-main-left', 202 | 'constraint_class' => 'modResource' 203 | ); 204 | if (!$rule = $modx->getObject('modActionDom', $rule_data)) { 205 | $rule_data['active'] = true; 206 | $rule = $modx->newObject('modActionDom', $rule_data); 207 | $rule->save(); 208 | } 209 | } 210 | } 211 | } 212 | 213 | break; 214 | case xPDOTransport::ACTION_UNINSTALL: 215 | break; 216 | } 217 | 218 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.providers.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /* @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | case xPDOTransport::ACTION_UPGRADE: 10 | $provider_name = 'modstore.pro'; 11 | if (!$provider = $modx->getObject('transport.modTransportProvider', array('service_url:LIKE' => '%' . $provider_name . '%'))) { 12 | $provider = $modx->newObject('transport.modTransportProvider', array( 13 | 'name' => $provider_name, 14 | 'service_url' => 'http://' . $provider_name . '/extras/', 15 | 'username' => !empty($options['email']) && preg_match('/.+@.+\..+/i', $options['email']) ? trim($options['email']) : '', 16 | 'api_key' => !empty($options['key']) ? trim($options['key']) : '', 17 | 'description' => 'Repository of ' . $provider_name, 18 | 'created' => time(), 19 | )); 20 | $provider->save(); 21 | } 22 | break; 23 | case xPDOTransport::ACTION_UNINSTALL: 24 | break; 25 | } 26 | } 27 | return true; 28 | -------------------------------------------------------------------------------- /_build/resolvers/resolve.remove_changelog.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $file = $modx->getOption('core_path') . 'docs/changelog.txt'; 8 | 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (file_exists($file)) { 13 | $modx->log(modX::LOG_LEVEL_INFO, 'Removing changelog.txt'); 14 | unlink($file); 15 | } 16 | break; 17 | 18 | case xPDOTransport::ACTION_UNINSTALL: 19 | break; 20 | } 21 | } 22 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.rename_htaccess.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | $inroot = $modx->getOption('base_path') . 'ht.access'; 8 | $incore = $modx->getOption('core_path') . 'ht.access'; 9 | 10 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 11 | case xPDOTransport::ACTION_INSTALL: 12 | case xPDOTransport::ACTION_UPGRADE: 13 | if (file_exists($inroot) || file_exists($incore)) { 14 | $new_inroot = $modx->getOption('base_path') . '.htaccess'; 15 | $new_incore = $modx->getOption('core_path') . '.htaccess'; 16 | $log = false; 17 | if (!file_exists($new_inroot)) { 18 | rename($inroot, $new_inroot); 19 | $log = true; 20 | } 21 | if (!file_exists($new_incore)) { 22 | rename($incore, $new_incore); 23 | $log = true; 24 | } 25 | if ($log) { 26 | $modx->log(modX::LOG_LEVEL_INFO, 'Renaming htaccess'); 27 | } 28 | } 29 | break; 30 | 31 | case xPDOTransport::ACTION_UNINSTALL: 32 | break; 33 | } 34 | } 35 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.sample.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Sample resolver install'); 10 | break; 11 | case xPDOTransport::ACTION_UPGRADE: 12 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Sample resolver upgrade'); 13 | break; 14 | 15 | case xPDOTransport::ACTION_UNINSTALL: 16 | break; 17 | } 18 | } 19 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.set_start_year.php: -------------------------------------------------------------------------------- 1 | xpdo) { 4 | /** @var modX $modx */ 5 | $modx =& $object->xpdo; 6 | 7 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 8 | case xPDOTransport::ACTION_INSTALL: 9 | if ($tmp = $modx->getObject('modChunk', array('name' => 'footer'))) { 10 | if (strpos($tmp->get('content'), '{if $year == 2016}2016{else}2016—{$year}{/if}') !== false) { 11 | $modx->log(modX::LOG_LEVEL_INFO, 'Run Set start year for copyright'); 12 | $tmp->set('content', str_replace( 13 | '{if $year == 2016}2016{else}2016—{$year}{/if}', 14 | '{if $year == '.date('Y').'}'.date('Y').'{else}'.date('Y').'—{$year}{/if}', 15 | $tmp->get('content'))); 16 | $tmp->save(); 17 | } 18 | } 19 | break; 20 | case xPDOTransport::ACTION_UPGRADE: 21 | case xPDOTransport::ACTION_UNINSTALL: 22 | break; 23 | } 24 | } 25 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.settings.php: -------------------------------------------------------------------------------- 1 | xpdo AND !$object->xpdo instanceof modX) { 5 | return true; 6 | } 7 | 8 | /** @var $options */ 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | 13 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'allow_multiple_emails'))) { 14 | $tmp = $modx->newObject('modSystemSetting'); 15 | } 16 | $tmp->fromArray(array( 17 | 'namespace' => 'core', 18 | 'area' => 'authentication', 19 | 'xtype' => 'combo-boolean', 20 | 'value' => '0', 21 | 'key' => 'allow_multiple_emails', 22 | ), '', true, true); 23 | $tmp->save(); 24 | 25 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_alias_realtime'))) { 26 | $tmp = $modx->newObject('modSystemSetting'); 27 | } 28 | $tmp->fromArray(array( 29 | 'namespace' => 'core', 30 | 'area' => 'furls', 31 | 'xtype' => 'combo-boolean', 32 | 'value' => '1', 33 | 'key' => 'friendly_alias_realtime', 34 | ), '', true, true); 35 | $tmp->save(); 36 | 37 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_urls'))) { 38 | $tmp = $modx->newObject('modSystemSetting'); 39 | } 40 | $tmp->fromArray(array( 41 | 'namespace' => 'core', 42 | 'area' => 'furls', 43 | 'xtype' => 'combo-boolean', 44 | 'value' => '1', 45 | 'key' => 'friendly_urls', 46 | ), '', true, true); 47 | $tmp->save(); 48 | 49 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_urls_strict'))) { 50 | $tmp = $modx->newObject('modSystemSetting'); 51 | } 52 | $tmp->fromArray(array( 53 | 'namespace' => 'core', 54 | 'area' => 'furls', 55 | 'xtype' => 'combo-boolean', 56 | 'value' => '1', 57 | 'key' => 'friendly_urls_strict', 58 | ), '', true, true); 59 | $tmp->save(); 60 | 61 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'hidemenu_default'))) { 62 | $tmp = $modx->newObject('modSystemSetting'); 63 | } 64 | $tmp->fromArray(array( 65 | 'namespace' => 'core', 66 | 'area' => 'site', 67 | 'xtype' => 'combo-boolean', 68 | 'value' => '1', 69 | 'key' => 'hidemenu_default', 70 | ), '', true, true); 71 | $tmp->save(); 72 | 73 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'publish_default'))) { 74 | $tmp = $modx->newObject('modSystemSetting'); 75 | } 76 | $tmp->fromArray(array( 77 | 'namespace' => 'core', 78 | 'area' => 'site', 79 | 'xtype' => 'combo-boolean', 80 | 'value' => '1', 81 | 'key' => 'publish_default', 82 | ), '', true, true); 83 | $tmp->save(); 84 | 85 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'use_alias_path'))) { 86 | $tmp = $modx->newObject('modSystemSetting'); 87 | } 88 | $tmp->fromArray(array( 89 | 'namespace' => 'core', 90 | 'area' => 'furls', 91 | 'xtype' => 'combo-boolean', 92 | 'value' => '1', 93 | 'key' => 'use_alias_path', 94 | ), '', true, true); 95 | $tmp->save(); 96 | 97 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'container_suffix'))) { 98 | $tmp = $modx->newObject('modSystemSetting'); 99 | } 100 | $tmp->fromArray(array( 101 | 'namespace' => 'core', 102 | 'area' => 'furls', 103 | 'xtype' => 'textfield', 104 | 'value' => '', 105 | 'key' => 'container_suffix', 106 | ), '', true, true); 107 | $tmp->save(); 108 | 109 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_alias_restrict_chars_pattern'))) { 110 | $tmp = $modx->newObject('modSystemSetting'); 111 | } 112 | $tmp->fromArray(array( 113 | 'namespace' => 'core', 114 | 'area' => 'furls', 115 | 'xtype' => 'textfield', 116 | 'value' => file_get_contents($modx->getOption('core_path') . 'components/' . strtolower($options['site_category']) . '/docs/friendly_alias_restrict_chars_pattern.txt'), 117 | 'key' => 'friendly_alias_restrict_chars_pattern', 118 | ), '', true, true); 119 | $tmp->save(); 120 | 121 | if (in_array('translit', $options['install_addons'])) { 122 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'friendly_alias_translit'))) { 123 | $tmp = $modx->newObject('modSystemSetting'); 124 | } 125 | $tmp->fromArray(array( 126 | 'namespace' => 'core', 127 | 'area' => 'furls', 128 | 'xtype' => 'textfield', 129 | 'value' => 'russian', 130 | 'key' => 'friendly_alias_translit', 131 | ), '', true, true); 132 | $tmp->save(); 133 | } 134 | 135 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'resource_tree_node_name'))) { 136 | $tmp = $modx->newObject('modSystemSetting'); 137 | } 138 | $tmp->fromArray(array( 139 | 'namespace' => 'core', 140 | 'area' => 'manager', 141 | 'xtype' => 'textfield', 142 | 'value' => 'menutitle', 143 | 'key' => 'resource_tree_node_name', 144 | ), '', true, true); 145 | $tmp->save(); 146 | 147 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'resource_tree_node_tooltip'))) { 148 | $tmp = $modx->newObject('modSystemSetting'); 149 | } 150 | $tmp->fromArray(array( 151 | 'namespace' => 'core', 152 | 'area' => 'manager', 153 | 'xtype' => 'textfield', 154 | 'value' => 'alias', 155 | 'key' => 'resource_tree_node_tooltip', 156 | ), '', true, true); 157 | $tmp->save(); 158 | 159 | 160 | $alias = '404'; 161 | $tid = $modx->getOption('site_start'); 162 | if ($resource = $modx->getObject('modResource', array('alias' => $alias))) { 163 | $tid = $resource->get('id'); 164 | } 165 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'error_page'))) { 166 | $tmp = $modx->newObject('modSystemSetting'); 167 | } 168 | $tmp->fromArray(array( 169 | 'namespace' => 'core', 170 | 'area' => 'site', 171 | 'xtype' => 'textfield', 172 | 'value' => $tid, 173 | 'key' => 'error_page', 174 | ), '', true, true); 175 | $tmp->save(); 176 | 177 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'site_unavailable_page'))) { 178 | $tmp = $modx->newObject('modSystemSetting'); 179 | } 180 | $tmp->fromArray(array( 181 | 'namespace' => 'core', 182 | 'area' => 'site', 183 | 'xtype' => 'textfield', 184 | 'value' => $tid, 185 | 'key' => 'site_unavailable_page', 186 | ), '', true, true); 187 | $tmp->save(); 188 | 189 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'unauthorized_page'))) { 190 | $tmp = $modx->newObject('modSystemSetting'); 191 | } 192 | $tmp->fromArray(array( 193 | 'namespace' => 'core', 194 | 'area' => 'site', 195 | 'xtype' => 'textfield', 196 | 'value' => $tid, 197 | 'key' => 'unauthorized_page', 198 | ), '', true, true); 199 | $tmp->save(); 200 | 201 | 202 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'error_page_header'))) { 203 | $tmp = $modx->newObject('modSystemSetting'); 204 | } 205 | $tmp->fromArray(array( 206 | 'namespace' => 'core', 207 | 'area' => 'site', 208 | 'xtype' => 'textfield', 209 | 'value' => 'HTTP/1.0 404 Not Found', 210 | 'key' => 'error_page_header', 211 | ), '', true, true); 212 | $tmp->save(); 213 | 214 | if (in_array('FastUploadTV', $options['install_addons'])) { 215 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'fastuploadtv.translit'))) { 216 | $tmp = $modx->newObject('modSystemSetting'); 217 | } 218 | $tmp->fromArray(array( 219 | 'namespace' => 'fastuploadtv', 220 | 'area' => 'Default', 221 | 'xtype' => 'combo-boolean', 222 | 'value' => '1', 223 | 'key' => 'fastuploadtv.translit', 224 | ), '', true, true); 225 | $tmp->save(); 226 | } 227 | 228 | if (in_array('pdoTools', $options['install_addons'])) { 229 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'pdotools_fenom_parser'))) { 230 | $tmp = $modx->newObject('modSystemSetting'); 231 | } 232 | $tmp->fromArray(array( 233 | 'namespace' => 'pdotools', 234 | 'area' => 'pdotools_main', 235 | 'xtype' => 'combo-boolean', 236 | 'value' => '1', 237 | 'key' => 'pdotools_fenom_parser', 238 | ), '', true, true); 239 | $tmp->save(); 240 | } 241 | 242 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'locale'))) { 243 | $tmp = $modx->newObject('modSystemSetting'); 244 | } 245 | $tmp->fromArray(array( 246 | 'namespace' => 'core', 247 | 'area' => 'language', 248 | 'xtype' => 'textfield', 249 | 'value' => 'ru_RU.utf8', 250 | 'key' => 'locale', 251 | ), '', true, true); 252 | $tmp->save(); 253 | 254 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'cache_prefix'))) { 255 | $tmp = $modx->newObject('modSystemSetting'); 256 | } 257 | $tmp->fromArray(array( 258 | 'namespace' => 'core', 259 | 'area' => 'caching', 260 | 'xtype' => 'textfield', 261 | 'value' => '', 262 | 'key' => 'cache_prefix', 263 | ), '', true, true); 264 | $tmp->save(); 265 | 266 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'manager_favicon_url'))) { 267 | $tmp = $modx->newObject('modSystemSetting'); 268 | } 269 | $tmp->fromArray(array( 270 | 'namespace' => 'core', 271 | 'area' => 'manager', 272 | 'xtype' => 'textfield', 273 | 'value' => $modx->getOption('assets_url') . 'components/' . strtolower($options['site_category']) . '/web/img/favicon.ico', 274 | 'key' => 'manager_favicon_url', 275 | ), '', true, true); 276 | $tmp->save(); 277 | 278 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'log_deprecated'))) { 279 | $tmp = $modx->newObject('modSystemSetting'); 280 | } 281 | $tmp->fromArray(array( 282 | 'namespace' => 'core', 283 | 'area' => 'system', 284 | 'xtype' => 'combo-boolean', 285 | 'value' => '0', 286 | 'key' => 'log_deprecated', 287 | ), '', true, true); 288 | $tmp->save(); 289 | 290 | break; 291 | 292 | case xPDOTransport::ACTION_UNINSTALL: 293 | break; 294 | } 295 | 296 | return true; 297 | -------------------------------------------------------------------------------- /_build/resolvers/resolve.template.php: -------------------------------------------------------------------------------- 1 | xpdo AND !$object->xpdo instanceof modX) { 5 | return true; 6 | } 7 | 8 | /** @var $options */ 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (isset($options['site_template_name']) && !empty($options['site_template_name'])) { 13 | 14 | $template = $modx->getObject('modTemplate', array('templatename' => $options['site_template_name'])); 15 | 16 | if (!$tmp = $modx->getObject('modSystemSetting', array('key' => 'default_template'))) { 17 | $tmp = $modx->newObject('modSystemSetting'); 18 | } 19 | $tmp->fromArray(array( 20 | 'namespace' => 'core', 21 | 'area' => 'site', 22 | 'xtype' => 'textfield', 23 | 'value' => $template->get('id'), 24 | 'key' => 'default_template', 25 | ), '', true, true); 26 | $tmp->save(); 27 | 28 | $site_start = $modx->getObject('modResource', $modx->getOption('site_start')); 29 | if ($site_start) { 30 | $site_start->set('template', $template->get('id')); 31 | $site_start->save(); 32 | } 33 | } 34 | break; 35 | case xPDOTransport::ACTION_UNINSTALL: 36 | break; 37 | } 38 | 39 | return true; -------------------------------------------------------------------------------- /_build/resolvers/resolve.tvs.php: -------------------------------------------------------------------------------- 1 | xpdo AND !$object->xpdo instanceof modX) { 5 | return true; 6 | } 7 | 8 | /** @var $options */ 9 | switch ($options[xPDOTransport::PACKAGE_ACTION]) { 10 | case xPDOTransport::ACTION_INSTALL: 11 | case xPDOTransport::ACTION_UPGRADE: 12 | if (isset($options['site_category']) && $options['site_category']) { 13 | if ($category = $modx->getObject('modCategory', array('category' => $options['site_category']))) { 14 | $cat_id = $category->get('id'); 15 | } else { 16 | $cat_id = 0; 17 | } 18 | } else { 19 | $cat_id = 0; 20 | } 21 | 22 | $tvs = array(); 23 | 24 | $name = 'img'; 25 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 26 | $tv = $modx->newObject('modTemplateVar'); 27 | if (in_array('FastUploadTV', $options['install_addons'])) { 28 | $image_tv_type = 'fastuploadtv'; 29 | } else { 30 | $image_tv_type = 'image'; 31 | } 32 | if ($modx->getOption('cultureKey') == 'ru') { 33 | $caption = 'Изображение'; 34 | } else { 35 | $caption = 'Image'; 36 | } 37 | $tv->fromArray(array( 38 | 'name' => $name, 39 | 'type' => $image_tv_type, 40 | 'caption' => $caption, //'Изображение', 41 | 'category' => $cat_id, 42 | 'input_properties' => array( 43 | "path" => "assets/images/{d}-{m}-{y}/", 44 | "prefix" => "{rand}-", 45 | "MIME" => "", 46 | "showValue" => false, 47 | "showPreview" => true 48 | ), 49 | )); 50 | $tv->save(); 51 | $tvs[] = $tv->get('id'); 52 | } 53 | 54 | $name = 'show_on_page'; 55 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 56 | $tv = $modx->newObject('modTemplateVar'); 57 | if ($modx->getOption('cultureKey') == 'ru') { 58 | $caption = 'Отображать на странице'; 59 | } else { 60 | $caption = 'Display on page'; 61 | } 62 | $tv->fromArray(array( 63 | 'name' => $name, 64 | 'type' => 'checkbox', 65 | 'caption' => $caption, //'Отображать на странице', 66 | 'category' => $cat_id, 67 | 'elements' => 'Дочерние ресурсы==children||Контент==content||Галерею==gallery', 68 | 'default_text' => 'children||content||gallery', 69 | 'display' => 'delim', 70 | 'output_properties' => array( 71 | 'delimiter' => '||' 72 | ) 73 | )); 74 | $tv->save(); 75 | $tvs[] = $tv->get('id'); 76 | } 77 | 78 | /* Перенесено в ClientConfig 79 | 80 | $name = 'address'; 81 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 82 | $tv = $modx->newObject('modTemplateVar'); 83 | $tv->fromArray(array( 84 | 'name' => $name, 85 | 'type' => 'text', 86 | 'caption' => $caption, //'Адрес', 87 | 'category' => $cat_id 88 | )); 89 | $tv->save(); 90 | $tvs[] = $tv->get('id'); 91 | } 92 | 93 | $name = 'phone'; 94 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 95 | $tv = $modx->newObject('modTemplateVar'); 96 | $tv->fromArray(array( 97 | 'name' => $name, 98 | 'type' => 'text', 99 | 'caption' => $caption, //'Телефон', 100 | 'category' => $cat_id 101 | )); 102 | $tv->save(); 103 | $tvs[] = $tv->get('id'); 104 | } 105 | 106 | $name = 'email'; 107 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 108 | $tv = $modx->newObject('modTemplateVar'); 109 | $tv->fromArray(array( 110 | 'name' => $name, 111 | 'type' => 'text', 112 | 'caption' => $caption, //'E-mail', 113 | 'category' => $cat_id 114 | )); 115 | $tv->save(); 116 | $tvs[] = $tv->get('id'); 117 | } 118 | */ 119 | 120 | $name = 'keywords'; 121 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 122 | $tv = $modx->newObject('modTemplateVar'); 123 | if ($modx->getOption('cultureKey') == 'ru') { 124 | $caption = 'Keywords'; 125 | } else { 126 | $caption = 'Keywords'; 127 | } 128 | $tv->fromArray(array( 129 | 'name' => $name, 130 | 'type' => 'text', 131 | 'caption' => $caption, //'Keywords', 132 | 'category' => $cat_id 133 | )); 134 | $tv->save(); 135 | $tvs[] = $tv->get('id'); 136 | } 137 | 138 | $name = 'subtitle'; 139 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 140 | $tv = $modx->newObject('modTemplateVar'); 141 | if ($modx->getOption('cultureKey') == 'ru') { 142 | $caption = 'Подпись'; 143 | } else { 144 | $caption = 'Subtitle'; 145 | } 146 | $tv->fromArray(array( 147 | 'name' => $name, 148 | 'type' => 'text', 149 | 'caption' => $caption, //'Подпись', 150 | 'category' => $cat_id 151 | )); 152 | $tv->save(); 153 | $tvs[] = $tv->get('id'); 154 | } 155 | 156 | if (in_array('MIGX', $options['install_addons'])) { 157 | $name = 'elements'; 158 | if (!$tv = $modx->getObject('modTemplateVar', array('name' => $name))) { 159 | $tv = $modx->newObject('modTemplateVar'); 160 | if ($modx->getOption('cultureKey') == 'ru') { 161 | $caption = 'Элементы'; 162 | } else { 163 | $caption = 'Elements'; 164 | } 165 | if ($modx->getOption('cultureKey') == 'ru') { 166 | $tv->fromArray(array( 167 | 'name' => $name, 168 | 'type' => 'migx', 169 | 'caption' => $caption, //'Элементы', 170 | 'category' => $cat_id, 171 | 'input_properties' => array( 172 | "formtabs" => '[{"caption":"Элемент","fields":[{"field":"title","caption":"Заголовок"},{"field":"subtitle","caption":"Подзаголовок"},{"field":"img","caption":"Изображение","inputTV":"img"},{"field":"content","caption":"Контент","inputTVtype":"richtext"}]}]', 173 | "columns" => '[{"header":"Изображение","dataIndex":"img","width":200,"renderer":"this.renderImage"},{"header":"Содержимое","dataIndex":"title","width":400}]' 174 | ), 175 | )); 176 | } else { 177 | $tv->fromArray(array( 178 | 'name' => $name, 179 | 'type' => 'migx', 180 | 'caption' => $caption, //'Элементы', 181 | 'category' => $cat_id, 182 | 'input_properties' => array( 183 | "formtabs" => '[{"caption":"Element","fields":[{"field":"title","caption":"Title"},{"field":"subtitle","caption":"Subtitle"},{"field":"img","caption":"Image","inputTV":"img"},{"field":"content","caption":"Content","inputTVtype":"richtext"}]}]', 184 | "columns" => '[{"header":"Image","dataIndex":"img","width":200,"renderer":"this.renderImage"},{"header":"Content","dataIndex":"title","width":400}]' 185 | ), 186 | )); 187 | } 188 | $tv->save(); 189 | $tvs[] = $tv->get('id'); 190 | } 191 | } 192 | 193 | foreach ($modx->getCollection('modTemplate') as $template) { 194 | $templateId = $template->id; 195 | foreach ($tvs as $k => $tvid) { 196 | if (!$tvt = $modx->getObject('modTemplateVarTemplate', array('tmplvarid' => $tvid, 'templateid' => $templateId))) { 197 | $record = array('tmplvarid' => $tvid, 'templateid' => $templateId); 198 | $keys = array_keys($record); 199 | $fields = '`' . implode('`,`', $keys) . '`'; 200 | $placeholders = substr(str_repeat('?,', count($keys)), 0, -1); 201 | $sql = "INSERT INTO {$modx->getTableName('modTemplateVarTemplate')} ({$fields}) VALUES ({$placeholders});"; 202 | $modx->prepare($sql)->execute(array_values($record)); 203 | } 204 | } 205 | } 206 | 207 | break; 208 | case xPDOTransport::ACTION_UNINSTALL: 209 | break; 210 | } 211 | 212 | return true; -------------------------------------------------------------------------------- /assets/components/site/bootstrap/css/bootstrap-theme.min.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.3.7 (http://getbootstrap.com) 3 | * Copyright 2011-2016 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */.btn-danger,.btn-default,.btn-info,.btn-primary,.btn-success,.btn-warning{text-shadow:0 -1px 0 rgba(0,0,0,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075)}.btn-danger.active,.btn-danger:active,.btn-default.active,.btn-default:active,.btn-info.active,.btn-info:active,.btn-primary.active,.btn-primary:active,.btn-success.active,.btn-success:active,.btn-warning.active,.btn-warning:active{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-danger.disabled,.btn-danger[disabled],.btn-default.disabled,.btn-default[disabled],.btn-info.disabled,.btn-info[disabled],.btn-primary.disabled,.btn-primary[disabled],.btn-success.disabled,.btn-success[disabled],.btn-warning.disabled,.btn-warning[disabled],fieldset[disabled] .btn-danger,fieldset[disabled] .btn-default,fieldset[disabled] .btn-info,fieldset[disabled] .btn-primary,fieldset[disabled] .btn-success,fieldset[disabled] .btn-warning{-webkit-box-shadow:none;box-shadow:none}.btn-danger .badge,.btn-default .badge,.btn-info .badge,.btn-primary .badge,.btn-success .badge,.btn-warning .badge{text-shadow:none}.btn.active,.btn:active{background-image:none}.btn-default{text-shadow:0 1px 0 #fff;background-image:-webkit-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-o-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#e0e0e0));background-image:linear-gradient(to bottom,#fff 0,#e0e0e0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#dbdbdb;border-color:#ccc}.btn-default:focus,.btn-default:hover{background-color:#e0e0e0;background-position:0 -15px}.btn-default.active,.btn-default:active{background-color:#e0e0e0;border-color:#dbdbdb}.btn-default.disabled,.btn-default.disabled.active,.btn-default.disabled.focus,.btn-default.disabled:active,.btn-default.disabled:focus,.btn-default.disabled:hover,.btn-default[disabled],.btn-default[disabled].active,.btn-default[disabled].focus,.btn-default[disabled]:active,.btn-default[disabled]:focus,.btn-default[disabled]:hover,fieldset[disabled] .btn-default,fieldset[disabled] .btn-default.active,fieldset[disabled] .btn-default.focus,fieldset[disabled] .btn-default:active,fieldset[disabled] .btn-default:focus,fieldset[disabled] .btn-default:hover{background-color:#e0e0e0;background-image:none}.btn-primary{background-image:-webkit-linear-gradient(top,#337ab7 0,#265a88 100%);background-image:-o-linear-gradient(top,#337ab7 0,#265a88 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#265a88));background-image:linear-gradient(to bottom,#337ab7 0,#265a88 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#245580}.btn-primary:focus,.btn-primary:hover{background-color:#265a88;background-position:0 -15px}.btn-primary.active,.btn-primary:active{background-color:#265a88;border-color:#245580}.btn-primary.disabled,.btn-primary.disabled.active,.btn-primary.disabled.focus,.btn-primary.disabled:active,.btn-primary.disabled:focus,.btn-primary.disabled:hover,.btn-primary[disabled],.btn-primary[disabled].active,.btn-primary[disabled].focus,.btn-primary[disabled]:active,.btn-primary[disabled]:focus,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary,fieldset[disabled] .btn-primary.active,fieldset[disabled] .btn-primary.focus,fieldset[disabled] .btn-primary:active,fieldset[disabled] .btn-primary:focus,fieldset[disabled] .btn-primary:hover{background-color:#265a88;background-image:none}.btn-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#419641));background-image:linear-gradient(to bottom,#5cb85c 0,#419641 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#3e8f3e}.btn-success:focus,.btn-success:hover{background-color:#419641;background-position:0 -15px}.btn-success.active,.btn-success:active{background-color:#419641;border-color:#3e8f3e}.btn-success.disabled,.btn-success.disabled.active,.btn-success.disabled.focus,.btn-success.disabled:active,.btn-success.disabled:focus,.btn-success.disabled:hover,.btn-success[disabled],.btn-success[disabled].active,.btn-success[disabled].focus,.btn-success[disabled]:active,.btn-success[disabled]:focus,.btn-success[disabled]:hover,fieldset[disabled] .btn-success,fieldset[disabled] .btn-success.active,fieldset[disabled] .btn-success.focus,fieldset[disabled] .btn-success:active,fieldset[disabled] .btn-success:focus,fieldset[disabled] .btn-success:hover{background-color:#419641;background-image:none}.btn-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#2aabd2));background-image:linear-gradient(to bottom,#5bc0de 0,#2aabd2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#28a4c9}.btn-info:focus,.btn-info:hover{background-color:#2aabd2;background-position:0 -15px}.btn-info.active,.btn-info:active{background-color:#2aabd2;border-color:#28a4c9}.btn-info.disabled,.btn-info.disabled.active,.btn-info.disabled.focus,.btn-info.disabled:active,.btn-info.disabled:focus,.btn-info.disabled:hover,.btn-info[disabled],.btn-info[disabled].active,.btn-info[disabled].focus,.btn-info[disabled]:active,.btn-info[disabled]:focus,.btn-info[disabled]:hover,fieldset[disabled] .btn-info,fieldset[disabled] .btn-info.active,fieldset[disabled] .btn-info.focus,fieldset[disabled] .btn-info:active,fieldset[disabled] .btn-info:focus,fieldset[disabled] .btn-info:hover{background-color:#2aabd2;background-image:none}.btn-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#eb9316));background-image:linear-gradient(to bottom,#f0ad4e 0,#eb9316 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#e38d13}.btn-warning:focus,.btn-warning:hover{background-color:#eb9316;background-position:0 -15px}.btn-warning.active,.btn-warning:active{background-color:#eb9316;border-color:#e38d13}.btn-warning.disabled,.btn-warning.disabled.active,.btn-warning.disabled.focus,.btn-warning.disabled:active,.btn-warning.disabled:focus,.btn-warning.disabled:hover,.btn-warning[disabled],.btn-warning[disabled].active,.btn-warning[disabled].focus,.btn-warning[disabled]:active,.btn-warning[disabled]:focus,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning,fieldset[disabled] .btn-warning.active,fieldset[disabled] .btn-warning.focus,fieldset[disabled] .btn-warning:active,fieldset[disabled] .btn-warning:focus,fieldset[disabled] .btn-warning:hover{background-color:#eb9316;background-image:none}.btn-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c12e2a));background-image:linear-gradient(to bottom,#d9534f 0,#c12e2a 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#b92c28}.btn-danger:focus,.btn-danger:hover{background-color:#c12e2a;background-position:0 -15px}.btn-danger.active,.btn-danger:active{background-color:#c12e2a;border-color:#b92c28}.btn-danger.disabled,.btn-danger.disabled.active,.btn-danger.disabled.focus,.btn-danger.disabled:active,.btn-danger.disabled:focus,.btn-danger.disabled:hover,.btn-danger[disabled],.btn-danger[disabled].active,.btn-danger[disabled].focus,.btn-danger[disabled]:active,.btn-danger[disabled]:focus,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger,fieldset[disabled] .btn-danger.active,fieldset[disabled] .btn-danger.focus,fieldset[disabled] .btn-danger:active,fieldset[disabled] .btn-danger:focus,fieldset[disabled] .btn-danger:hover{background-color:#c12e2a;background-image:none}.img-thumbnail,.thumbnail{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.dropdown-menu>li>a:focus,.dropdown-menu>li>a:hover{background-color:#e8e8e8;background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.dropdown-menu>.active>a,.dropdown-menu>.active>a:focus,.dropdown-menu>.active>a:hover{background-color:#2e6da4;background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}.navbar-default{background-image:-webkit-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-o-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#f8f8f8));background-image:linear-gradient(to bottom,#fff 0,#f8f8f8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-radius:4px;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075)}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.open>a{background-image:-webkit-linear-gradient(top,#dbdbdb 0,#e2e2e2 100%);background-image:-o-linear-gradient(top,#dbdbdb 0,#e2e2e2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dbdbdb),to(#e2e2e2));background-image:linear-gradient(to bottom,#dbdbdb 0,#e2e2e2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.075);box-shadow:inset 0 3px 9px rgba(0,0,0,.075)}.navbar-brand,.navbar-nav>li>a{text-shadow:0 1px 0 rgba(255,255,255,.25)}.navbar-inverse{background-image:-webkit-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-o-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#3c3c3c),to(#222));background-image:linear-gradient(to bottom,#3c3c3c 0,#222 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-radius:4px}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.open>a{background-image:-webkit-linear-gradient(top,#080808 0,#0f0f0f 100%);background-image:-o-linear-gradient(top,#080808 0,#0f0f0f 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#080808),to(#0f0f0f));background-image:linear-gradient(to bottom,#080808 0,#0f0f0f 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.25);box-shadow:inset 0 3px 9px rgba(0,0,0,.25)}.navbar-inverse .navbar-brand,.navbar-inverse .navbar-nav>li>a{text-shadow:0 -1px 0 rgba(0,0,0,.25)}.navbar-fixed-bottom,.navbar-fixed-top,.navbar-static-top{border-radius:0}@media (max-width:767px){.navbar .navbar-nav .open .dropdown-menu>.active>a,.navbar .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar .navbar-nav .open .dropdown-menu>.active>a:hover{color:#fff;background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}}.alert{text-shadow:0 1px 0 rgba(255,255,255,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05);box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05)}.alert-success{background-image:-webkit-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#c8e5bc));background-image:linear-gradient(to bottom,#dff0d8 0,#c8e5bc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);background-repeat:repeat-x;border-color:#b2dba1}.alert-info{background-image:-webkit-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#b9def0));background-image:linear-gradient(to bottom,#d9edf7 0,#b9def0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);background-repeat:repeat-x;border-color:#9acfea}.alert-warning{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#f8efc0));background-image:linear-gradient(to bottom,#fcf8e3 0,#f8efc0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);background-repeat:repeat-x;border-color:#f5e79e}.alert-danger{background-image:-webkit-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-o-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#e7c3c3));background-image:linear-gradient(to bottom,#f2dede 0,#e7c3c3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);background-repeat:repeat-x;border-color:#dca7a7}.progress{background-image:-webkit-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#ebebeb),to(#f5f5f5));background-image:linear-gradient(to bottom,#ebebeb 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x}.progress-bar{background-image:-webkit-linear-gradient(top,#337ab7 0,#286090 100%);background-image:-o-linear-gradient(top,#337ab7 0,#286090 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#286090));background-image:linear-gradient(to bottom,#337ab7 0,#286090 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);background-repeat:repeat-x}.progress-bar-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#449d44));background-image:linear-gradient(to bottom,#5cb85c 0,#449d44 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);background-repeat:repeat-x}.progress-bar-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#31b0d5));background-image:linear-gradient(to bottom,#5bc0de 0,#31b0d5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);background-repeat:repeat-x}.progress-bar-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#ec971f));background-image:linear-gradient(to bottom,#f0ad4e 0,#ec971f 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);background-repeat:repeat-x}.progress-bar-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c9302c));background-image:linear-gradient(to bottom,#d9534f 0,#c9302c 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);background-repeat:repeat-x}.progress-bar-striped{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.list-group{border-radius:4px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.list-group-item.active,.list-group-item.active:focus,.list-group-item.active:hover{text-shadow:0 -1px 0 #286090;background-image:-webkit-linear-gradient(top,#337ab7 0,#2b669a 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2b669a 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2b669a));background-image:linear-gradient(to bottom,#337ab7 0,#2b669a 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);background-repeat:repeat-x;border-color:#2b669a}.list-group-item.active .badge,.list-group-item.active:focus .badge,.list-group-item.active:hover .badge{text-shadow:none}.panel{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.05);box-shadow:0 1px 2px rgba(0,0,0,.05)}.panel-default>.panel-heading{background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.panel-primary>.panel-heading{background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}.panel-success>.panel-heading{background-image:-webkit-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#d0e9c6));background-image:linear-gradient(to bottom,#dff0d8 0,#d0e9c6 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);background-repeat:repeat-x}.panel-info>.panel-heading{background-image:-webkit-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#c4e3f3));background-image:linear-gradient(to bottom,#d9edf7 0,#c4e3f3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);background-repeat:repeat-x}.panel-warning>.panel-heading{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#faf2cc));background-image:linear-gradient(to bottom,#fcf8e3 0,#faf2cc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);background-repeat:repeat-x}.panel-danger>.panel-heading{background-image:-webkit-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-o-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#ebcccc));background-image:linear-gradient(to bottom,#f2dede 0,#ebcccc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);background-repeat:repeat-x}.well{background-image:-webkit-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#e8e8e8),to(#f5f5f5));background-image:linear-gradient(to bottom,#e8e8e8 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x;border-color:#dcdcdc;-webkit-box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1)} 6 | /*# sourceMappingURL=bootstrap-theme.min.css.map */ -------------------------------------------------------------------------------- /assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/bootstrap/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /assets/components/site/bootstrap/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/blank.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/blank.gif -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/fancybox_loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/fancybox_loading.gif -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/fancybox_loading@2x.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/fancybox_loading@2x.gif -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/fancybox_overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/fancybox_overlay.png -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/fancybox_sprite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/fancybox_sprite.png -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/fancybox_sprite@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/fancybox_sprite@2x.png -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/fancybox_buttons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/fancybox/source/helpers/fancybox_buttons.png -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/jquery.fancybox-buttons.css: -------------------------------------------------------------------------------- 1 | #fancybox-buttons { 2 | position: fixed; 3 | left: 0; 4 | width: 100%; 5 | z-index: 8050; 6 | } 7 | 8 | #fancybox-buttons.top { 9 | top: 10px; 10 | } 11 | 12 | #fancybox-buttons.bottom { 13 | bottom: 10px; 14 | } 15 | 16 | #fancybox-buttons ul { 17 | display: block; 18 | width: 166px; 19 | height: 30px; 20 | margin: 0 auto; 21 | padding: 0; 22 | list-style: none; 23 | border: 1px solid #111; 24 | border-radius: 3px; 25 | -webkit-box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); 26 | -moz-box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); 27 | box-shadow: inset 0 0 0 1px rgba(255,255,255,.05); 28 | background: rgb(50,50,50); 29 | background: -moz-linear-gradient(top, rgb(68,68,68) 0%, rgb(52,52,52) 50%, rgb(41,41,41) 50%, rgb(51,51,51) 100%); 30 | background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgb(68,68,68)), color-stop(50%,rgb(52,52,52)), color-stop(50%,rgb(41,41,41)), color-stop(100%,rgb(51,51,51))); 31 | background: -webkit-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); 32 | background: -o-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); 33 | background: -ms-linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); 34 | background: linear-gradient(top, rgb(68,68,68) 0%,rgb(52,52,52) 50%,rgb(41,41,41) 50%,rgb(51,51,51) 100%); 35 | filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#444444', endColorstr='#222222',GradientType=0 ); 36 | } 37 | 38 | #fancybox-buttons ul li { 39 | float: left; 40 | margin: 0; 41 | padding: 0; 42 | } 43 | 44 | #fancybox-buttons a { 45 | display: block; 46 | width: 30px; 47 | height: 30px; 48 | text-indent: -9999px; 49 | background-color: transparent; 50 | background-image: url('fancybox_buttons.png'); 51 | background-repeat: no-repeat; 52 | outline: none; 53 | opacity: 0.8; 54 | } 55 | 56 | #fancybox-buttons a:hover { 57 | opacity: 1; 58 | } 59 | 60 | #fancybox-buttons a.btnPrev { 61 | background-position: 5px 0; 62 | } 63 | 64 | #fancybox-buttons a.btnNext { 65 | background-position: -33px 0; 66 | border-right: 1px solid #3e3e3e; 67 | } 68 | 69 | #fancybox-buttons a.btnPlay { 70 | background-position: 0 -30px; 71 | } 72 | 73 | #fancybox-buttons a.btnPlayOn { 74 | background-position: -30px -30px; 75 | } 76 | 77 | #fancybox-buttons a.btnToggle { 78 | background-position: 3px -60px; 79 | border-left: 1px solid #111; 80 | border-right: 1px solid #3e3e3e; 81 | width: 35px 82 | } 83 | 84 | #fancybox-buttons a.btnToggleOn { 85 | background-position: -27px -60px; 86 | } 87 | 88 | #fancybox-buttons a.btnClose { 89 | border-left: 1px solid #111; 90 | width: 35px; 91 | background-position: -56px 0px; 92 | } 93 | 94 | #fancybox-buttons a.btnDisabled { 95 | opacity : 0.4; 96 | cursor: default; 97 | } -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/jquery.fancybox-buttons.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * Buttons helper for fancyBox 3 | * version: 1.0.5 (Mon, 15 Oct 2012) 4 | * @requires fancyBox v2.0 or later 5 | * 6 | * Usage: 7 | * $(".fancybox").fancybox({ 8 | * helpers : { 9 | * buttons: { 10 | * position : 'top' 11 | * } 12 | * } 13 | * }); 14 | * 15 | */ 16 | (function ($) { 17 | //Shortcut for fancyBox object 18 | var F = $.fancybox; 19 | 20 | //Add helper object 21 | F.helpers.buttons = { 22 | defaults : { 23 | skipSingle : false, // disables if gallery contains single image 24 | position : 'top', // 'top' or 'bottom' 25 | tpl : '
' 26 | }, 27 | 28 | list : null, 29 | buttons: null, 30 | 31 | beforeLoad: function (opts, obj) { 32 | //Remove self if gallery do not have at least two items 33 | 34 | if (opts.skipSingle && obj.group.length < 2) { 35 | obj.helpers.buttons = false; 36 | obj.closeBtn = true; 37 | 38 | return; 39 | } 40 | 41 | //Increase top margin to give space for buttons 42 | obj.margin[ opts.position === 'bottom' ? 2 : 0 ] += 30; 43 | }, 44 | 45 | onPlayStart: function () { 46 | if (this.buttons) { 47 | this.buttons.play.attr('title', 'Pause slideshow').addClass('btnPlayOn'); 48 | } 49 | }, 50 | 51 | onPlayEnd: function () { 52 | if (this.buttons) { 53 | this.buttons.play.attr('title', 'Start slideshow').removeClass('btnPlayOn'); 54 | } 55 | }, 56 | 57 | afterShow: function (opts, obj) { 58 | var buttons = this.buttons; 59 | 60 | if (!buttons) { 61 | this.list = $(opts.tpl).addClass(opts.position).appendTo('body'); 62 | 63 | buttons = { 64 | prev : this.list.find('.btnPrev').click( F.prev ), 65 | next : this.list.find('.btnNext').click( F.next ), 66 | play : this.list.find('.btnPlay').click( F.play ), 67 | toggle : this.list.find('.btnToggle').click( F.toggle ), 68 | close : this.list.find('.btnClose').click( F.close ) 69 | } 70 | } 71 | 72 | //Prev 73 | if (obj.index > 0 || obj.loop) { 74 | buttons.prev.removeClass('btnDisabled'); 75 | } else { 76 | buttons.prev.addClass('btnDisabled'); 77 | } 78 | 79 | //Next / Play 80 | if (obj.loop || obj.index < obj.group.length - 1) { 81 | buttons.next.removeClass('btnDisabled'); 82 | buttons.play.removeClass('btnDisabled'); 83 | 84 | } else { 85 | buttons.next.addClass('btnDisabled'); 86 | buttons.play.addClass('btnDisabled'); 87 | } 88 | 89 | this.buttons = buttons; 90 | 91 | this.onUpdate(opts, obj); 92 | }, 93 | 94 | onUpdate: function (opts, obj) { 95 | var toggle; 96 | 97 | if (!this.buttons) { 98 | return; 99 | } 100 | 101 | toggle = this.buttons.toggle.removeClass('btnDisabled btnToggleOn'); 102 | 103 | //Size toggle button 104 | if (obj.canShrink) { 105 | toggle.addClass('btnToggleOn'); 106 | 107 | } else if (!obj.canExpand) { 108 | toggle.addClass('btnDisabled'); 109 | } 110 | }, 111 | 112 | beforeClose: function () { 113 | if (this.list) { 114 | this.list.remove(); 115 | } 116 | 117 | this.list = null; 118 | this.buttons = null; 119 | } 120 | }; 121 | 122 | }(jQuery)); 123 | -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/jquery.fancybox-media.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * Media helper for fancyBox 3 | * version: 1.0.6 (Fri, 14 Jun 2013) 4 | * @requires fancyBox v2.0 or later 5 | * 6 | * Usage: 7 | * $(".fancybox").fancybox({ 8 | * helpers : { 9 | * media: true 10 | * } 11 | * }); 12 | * 13 | * Set custom URL parameters: 14 | * $(".fancybox").fancybox({ 15 | * helpers : { 16 | * media: { 17 | * youtube : { 18 | * params : { 19 | * autoplay : 0 20 | * } 21 | * } 22 | * } 23 | * } 24 | * }); 25 | * 26 | * Or: 27 | * $(".fancybox").fancybox({, 28 | * helpers : { 29 | * media: true 30 | * }, 31 | * youtube : { 32 | * autoplay: 0 33 | * } 34 | * }); 35 | * 36 | * Supports: 37 | * 38 | * Youtube 39 | * http://www.youtube.com/watch?v=opj24KnzrWo 40 | * http://www.youtube.com/embed/opj24KnzrWo 41 | * http://youtu.be/opj24KnzrWo 42 | * http://www.youtube-nocookie.com/embed/opj24KnzrWo 43 | * Vimeo 44 | * http://vimeo.com/40648169 45 | * http://vimeo.com/channels/staffpicks/38843628 46 | * http://vimeo.com/groups/surrealism/videos/36516384 47 | * http://player.vimeo.com/video/45074303 48 | * Metacafe 49 | * http://www.metacafe.com/watch/7635964/dr_seuss_the_lorax_movie_trailer/ 50 | * http://www.metacafe.com/watch/7635964/ 51 | * Dailymotion 52 | * http://www.dailymotion.com/video/xoytqh_dr-seuss-the-lorax-premiere_people 53 | * Twitvid 54 | * http://twitvid.com/QY7MD 55 | * Twitpic 56 | * http://twitpic.com/7p93st 57 | * Instagram 58 | * http://instagr.am/p/IejkuUGxQn/ 59 | * http://instagram.com/p/IejkuUGxQn/ 60 | * Google maps 61 | * http://maps.google.com/maps?q=Eiffel+Tower,+Avenue+Gustave+Eiffel,+Paris,+France&t=h&z=17 62 | * http://maps.google.com/?ll=48.857995,2.294297&spn=0.007666,0.021136&t=m&z=16 63 | * http://maps.google.com/?ll=48.859463,2.292626&spn=0.000965,0.002642&t=m&z=19&layer=c&cbll=48.859524,2.292532&panoid=YJ0lq28OOy3VT2IqIuVY0g&cbp=12,151.58,,0,-15.56 64 | */ 65 | (function ($) { 66 | "use strict"; 67 | 68 | //Shortcut for fancyBox object 69 | var F = $.fancybox, 70 | format = function( url, rez, params ) { 71 | params = params || ''; 72 | 73 | if ( $.type( params ) === "object" ) { 74 | params = $.param(params, true); 75 | } 76 | 77 | $.each(rez, function(key, value) { 78 | url = url.replace( '$' + key, value || '' ); 79 | }); 80 | 81 | if (params.length) { 82 | url += ( url.indexOf('?') > 0 ? '&' : '?' ) + params; 83 | } 84 | 85 | return url; 86 | }; 87 | 88 | //Add helper object 89 | F.helpers.media = { 90 | defaults : { 91 | youtube : { 92 | matcher : /(youtube\.com|youtu\.be|youtube-nocookie\.com)\/(watch\?v=|v\/|u\/|embed\/?)?(videoseries\?list=(.*)|[\w-]{11}|\?listType=(.*)&list=(.*)).*/i, 93 | params : { 94 | autoplay : 1, 95 | autohide : 1, 96 | fs : 1, 97 | rel : 0, 98 | hd : 1, 99 | wmode : 'opaque', 100 | enablejsapi : 1 101 | }, 102 | type : 'iframe', 103 | url : '//www.youtube.com/embed/$3' 104 | }, 105 | vimeo : { 106 | matcher : /(?:vimeo(?:pro)?.com)\/(?:[^\d]+)?(\d+)(?:.*)/, 107 | params : { 108 | autoplay : 1, 109 | hd : 1, 110 | show_title : 1, 111 | show_byline : 1, 112 | show_portrait : 0, 113 | fullscreen : 1 114 | }, 115 | type : 'iframe', 116 | url : '//player.vimeo.com/video/$1' 117 | }, 118 | metacafe : { 119 | matcher : /metacafe.com\/(?:watch|fplayer)\/([\w\-]{1,10})/, 120 | params : { 121 | autoPlay : 'yes' 122 | }, 123 | type : 'swf', 124 | url : function( rez, params, obj ) { 125 | obj.swf.flashVars = 'playerVars=' + $.param( params, true ); 126 | 127 | return '//www.metacafe.com/fplayer/' + rez[1] + '/.swf'; 128 | } 129 | }, 130 | dailymotion : { 131 | matcher : /dailymotion.com\/video\/(.*)\/?(.*)/, 132 | params : { 133 | additionalInfos : 0, 134 | autoStart : 1 135 | }, 136 | type : 'swf', 137 | url : '//www.dailymotion.com/swf/video/$1' 138 | }, 139 | twitvid : { 140 | matcher : /twitvid\.com\/([a-zA-Z0-9_\-\?\=]+)/i, 141 | params : { 142 | autoplay : 0 143 | }, 144 | type : 'iframe', 145 | url : '//www.twitvid.com/embed.php?guid=$1' 146 | }, 147 | twitpic : { 148 | matcher : /twitpic\.com\/(?!(?:place|photos|events)\/)([a-zA-Z0-9\?\=\-]+)/i, 149 | type : 'image', 150 | url : '//twitpic.com/show/full/$1/' 151 | }, 152 | instagram : { 153 | matcher : /(instagr\.am|instagram\.com)\/p\/([a-zA-Z0-9_\-]+)\/?/i, 154 | type : 'image', 155 | url : '//$1/p/$2/media/?size=l' 156 | }, 157 | google_maps : { 158 | matcher : /maps\.google\.([a-z]{2,3}(\.[a-z]{2})?)\/(\?ll=|maps\?)(.*)/i, 159 | type : 'iframe', 160 | url : function( rez ) { 161 | return '//maps.google.' + rez[1] + '/' + rez[3] + '' + rez[4] + '&output=' + (rez[4].indexOf('layer=c') > 0 ? 'svembed' : 'embed'); 162 | } 163 | } 164 | }, 165 | 166 | beforeLoad : function(opts, obj) { 167 | var url = obj.href || '', 168 | type = false, 169 | what, 170 | item, 171 | rez, 172 | params; 173 | 174 | for (what in opts) { 175 | if (opts.hasOwnProperty(what)) { 176 | item = opts[ what ]; 177 | rez = url.match( item.matcher ); 178 | 179 | if (rez) { 180 | type = item.type; 181 | params = $.extend(true, {}, item.params, obj[ what ] || ($.isPlainObject(opts[ what ]) ? opts[ what ].params : null)); 182 | 183 | url = $.type( item.url ) === "function" ? item.url.call( this, rez, params, obj ) : format( item.url, rez, params ); 184 | 185 | break; 186 | } 187 | } 188 | } 189 | 190 | if (type) { 191 | obj.href = url; 192 | obj.type = type; 193 | 194 | obj.autoHeight = false; 195 | } 196 | } 197 | }; 198 | 199 | }(jQuery)); -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/jquery.fancybox-thumbs.css: -------------------------------------------------------------------------------- 1 | #fancybox-thumbs { 2 | position: fixed; 3 | left: 0; 4 | width: 100%; 5 | overflow: hidden; 6 | z-index: 8050; 7 | } 8 | 9 | #fancybox-thumbs.bottom { 10 | bottom: 2px; 11 | } 12 | 13 | #fancybox-thumbs.top { 14 | top: 2px; 15 | } 16 | 17 | #fancybox-thumbs ul { 18 | position: relative; 19 | list-style: none; 20 | margin: 0; 21 | padding: 0; 22 | } 23 | 24 | #fancybox-thumbs ul li { 25 | float: left; 26 | padding: 1px; 27 | opacity: 0.5; 28 | } 29 | 30 | #fancybox-thumbs ul li.active { 31 | opacity: 0.75; 32 | padding: 0; 33 | border: 1px solid #fff; 34 | } 35 | 36 | #fancybox-thumbs ul li:hover { 37 | opacity: 1; 38 | } 39 | 40 | #fancybox-thumbs ul li a { 41 | display: block; 42 | position: relative; 43 | overflow: hidden; 44 | border: 1px solid #222; 45 | background: #111; 46 | outline: none; 47 | } 48 | 49 | #fancybox-thumbs ul li img { 50 | display: block; 51 | position: relative; 52 | border: 0; 53 | padding: 0; 54 | max-width: none; 55 | } -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/helpers/jquery.fancybox-thumbs.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * Thumbnail helper for fancyBox 3 | * version: 1.0.7 (Mon, 01 Oct 2012) 4 | * @requires fancyBox v2.0 or later 5 | * 6 | * Usage: 7 | * $(".fancybox").fancybox({ 8 | * helpers : { 9 | * thumbs: { 10 | * width : 50, 11 | * height : 50 12 | * } 13 | * } 14 | * }); 15 | * 16 | */ 17 | (function ($) { 18 | //Shortcut for fancyBox object 19 | var F = $.fancybox; 20 | 21 | //Add helper object 22 | F.helpers.thumbs = { 23 | defaults : { 24 | width : 50, // thumbnail width 25 | height : 50, // thumbnail height 26 | position : 'bottom', // 'top' or 'bottom' 27 | source : function ( item ) { // function to obtain the URL of the thumbnail image 28 | var href; 29 | 30 | if (item.element) { 31 | href = $(item.element).find('img').attr('src'); 32 | } 33 | 34 | if (!href && item.type === 'image' && item.href) { 35 | href = item.href; 36 | } 37 | 38 | return href; 39 | } 40 | }, 41 | 42 | wrap : null, 43 | list : null, 44 | width : 0, 45 | 46 | init: function (opts, obj) { 47 | var that = this, 48 | list, 49 | thumbWidth = opts.width, 50 | thumbHeight = opts.height, 51 | thumbSource = opts.source; 52 | 53 | //Build list structure 54 | list = ''; 55 | 56 | for (var n = 0; n < obj.group.length; n++) { 57 | list += '
  • '; 58 | } 59 | 60 | this.wrap = $('
    ').addClass(opts.position).appendTo('body'); 61 | this.list = $('').appendTo(this.wrap); 62 | 63 | //Load each thumbnail 64 | $.each(obj.group, function (i) { 65 | var href = thumbSource( obj.group[ i ] ); 66 | 67 | if (!href) { 68 | return; 69 | } 70 | 71 | $("").load(function () { 72 | var width = this.width, 73 | height = this.height, 74 | widthRatio, heightRatio, parent; 75 | 76 | if (!that.list || !width || !height) { 77 | return; 78 | } 79 | 80 | //Calculate thumbnail width/height and center it 81 | widthRatio = width / thumbWidth; 82 | heightRatio = height / thumbHeight; 83 | 84 | parent = that.list.children().eq(i).find('a'); 85 | 86 | if (widthRatio >= 1 && heightRatio >= 1) { 87 | if (widthRatio > heightRatio) { 88 | width = Math.floor(width / heightRatio); 89 | height = thumbHeight; 90 | 91 | } else { 92 | width = thumbWidth; 93 | height = Math.floor(height / widthRatio); 94 | } 95 | } 96 | 97 | $(this).css({ 98 | width : width, 99 | height : height, 100 | top : Math.floor(thumbHeight / 2 - height / 2), 101 | left : Math.floor(thumbWidth / 2 - width / 2) 102 | }); 103 | 104 | parent.width(thumbWidth).height(thumbHeight); 105 | 106 | $(this).hide().appendTo(parent).fadeIn(300); 107 | 108 | }).attr('src', href); 109 | }); 110 | 111 | //Set initial width 112 | this.width = this.list.children().eq(0).outerWidth(true); 113 | 114 | this.list.width(this.width * (obj.group.length + 1)).css('left', Math.floor($(window).width() * 0.5 - (obj.index * this.width + this.width * 0.5))); 115 | }, 116 | 117 | beforeLoad: function (opts, obj) { 118 | //Remove self if gallery do not have at least two items 119 | if (obj.group.length < 2) { 120 | obj.helpers.thumbs = false; 121 | 122 | return; 123 | } 124 | 125 | //Increase bottom margin to give space for thumbs 126 | obj.margin[ opts.position === 'top' ? 0 : 2 ] += ((opts.height) + 15); 127 | }, 128 | 129 | afterShow: function (opts, obj) { 130 | //Check if exists and create or update list 131 | if (this.list) { 132 | this.onUpdate(opts, obj); 133 | 134 | } else { 135 | this.init(opts, obj); 136 | } 137 | 138 | //Set active element 139 | this.list.children().removeClass('active').eq(obj.index).addClass('active'); 140 | }, 141 | 142 | //Center list 143 | onUpdate: function (opts, obj) { 144 | if (this.list) { 145 | this.list.stop(true).animate({ 146 | 'left': Math.floor($(window).width() * 0.5 - (obj.index * this.width + this.width * 0.5)) 147 | }, 150); 148 | } 149 | }, 150 | 151 | beforeClose: function () { 152 | if (this.wrap) { 153 | this.wrap.remove(); 154 | } 155 | 156 | this.wrap = null; 157 | this.list = null; 158 | this.width = 0; 159 | } 160 | } 161 | 162 | }(jQuery)); -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/jquery.fancybox.css: -------------------------------------------------------------------------------- 1 | /*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */ 2 | .fancybox-wrap, 3 | .fancybox-skin, 4 | .fancybox-outer, 5 | .fancybox-inner, 6 | .fancybox-image, 7 | .fancybox-wrap iframe, 8 | .fancybox-wrap object, 9 | .fancybox-nav, 10 | .fancybox-nav span, 11 | .fancybox-tmp 12 | { 13 | padding: 0; 14 | margin: 0; 15 | border: 0; 16 | outline: none; 17 | vertical-align: top; 18 | } 19 | 20 | .fancybox-wrap { 21 | position: absolute; 22 | top: 0; 23 | left: 0; 24 | z-index: 8020; 25 | } 26 | 27 | .fancybox-skin { 28 | position: relative; 29 | background: #f9f9f9; 30 | color: #444; 31 | text-shadow: none; 32 | -webkit-border-radius: 4px; 33 | -moz-border-radius: 4px; 34 | border-radius: 4px; 35 | } 36 | 37 | .fancybox-opened { 38 | z-index: 8030; 39 | } 40 | 41 | .fancybox-opened .fancybox-skin { 42 | -webkit-box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); 43 | -moz-box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); 44 | box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5); 45 | } 46 | 47 | .fancybox-outer, .fancybox-inner { 48 | position: relative; 49 | } 50 | 51 | .fancybox-inner { 52 | overflow: hidden; 53 | } 54 | 55 | .fancybox-type-iframe .fancybox-inner { 56 | -webkit-overflow-scrolling: touch; 57 | } 58 | 59 | .fancybox-error { 60 | color: #444; 61 | font: 14px/20px "Helvetica Neue",Helvetica,Arial,sans-serif; 62 | margin: 0; 63 | padding: 15px; 64 | white-space: nowrap; 65 | } 66 | 67 | .fancybox-image, .fancybox-iframe { 68 | display: block; 69 | width: 100%; 70 | height: 100%; 71 | } 72 | 73 | .fancybox-image { 74 | max-width: 100%; 75 | max-height: 100%; 76 | } 77 | 78 | #fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span { 79 | background-image: url('fancybox_sprite.png'); 80 | } 81 | 82 | #fancybox-loading { 83 | position: fixed; 84 | top: 50%; 85 | left: 50%; 86 | margin-top: -22px; 87 | margin-left: -22px; 88 | background-position: 0 -108px; 89 | opacity: 0.8; 90 | cursor: pointer; 91 | z-index: 8060; 92 | } 93 | 94 | #fancybox-loading div { 95 | width: 44px; 96 | height: 44px; 97 | background: url('fancybox_loading.gif') center center no-repeat; 98 | } 99 | 100 | .fancybox-close { 101 | position: absolute; 102 | top: -18px; 103 | right: -18px; 104 | width: 36px; 105 | height: 36px; 106 | cursor: pointer; 107 | z-index: 8040; 108 | } 109 | 110 | .fancybox-nav { 111 | position: absolute; 112 | top: 0; 113 | width: 40%; 114 | height: 100%; 115 | cursor: pointer; 116 | text-decoration: none; 117 | background: transparent url('blank.gif'); /* helps IE */ 118 | -webkit-tap-highlight-color: rgba(0,0,0,0); 119 | z-index: 8040; 120 | } 121 | 122 | .fancybox-prev { 123 | left: 0; 124 | } 125 | 126 | .fancybox-next { 127 | right: 0; 128 | } 129 | 130 | .fancybox-nav span { 131 | position: absolute; 132 | top: 50%; 133 | width: 36px; 134 | height: 34px; 135 | margin-top: -18px; 136 | cursor: pointer; 137 | z-index: 8040; 138 | visibility: hidden; 139 | } 140 | 141 | .fancybox-prev span { 142 | left: 10px; 143 | background-position: 0 -36px; 144 | } 145 | 146 | .fancybox-next span { 147 | right: 10px; 148 | background-position: 0 -72px; 149 | } 150 | 151 | .fancybox-nav:hover span { 152 | visibility: visible; 153 | } 154 | 155 | .fancybox-tmp { 156 | position: absolute; 157 | top: -99999px; 158 | left: -99999px; 159 | visibility: hidden; 160 | max-width: 99999px; 161 | max-height: 99999px; 162 | overflow: visible !important; 163 | } 164 | 165 | /* Overlay helper */ 166 | 167 | .fancybox-lock { 168 | overflow: hidden !important; 169 | width: auto; 170 | } 171 | 172 | .fancybox-lock body { 173 | overflow: hidden !important; 174 | } 175 | 176 | .fancybox-lock-test { 177 | overflow-y: hidden !important; 178 | } 179 | 180 | .fancybox-overlay { 181 | position: absolute; 182 | top: 0; 183 | left: 0; 184 | overflow: hidden; 185 | display: none; 186 | z-index: 8010; 187 | background: url('fancybox_overlay.png'); 188 | } 189 | 190 | .fancybox-overlay-fixed { 191 | position: fixed; 192 | bottom: 0; 193 | right: 0; 194 | } 195 | 196 | .fancybox-lock .fancybox-overlay { 197 | overflow: auto; 198 | overflow-y: scroll; 199 | } 200 | 201 | /* Title helper */ 202 | 203 | .fancybox-title { 204 | visibility: hidden; 205 | font: normal 13px/20px "Helvetica Neue",Helvetica,Arial,sans-serif; 206 | position: relative; 207 | text-shadow: none; 208 | z-index: 8050; 209 | } 210 | 211 | .fancybox-opened .fancybox-title { 212 | visibility: visible; 213 | } 214 | 215 | .fancybox-title-float-wrap { 216 | position: absolute; 217 | bottom: 0; 218 | right: 50%; 219 | margin-bottom: -35px; 220 | z-index: 8050; 221 | text-align: center; 222 | } 223 | 224 | .fancybox-title-float-wrap .child { 225 | display: inline-block; 226 | margin-right: -100%; 227 | padding: 2px 20px; 228 | background: transparent; /* Fallback for web browsers that doesn't support RGBa */ 229 | background: rgba(0, 0, 0, 0.8); 230 | -webkit-border-radius: 15px; 231 | -moz-border-radius: 15px; 232 | border-radius: 15px; 233 | text-shadow: 0 1px 2px #222; 234 | color: #FFF; 235 | font-weight: bold; 236 | line-height: 24px; 237 | white-space: nowrap; 238 | } 239 | 240 | .fancybox-title-outside-wrap { 241 | position: relative; 242 | margin-top: 10px; 243 | color: #fff; 244 | } 245 | 246 | .fancybox-title-inside-wrap { 247 | padding-top: 10px; 248 | } 249 | 250 | .fancybox-title-over-wrap { 251 | position: absolute; 252 | bottom: 0; 253 | left: 0; 254 | color: #fff; 255 | padding: 10px; 256 | background: #000; 257 | background: rgba(0, 0, 0, .8); 258 | } 259 | 260 | /*Retina graphics!*/ 261 | @media only screen and (-webkit-min-device-pixel-ratio: 1.5), 262 | only screen and (min--moz-device-pixel-ratio: 1.5), 263 | only screen and (min-device-pixel-ratio: 1.5){ 264 | 265 | #fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span { 266 | background-image: url('fancybox_sprite@2x.png'); 267 | background-size: 44px 152px; /*The size of the normal image, half the size of the hi-res image*/ 268 | } 269 | 270 | #fancybox-loading div { 271 | background-image: url('fancybox_loading@2x.gif'); 272 | background-size: 24px 24px; /*The size of the normal image, half the size of the hi-res image*/ 273 | } 274 | } -------------------------------------------------------------------------------- /assets/components/site/fancybox/source/jquery.fancybox.pack.js: -------------------------------------------------------------------------------- 1 | /*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */ 2 | (function(r,G,f,v){var J=f("html"),n=f(r),p=f(G),b=f.fancybox=function(){b.open.apply(this,arguments)},I=navigator.userAgent.match(/msie/i),B=null,s=G.createTouch!==v,t=function(a){return a&&a.hasOwnProperty&&a instanceof f},q=function(a){return a&&"string"===f.type(a)},E=function(a){return q(a)&&0
    ',image:'',iframe:'",error:'

    The requested content cannot be loaded.
    Please try again later.

    ',closeBtn:'',next:'',prev:''},openEffect:"fade",openSpeed:250,openEasing:"swing",openOpacity:!0, 6 | openMethod:"zoomIn",closeEffect:"fade",closeSpeed:250,closeEasing:"swing",closeOpacity:!0,closeMethod:"zoomOut",nextEffect:"elastic",nextSpeed:250,nextEasing:"swing",nextMethod:"changeIn",prevEffect:"elastic",prevSpeed:250,prevEasing:"swing",prevMethod:"changeOut",helpers:{overlay:!0,title:!0},onCancel:f.noop,beforeLoad:f.noop,afterLoad:f.noop,beforeShow:f.noop,afterShow:f.noop,beforeChange:f.noop,beforeClose:f.noop,afterClose:f.noop},group:{},opts:{},previous:null,coming:null,current:null,isActive:!1, 7 | isOpen:!1,isOpened:!1,wrap:null,skin:null,outer:null,inner:null,player:{timer:null,isActive:!1},ajaxLoad:null,imgPreload:null,transitions:{},helpers:{},open:function(a,d){if(a&&(f.isPlainObject(d)||(d={}),!1!==b.close(!0)))return f.isArray(a)||(a=t(a)?f(a).get():[a]),f.each(a,function(e,c){var k={},g,h,j,m,l;"object"===f.type(c)&&(c.nodeType&&(c=f(c)),t(c)?(k={href:c.data("fancybox-href")||c.attr("href"),title:c.data("fancybox-title")||c.attr("title"),isDom:!0,element:c},f.metadata&&f.extend(!0,k, 8 | c.metadata())):k=c);g=d.href||k.href||(q(c)?c:null);h=d.title!==v?d.title:k.title||"";m=(j=d.content||k.content)?"html":d.type||k.type;!m&&k.isDom&&(m=c.data("fancybox-type"),m||(m=(m=c.prop("class").match(/fancybox\.(\w+)/))?m[1]:null));q(g)&&(m||(b.isImage(g)?m="image":b.isSWF(g)?m="swf":"#"===g.charAt(0)?m="inline":q(c)&&(m="html",j=c)),"ajax"===m&&(l=g.split(/\s+/,2),g=l.shift(),l=l.shift()));j||("inline"===m?g?j=f(q(g)?g.replace(/.*(?=#[^\s]+$)/,""):g):k.isDom&&(j=c):"html"===m?j=g:!m&&(!g&& 9 | k.isDom)&&(m="inline",j=c));f.extend(k,{href:g,type:m,content:j,title:h,selector:l});a[e]=k}),b.opts=f.extend(!0,{},b.defaults,d),d.keys!==v&&(b.opts.keys=d.keys?f.extend({},b.defaults.keys,d.keys):!1),b.group=a,b._start(b.opts.index)},cancel:function(){var a=b.coming;a&&!1!==b.trigger("onCancel")&&(b.hideLoading(),b.ajaxLoad&&b.ajaxLoad.abort(),b.ajaxLoad=null,b.imgPreload&&(b.imgPreload.onload=b.imgPreload.onerror=null),a.wrap&&a.wrap.stop(!0,!0).trigger("onReset").remove(),b.coming=null,b.current|| 10 | b._afterZoomOut(a))},close:function(a){b.cancel();!1!==b.trigger("beforeClose")&&(b.unbindEvents(),b.isActive&&(!b.isOpen||!0===a?(f(".fancybox-wrap").stop(!0).trigger("onReset").remove(),b._afterZoomOut()):(b.isOpen=b.isOpened=!1,b.isClosing=!0,f(".fancybox-item, .fancybox-nav").remove(),b.wrap.stop(!0,!0).removeClass("fancybox-opened"),b.transitions[b.current.closeMethod]())))},play:function(a){var d=function(){clearTimeout(b.player.timer)},e=function(){d();b.current&&b.player.isActive&&(b.player.timer= 11 | setTimeout(b.next,b.current.playSpeed))},c=function(){d();p.unbind(".player");b.player.isActive=!1;b.trigger("onPlayEnd")};if(!0===a||!b.player.isActive&&!1!==a){if(b.current&&(b.current.loop||b.current.index=c.index?"next":"prev"],b.router=e||"jumpto",c.loop&&(0>a&&(a=c.group.length+a%c.group.length),a%=c.group.length),c.group[a]!==v&&(b.cancel(),b._start(a)))},reposition:function(a,d){var e=b.current,c=e?e.wrap:null,k;c&&(k=b._getPosition(d),a&&"scroll"===a.type?(delete k.position,c.stop(!0,!0).animate(k,200)):(c.css(k),e.pos=f.extend({},e.dim,k)))},update:function(a){var d= 13 | a&&a.type,e=!d||"orientationchange"===d;e&&(clearTimeout(B),B=null);b.isOpen&&!B&&(B=setTimeout(function(){var c=b.current;c&&!b.isClosing&&(b.wrap.removeClass("fancybox-tmp"),(e||"load"===d||"resize"===d&&c.autoResize)&&b._setDimension(),"scroll"===d&&c.canShrink||b.reposition(a),b.trigger("onUpdate"),B=null)},e&&!s?0:300))},toggle:function(a){b.isOpen&&(b.current.fitToView="boolean"===f.type(a)?a:!b.current.fitToView,s&&(b.wrap.removeAttr("style").addClass("fancybox-tmp"),b.trigger("onUpdate")), 14 | b.update())},hideLoading:function(){p.unbind(".loading");f("#fancybox-loading").remove()},showLoading:function(){var a,d;b.hideLoading();a=f('
    ').click(b.cancel).appendTo("body");p.bind("keydown.loading",function(a){if(27===(a.which||a.keyCode))a.preventDefault(),b.cancel()});b.defaults.fixed||(d=b.getViewport(),a.css({position:"absolute",top:0.5*d.h+d.y,left:0.5*d.w+d.x}))},getViewport:function(){var a=b.current&&b.current.locked||!1,d={x:n.scrollLeft(), 15 | y:n.scrollTop()};a?(d.w=a[0].clientWidth,d.h=a[0].clientHeight):(d.w=s&&r.innerWidth?r.innerWidth:n.width(),d.h=s&&r.innerHeight?r.innerHeight:n.height());return d},unbindEvents:function(){b.wrap&&t(b.wrap)&&b.wrap.unbind(".fb");p.unbind(".fb");n.unbind(".fb")},bindEvents:function(){var a=b.current,d;a&&(n.bind("orientationchange.fb"+(s?"":" resize.fb")+(a.autoCenter&&!a.locked?" scroll.fb":""),b.update),(d=a.keys)&&p.bind("keydown.fb",function(e){var c=e.which||e.keyCode,k=e.target||e.srcElement; 16 | if(27===c&&b.coming)return!1;!e.ctrlKey&&(!e.altKey&&!e.shiftKey&&!e.metaKey&&(!k||!k.type&&!f(k).is("[contenteditable]")))&&f.each(d,function(d,k){if(1h[0].clientWidth||h[0].clientHeight&&h[0].scrollHeight>h[0].clientHeight),h=f(h).parent();if(0!==c&&!j&&1g||0>k)b.next(0>g?"up":"right");d.preventDefault()}}))},trigger:function(a,d){var e,c=d||b.coming||b.current;if(c){f.isFunction(c[a])&&(e=c[a].apply(c,Array.prototype.slice.call(arguments,1)));if(!1===e)return!1;c.helpers&&f.each(c.helpers,function(d,e){if(e&&b.helpers[d]&&f.isFunction(b.helpers[d][a]))b.helpers[d][a](f.extend(!0, 18 | {},b.helpers[d].defaults,e),c)});p.trigger(a)}},isImage:function(a){return q(a)&&a.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i)},isSWF:function(a){return q(a)&&a.match(/\.(swf)((\?|#).*)?$/i)},_start:function(a){var d={},e,c;a=l(a);e=b.group[a]||null;if(!e)return!1;d=f.extend(!0,{},b.opts,e);e=d.margin;c=d.padding;"number"===f.type(e)&&(d.margin=[e,e,e,e]);"number"===f.type(c)&&(d.padding=[c,c,c,c]);d.modal&&f.extend(!0,d,{closeBtn:!1,closeClick:!1,nextClick:!1,arrows:!1, 19 | mouseWheel:!1,keys:null,helpers:{overlay:{closeClick:!1}}});d.autoSize&&(d.autoWidth=d.autoHeight=!0);"auto"===d.width&&(d.autoWidth=!0);"auto"===d.height&&(d.autoHeight=!0);d.group=b.group;d.index=a;b.coming=d;if(!1===b.trigger("beforeLoad"))b.coming=null;else{c=d.type;e=d.href;if(!c)return b.coming=null,b.current&&b.router&&"jumpto"!==b.router?(b.current.index=a,b[b.router](b.direction)):!1;b.isActive=!0;if("image"===c||"swf"===c)d.autoHeight=d.autoWidth=!1,d.scrolling="visible";"image"===c&&(d.aspectRatio= 20 | !0);"iframe"===c&&s&&(d.scrolling="scroll");d.wrap=f(d.tpl.wrap).addClass("fancybox-"+(s?"mobile":"desktop")+" fancybox-type-"+c+" fancybox-tmp "+d.wrapCSS).appendTo(d.parent||"body");f.extend(d,{skin:f(".fancybox-skin",d.wrap),outer:f(".fancybox-outer",d.wrap),inner:f(".fancybox-inner",d.wrap)});f.each(["Top","Right","Bottom","Left"],function(a,b){d.skin.css("padding"+b,w(d.padding[a]))});b.trigger("onReady");if("inline"===c||"html"===c){if(!d.content||!d.content.length)return b._error("content")}else if(!e)return b._error("href"); 21 | "image"===c?b._loadImage():"ajax"===c?b._loadAjax():"iframe"===c?b._loadIframe():b._afterLoad()}},_error:function(a){f.extend(b.coming,{type:"html",autoWidth:!0,autoHeight:!0,minWidth:0,minHeight:0,scrolling:"no",hasError:a,content:b.coming.tpl.error});b._afterLoad()},_loadImage:function(){var a=b.imgPreload=new Image;a.onload=function(){this.onload=this.onerror=null;b.coming.width=this.width/b.opts.pixelRatio;b.coming.height=this.height/b.opts.pixelRatio;b._afterLoad()};a.onerror=function(){this.onload= 22 | this.onerror=null;b._error("image")};a.src=b.coming.href;!0!==a.complete&&b.showLoading()},_loadAjax:function(){var a=b.coming;b.showLoading();b.ajaxLoad=f.ajax(f.extend({},a.ajax,{url:a.href,error:function(a,e){b.coming&&"abort"!==e?b._error("ajax",a):b.hideLoading()},success:function(d,e){"success"===e&&(a.content=d,b._afterLoad())}}))},_loadIframe:function(){var a=b.coming,d=f(a.tpl.iframe.replace(/\{rnd\}/g,(new Date).getTime())).attr("scrolling",s?"auto":a.iframe.scrolling).attr("src",a.href); 23 | f(a.wrap).bind("onReset",function(){try{f(this).find("iframe").hide().attr("src","//about:blank").end().empty()}catch(a){}});a.iframe.preload&&(b.showLoading(),d.one("load",function(){f(this).data("ready",1);s||f(this).bind("load.fb",b.update);f(this).parents(".fancybox-wrap").width("100%").removeClass("fancybox-tmp").show();b._afterLoad()}));a.content=d.appendTo(a.inner);a.iframe.preload||b._afterLoad()},_preloadImages:function(){var a=b.group,d=b.current,e=a.length,c=d.preload?Math.min(d.preload, 24 | e-1):0,f,g;for(g=1;g<=c;g+=1)f=a[(d.index+g)%e],"image"===f.type&&f.href&&((new Image).src=f.href)},_afterLoad:function(){var a=b.coming,d=b.current,e,c,k,g,h;b.hideLoading();if(a&&!1!==b.isActive)if(!1===b.trigger("afterLoad",a,d))a.wrap.stop(!0).trigger("onReset").remove(),b.coming=null;else{d&&(b.trigger("beforeChange",d),d.wrap.stop(!0).removeClass("fancybox-opened").find(".fancybox-item, .fancybox-nav").remove());b.unbindEvents();e=a.content;c=a.type;k=a.scrolling;f.extend(b,{wrap:a.wrap,skin:a.skin, 25 | outer:a.outer,inner:a.inner,current:a,previous:d});g=a.href;switch(c){case "inline":case "ajax":case "html":a.selector?e=f("
    ").html(e).find(a.selector):t(e)&&(e.data("fancybox-placeholder")||e.data("fancybox-placeholder",f('
    ').insertAfter(e).hide()),e=e.show().detach(),a.wrap.bind("onReset",function(){f(this).find(e).length&&e.hide().replaceAll(e.data("fancybox-placeholder")).data("fancybox-placeholder",!1)}));break;case "image":e=a.tpl.image.replace("{href}", 26 | g);break;case "swf":e='',h="",f.each(a.swf,function(a,b){e+='';h+=" "+a+'="'+b+'"'}),e+='"}(!t(e)||!e.parent().is(a.inner))&&a.inner.append(e);b.trigger("beforeShow");a.inner.css("overflow","yes"===k?"scroll": 27 | "no"===k?"hidden":k);b._setDimension();b.reposition();b.isOpen=!1;b.coming=null;b.bindEvents();if(b.isOpened){if(d.prevMethod)b.transitions[d.prevMethod]()}else f(".fancybox-wrap").not(a.wrap).stop(!0).trigger("onReset").remove();b.transitions[b.isOpened?a.nextMethod:a.openMethod]();b._preloadImages()}},_setDimension:function(){var a=b.getViewport(),d=0,e=!1,c=!1,e=b.wrap,k=b.skin,g=b.inner,h=b.current,c=h.width,j=h.height,m=h.minWidth,u=h.minHeight,n=h.maxWidth,p=h.maxHeight,s=h.scrolling,q=h.scrollOutside? 28 | h.scrollbarWidth:0,x=h.margin,y=l(x[1]+x[3]),r=l(x[0]+x[2]),v,z,t,C,A,F,B,D,H;e.add(k).add(g).width("auto").height("auto").removeClass("fancybox-tmp");x=l(k.outerWidth(!0)-k.width());v=l(k.outerHeight(!0)-k.height());z=y+x;t=r+v;C=E(c)?(a.w-z)*l(c)/100:c;A=E(j)?(a.h-t)*l(j)/100:j;if("iframe"===h.type){if(H=h.content,h.autoHeight&&1===H.data("ready"))try{H[0].contentWindow.document.location&&(g.width(C).height(9999),F=H.contents().find("body"),q&&F.css("overflow-x","hidden"),A=F.outerHeight(!0))}catch(G){}}else if(h.autoWidth|| 29 | h.autoHeight)g.addClass("fancybox-tmp"),h.autoWidth||g.width(C),h.autoHeight||g.height(A),h.autoWidth&&(C=g.width()),h.autoHeight&&(A=g.height()),g.removeClass("fancybox-tmp");c=l(C);j=l(A);D=C/A;m=l(E(m)?l(m,"w")-z:m);n=l(E(n)?l(n,"w")-z:n);u=l(E(u)?l(u,"h")-t:u);p=l(E(p)?l(p,"h")-t:p);F=n;B=p;h.fitToView&&(n=Math.min(a.w-z,n),p=Math.min(a.h-t,p));z=a.w-y;r=a.h-r;h.aspectRatio?(c>n&&(c=n,j=l(c/D)),j>p&&(j=p,c=l(j*D)),cz||y>r)&&(c>m&&j>u)&&!(19n&&(c=n,j=l(c/D)),g.width(c).height(j),e.width(c+x),a=e.width(),y=e.height();else c=Math.max(m,Math.min(c,c-(a-z))),j=Math.max(u,Math.min(j,j-(y-r)));q&&("auto"===s&&jz||y>r)&&c>m&&j>u;c=h.aspectRatio?cu&&j
    ').appendTo(b.coming?b.coming.parent:a.parent);this.fixed=!1;a.fixed&&b.defaults.fixed&&(this.overlay.addClass("fancybox-overlay-fixed"),this.fixed=!0)},open:function(a){var d=this;a=f.extend({},this.defaults,a);this.overlay?this.overlay.unbind(".overlay").width("auto").height("auto"):this.create(a);this.fixed||(n.bind("resize.overlay",f.proxy(this.update,this)),this.update());a.closeClick&&this.overlay.bind("click.overlay",function(a){if(f(a.target).hasClass("fancybox-overlay"))return b.isActive? 40 | b.close():d.close(),!1});this.overlay.css(a.css).show()},close:function(){var a,b;n.unbind("resize.overlay");this.el.hasClass("fancybox-lock")&&(f(".fancybox-margin").removeClass("fancybox-margin"),a=n.scrollTop(),b=n.scrollLeft(),this.el.removeClass("fancybox-lock"),n.scrollTop(a).scrollLeft(b));f(".fancybox-overlay").remove().hide();f.extend(this,{overlay:null,fixed:!1})},update:function(){var a="100%",b;this.overlay.width(a).height("100%");I?(b=Math.max(G.documentElement.offsetWidth,G.body.offsetWidth), 41 | p.width()>b&&(a=p.width())):p.width()>n.width()&&(a=p.width());this.overlay.width(a).height(p.height())},onReady:function(a,b){var e=this.overlay;f(".fancybox-overlay").stop(!0,!0);e||this.create(a);a.locked&&(this.fixed&&b.fixed)&&(e||(this.margin=p.height()>n.height()?f("html").css("margin-right").replace("px",""):!1),b.locked=this.overlay.append(b.wrap),b.fixed=!1);!0===a.showEarly&&this.beforeShow.apply(this,arguments)},beforeShow:function(a,b){var e,c;b.locked&&(!1!==this.margin&&(f("*").filter(function(){return"fixed"=== 42 | f(this).css("position")&&!f(this).hasClass("fancybox-overlay")&&!f(this).hasClass("fancybox-wrap")}).addClass("fancybox-margin"),this.el.addClass("fancybox-margin")),e=n.scrollTop(),c=n.scrollLeft(),this.el.addClass("fancybox-lock"),n.scrollTop(e).scrollLeft(c));this.open(a)},onUpdate:function(){this.fixed||this.update()},afterClose:function(a){this.overlay&&!b.coming&&this.overlay.fadeOut(a.speedOut,f.proxy(this.close,this))}};b.helpers.title={defaults:{type:"float",position:"bottom"},beforeShow:function(a){var d= 43 | b.current,e=d.title,c=a.type;f.isFunction(e)&&(e=e.call(d.element,d));if(q(e)&&""!==f.trim(e)){d=f('
    '+e+"
    ");switch(c){case "inside":c=b.skin;break;case "outside":c=b.wrap;break;case "over":c=b.inner;break;default:c=b.skin,d.appendTo("body"),I&&d.width(d.width()),d.wrapInner(''),b.current.margin[2]+=Math.abs(l(d.css("margin-bottom")))}d["top"===a.position?"prependTo":"appendTo"](c)}}};f.fn.fancybox=function(a){var d, 44 | e=f(this),c=this.selector||"",k=function(g){var h=f(this).blur(),j=d,k,l;!g.ctrlKey&&(!g.altKey&&!g.shiftKey&&!g.metaKey)&&!h.is(".fancybox-wrap")&&(k=a.groupAttr||"data-fancybox-group",l=h.attr(k),l||(k="rel",l=h.get(0)[k]),l&&(""!==l&&"nofollow"!==l)&&(h=c.length?f(c):e,h=h.filter("["+k+'="'+l+'"]'),j=h.index(this)),a.index=j,!1!==b.open(h,a)&&g.preventDefault())};a=a||{};d=a.index||0;!c||!1===a.live?e.unbind("click.fb-start").bind("click.fb-start",k):p.undelegate(c,"click.fb-start").delegate(c+ 45 | ":not('.fancybox-item, .fancybox-nav')","click.fb-start",k);this.filter("[data-fancybox-start=1]").trigger("click");return this};p.ready(function(){var a,d;f.scrollbarWidth===v&&(f.scrollbarWidth=function(){var a=f('
    ').appendTo("body"),b=a.children(),b=b.innerWidth()-b.height(99).innerWidth();a.remove();return b});if(f.support.fixedPosition===v){a=f.support;d=f('
    ').appendTo("body");var e=20=== 46 | d[0].offsetTop||15===d[0].offsetTop;d.remove();a.fixedPosition=e}f.extend(b.defaults,{scrollbarWidth:f.scrollbarWidth(),fixed:f.support.fixedPosition,parent:f("body")});a=f(r).width();J.addClass("fancybox-lock-test");d=f(r).width();J.removeClass("fancybox-lock-test");f("").appendTo("head")})})(window,document,jQuery); -------------------------------------------------------------------------------- /assets/components/site/mgr/style.css: -------------------------------------------------------------------------------- 1 | #modx-resource-introtext {height: 60px !important;} 2 | #modx-resource-description {height: 60px !important;} 3 | .x-form-item.modx-tv {padding-left: 0 !important;} 4 | .modx-tv-form-element input {padding: 5px 1% !important; width: 98% !important;} 5 | .modx-richtext {width: 98%;height: 140px;border-color: #E4E4E4;padding: 5px 1%;border-radius: 3px;font-family: inherit;line-height: 120%;} 6 | .tv_modx-grid-multitvgrid_items .x-grid3-body, 7 | .modx-tv-form-element .x-form-field-wrap, 8 | .x-grid3-row {width: 100% !important;} 9 | .modx-js-parse-error {display: none !important;} 10 | -------------------------------------------------------------------------------- /assets/components/site/web/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/favicon.ico -------------------------------------------------------------------------------- /assets/components/site/web/img/gal1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal1.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/gal2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal2.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/gal3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal3.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/gal4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal4.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/gal5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal5.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/gal6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/gal6.jpg -------------------------------------------------------------------------------- /assets/components/site/web/img/spec1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/spec1.png -------------------------------------------------------------------------------- /assets/components/site/web/img/spec2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/spec2.png -------------------------------------------------------------------------------- /assets/components/site/web/img/spec3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/spec3.png -------------------------------------------------------------------------------- /assets/components/site/web/img/spec4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/spec4.png -------------------------------------------------------------------------------- /assets/components/site/web/img/spec5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ilyautkin/siteExtra/c705a8cdd86d8e4b0e4ee55136215f25b3ce89c9/assets/components/site/web/img/spec5.png -------------------------------------------------------------------------------- /assets/components/site/web/js/script.js: -------------------------------------------------------------------------------- 1 | $(document).ready(function() { 2 | // Fix image margins in content 3 | $("#content img, .galleryouter img").each(function() { 4 | var marginLable = ''; 5 | if ($(this).css("float") != 'none') { 6 | marginLable = "margin-" + $(this).css("float"); 7 | } 8 | var imgStyle = { 9 | "display": "inline-block", 10 | "vertical-align": "top", 11 | "margin-right": "10px", 12 | "margin-left": "10px", 13 | "margin-bottom": "10px", 14 | "background": "#fff", 15 | "padding": "5px", 16 | "border": "1px solid #d0dae3" 17 | }; 18 | if (marginLable) { 19 | imgStyle[marginLable] = 0; 20 | } else { 21 | imgStyle["margin-left"] = 0; 22 | } 23 | $(this).css(imgStyle); 24 | 25 | }); 26 | }); 27 | 28 | // FancyBox initialization 29 | $(".fancybox2").fancybox({ 30 | padding: 0, 31 | 32 | minWidth: 100, 33 | minHeight: 100, 34 | 35 | maxWidth: 800, 36 | maxHeight: 600, 37 | 38 | autoPlay: false, 39 | playSpeed: 3000, 40 | 41 | openEffect: "elastic", 42 | openSpeed: 150, 43 | 44 | closeEffect: "elastic", 45 | closeSpeed: 150, 46 | 47 | closeClick: true, 48 | titleShow: false, 49 | loop: false, 50 | title: "", 51 | 52 | helpers: { 53 | overlay: { 54 | closeClick: true, 55 | speedOut: 200, 56 | showEarly: true, 57 | css: {}, 58 | locked: true 59 | } 60 | } 61 | }); 62 | -------------------------------------------------------------------------------- /core/components/site/docs/changelog.txt: -------------------------------------------------------------------------------- 1 | 1.5.3-pl 2 | ============== 3 | - Added CKEditor base64image plugin 4 | 5 | 1.5.2-pl 6 | ============== 7 | - Added English translate 8 | 9 | 1.5.1-pl 10 | ============== 11 | - Added logRotation extra 12 | 13 | 1.5.0-pl 14 | ============== 15 | - Contact fields moved to ClientConfig 16 | - Renamed content chunks (content_spec and content_spec_list) 17 | 18 | 1.4.8-rc 19 | ============== 20 | - Sistem setting log_deprecated set false 21 | 22 | 1.4.7-rc 23 | ============== 24 | - Site_url changed to http_host in emails 25 | - Fenom syntax changed to short version 26 | - Container suffix and html-extention are removed 27 | - Added manager favicon 28 | 29 | 1.4.6-rc 30 | ============== 31 | - Added SmushIt addon 32 | - Added favicon.ico 33 | - Added quote and asterisk to friendly_alias_restrict_chars_pattern 34 | 35 | 1.4.5-beta 36 | ============== 37 | - Hide modx parse error window 38 | - Fix width for MIGX multiform field 39 | - Richtext field styles 40 | - Content is default for description tag 41 | - strtolower in SiteRedirect plugin 42 | 43 | 1.4.4-beta 44 | ============== 45 | - Fix addManagerCss bug 46 | - Fix elements columns of MIGX tv 47 | 48 | 1.4.3-beta 49 | ============== 50 | - New TVs: subtitle, keywords, elements 51 | - Sample of extending chunks 52 | - Sample using contact_form in contacts 53 | - Replace assets and siteextra path in chunk head 54 | 55 | 1.4.2-beta 56 | ============== 57 | - Added og:image meta tag 58 | - Added css fot TVTable plugin 59 | 60 | 1.4.1-beta 61 | ============== 62 | - Snippets "years" and "contain" removed 63 | - Checking for execute set_start_year resolver 64 | 65 | 1.4.0-beta 66 | ============== 67 | - Syntax of templates changed to Fenom 68 | 69 | 1.3.2-beta 70 | ============== 71 | - Fix setup on 2.5.7 72 | 73 | 1.3.1-beta 74 | ============== 75 | - Removing FancyBox3 76 | 77 | 1.3.0-beta 78 | ============== 79 | - Selecting addons to install 80 | 81 | 1.2.5-beta 82 | ============== 83 | - Added snippet clearPhone 84 | - Added redirect from index.php 85 | - FancyBox2 replaced by Fancybox3 86 | - Script for AjaxForm moved to footer 87 | 88 | 1.2.4-beta 89 | ============== 90 | - Script for AjaxForm moved to scripts.js 91 | 92 | 1.2.3-beta 93 | ============== 94 | - Uncacheable http_host and site_url 95 | - Added class row for menu 96 | - Set current year for start parameter of snippet year 97 | - Added emailFrom to AjaxForm call 98 | - Script for message in window moved to footer 99 | - Added show_on_page TV 100 | - 404 page hide in site map 101 | 102 | 1.2.2-beta 103 | ============== 104 | - Prefix for img separated by dash 105 | - Chunks and templates will not updates 106 | 107 | 1.2.1-beta 108 | ============== 109 | - Right URIs for children 110 | - Plugin "siteRedirect" disabled 111 | - Prefix for img TV 112 | - Excludes for sitemap.xml 113 | - Http_host to robots.txt 114 | - Comma excludes from URIs (settings) 115 | - Path for CSS-file in plugin 116 | 117 | 1.2.0-beta 118 | ============== 119 | - Added site_folder_name for customize extra 120 | 121 | 1.1.9-beta 122 | ============== 123 | - Fix 404 setting 124 | 125 | 1.1.8-beta 126 | ============== 127 | - Customize specs list 128 | 129 | 1.1.7-beta 130 | ============== 131 | - Images optimized 132 | - Fix template & category setting 133 | 134 | 1.1.6-beta 135 | ============== 136 | - Aside and mainpage 137 | 138 | 1.1.5-beta 139 | ============== 140 | - Bootstrap template 141 | - Content for resources 142 | - MIGX Gallery & Fancybox 143 | 144 | 1.1.4-beta 145 | ============== 146 | - Add snippets 147 | - Add TV show_child 148 | 149 | 1.1.3-beta 150 | ============== 151 | - Add template 152 | 153 | 1.1.2-beta 154 | ============== 155 | - Add siteRedirect 156 | - Add DirectResize 157 | 158 | 1.1.1-beta 159 | ============== 160 | - Form customisation 161 | - Add manager CSS 162 | 163 | 1.1.0-beta 164 | ============== 165 | - Added fixes and resolvers 166 | 167 | 1.0.0-beta 168 | ============== 169 | - First release -------------------------------------------------------------------------------- /core/components/site/docs/friendly_alias_restrict_chars_pattern.txt: -------------------------------------------------------------------------------- 1 | /[\0\x0B\t\n\r\f\a&=+%#«»*<>"~,:`@\?\[\]\{\}\|\^'\\]/ 2 | -------------------------------------------------------------------------------- /core/components/site/docs/license.txt: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 2, June 1991 3 | -------------------------- 4 | 5 | Copyright (C) 1989, 1991 Free Software Foundation, Inc. 6 | 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 7 | 8 | Everyone is permitted to copy and distribute verbatim copies 9 | of this license document, but changing it is not allowed. 10 | 11 | Preamble 12 | -------- 13 | 14 | The licenses for most software are designed to take away your 15 | freedom to share and change it. By contrast, the GNU General Public 16 | License is intended to guarantee your freedom to share and change free 17 | software--to make sure the software is free for all its users. This 18 | General Public License applies to most of the Free Software 19 | Foundation's software and to any other program whose authors commit to 20 | using it. (Some other Free Software Foundation software is covered by 21 | the GNU Library General Public License instead.) You can apply it to 22 | your programs, too. 23 | 24 | When we speak of free software, we are referring to freedom, not 25 | price. Our General Public Licenses are designed to make sure that you 26 | have the freedom to distribute copies of free software (and charge for 27 | this service if you wish), that you receive source code or can get it 28 | if you want it, that you can change the software or use pieces of it 29 | in new free programs; and that you know you can do these things. 30 | 31 | To protect your rights, we need to make restrictions that forbid 32 | anyone to deny you these rights or to ask you to surrender the rights. 33 | These restrictions translate to certain responsibilities for you if you 34 | distribute copies of the software, or if you modify it. 35 | 36 | For example, if you distribute copies of such a program, whether 37 | gratis or for a fee, you must give the recipients all the rights that 38 | you have. You must make sure that they, too, receive or can get the 39 | source code. And you must show them these terms so they know their 40 | rights. 41 | 42 | We protect your rights with two steps: (1) copyright the software, and 43 | (2) offer you this license which gives you legal permission to copy, 44 | distribute and/or modify the software. 45 | 46 | Also, for each author's protection and ours, we want to make certain 47 | that everyone understands that there is no warranty for this free 48 | software. If the software is modified by someone else and passed on, we 49 | want its recipients to know that what they have is not the original, so 50 | that any problems introduced by others will not reflect on the original 51 | authors' reputations. 52 | 53 | Finally, any free program is threatened constantly by software 54 | patents. We wish to avoid the danger that redistributors of a free 55 | program will individually obtain patent licenses, in effect making the 56 | program proprietary. To prevent this, we have made it clear that any 57 | patent must be licensed for everyone's free use or not licensed at all. 58 | 59 | The precise terms and conditions for copying, distribution and 60 | modification follow. 61 | 62 | 63 | GNU GENERAL PUBLIC LICENSE 64 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 65 | --------------------------------------------------------------- 66 | 67 | 0. This License applies to any program or other work which contains 68 | a notice placed by the copyright holder saying it may be distributed 69 | under the terms of this General Public License. The "Program", below, 70 | refers to any such program or work, and a "work based on the Program" 71 | means either the Program or any derivative work under copyright law: 72 | that is to say, a work containing the Program or a portion of it, 73 | either verbatim or with modifications and/or translated into another 74 | language. (Hereinafter, translation is included without limitation in 75 | the term "modification".) Each licensee is addressed as "you". 76 | 77 | Activities other than copying, distribution and modification are not 78 | covered by this License; they are outside its scope. The act of 79 | running the Program is not restricted, and the output from the Program 80 | is covered only if its contents constitute a work based on the 81 | Program (independent of having been made by running the Program). 82 | Whether that is true depends on what the Program does. 83 | 84 | 1. You may copy and distribute verbatim copies of the Program's 85 | source code as you receive it, in any medium, provided that you 86 | conspicuously and appropriately publish on each copy an appropriate 87 | copyright notice and disclaimer of warranty; keep intact all the 88 | notices that refer to this License and to the absence of any warranty; 89 | and give any other recipients of the Program a copy of this License 90 | along with the Program. 91 | 92 | You may charge a fee for the physical act of transferring a copy, and 93 | you may at your option offer warranty protection in exchange for a fee. 94 | 95 | 2. You may modify your copy or copies of the Program or any portion 96 | of it, thus forming a work based on the Program, and copy and 97 | distribute such modifications or work under the terms of Section 1 98 | above, provided that you also meet all of these conditions: 99 | 100 | a) You must cause the modified files to carry prominent notices 101 | stating that you changed the files and the date of any change. 102 | 103 | b) You must cause any work that you distribute or publish, that in 104 | whole or in part contains or is derived from the Program or any 105 | part thereof, to be licensed as a whole at no charge to all third 106 | parties under the terms of this License. 107 | 108 | c) If the modified program normally reads commands interactively 109 | when run, you must cause it, when started running for such 110 | interactive use in the most ordinary way, to print or display an 111 | announcement including an appropriate copyright notice and a 112 | notice that there is no warranty (or else, saying that you provide 113 | a warranty) and that users may redistribute the program under 114 | these conditions, and telling the user how to view a copy of this 115 | License. (Exception: if the Program itself is interactive but 116 | does not normally print such an announcement, your work based on 117 | the Program is not required to print an announcement.) 118 | 119 | These requirements apply to the modified work as a whole. If 120 | identifiable sections of that work are not derived from the Program, 121 | and can be reasonably considered independent and separate works in 122 | themselves, then this License, and its terms, do not apply to those 123 | sections when you distribute them as separate works. But when you 124 | distribute the same sections as part of a whole which is a work based 125 | on the Program, the distribution of the whole must be on the terms of 126 | this License, whose permissions for other licensees extend to the 127 | entire whole, and thus to each and every part regardless of who wrote it. 128 | 129 | Thus, it is not the intent of this section to claim rights or contest 130 | your rights to work written entirely by you; rather, the intent is to 131 | exercise the right to control the distribution of derivative or 132 | collective works based on the Program. 133 | 134 | In addition, mere aggregation of another work not based on the Program 135 | with the Program (or with a work based on the Program) on a volume of 136 | a storage or distribution medium does not bring the other work under 137 | the scope of this License. 138 | 139 | 3. You may copy and distribute the Program (or a work based on it, 140 | under Section 2) in object code or executable form under the terms of 141 | Sections 1 and 2 above provided that you also do one of the following: 142 | 143 | a) Accompany it with the complete corresponding machine-readable 144 | source code, which must be distributed under the terms of Sections 145 | 1 and 2 above on a medium customarily used for software interchange; or, 146 | 147 | b) Accompany it with a written offer, valid for at least three 148 | years, to give any third party, for a charge no more than your 149 | cost of physically performing source distribution, a complete 150 | machine-readable copy of the corresponding source code, to be 151 | distributed under the terms of Sections 1 and 2 above on a medium 152 | customarily used for software interchange; or, 153 | 154 | c) Accompany it with the information you received as to the offer 155 | to distribute corresponding source code. (This alternative is 156 | allowed only for noncommercial distribution and only if you 157 | received the program in object code or executable form with such 158 | an offer, in accord with Subsection b above.) 159 | 160 | The source code for a work means the preferred form of the work for 161 | making modifications to it. For an executable work, complete source 162 | code means all the source code for all modules it contains, plus any 163 | associated interface definition files, plus the scripts used to 164 | control compilation and installation of the executable. However, as a 165 | special exception, the source code distributed need not include 166 | anything that is normally distributed (in either source or binary 167 | form) with the major components (compiler, kernel, and so on) of the 168 | operating system on which the executable runs, unless that component 169 | itself accompanies the executable. 170 | 171 | If distribution of executable or object code is made by offering 172 | access to copy from a designated place, then offering equivalent 173 | access to copy the source code from the same place counts as 174 | distribution of the source code, even though third parties are not 175 | compelled to copy the source along with the object code. 176 | 177 | 4. You may not copy, modify, sublicense, or distribute the Program 178 | except as expressly provided under this License. Any attempt 179 | otherwise to copy, modify, sublicense or distribute the Program is 180 | void, and will automatically terminate your rights under this License. 181 | However, parties who have received copies, or rights, from you under 182 | this License will not have their licenses terminated so long as such 183 | parties remain in full compliance. 184 | 185 | 5. You are not required to accept this License, since you have not 186 | signed it. However, nothing else grants you permission to modify or 187 | distribute the Program or its derivative works. These actions are 188 | prohibited by law if you do not accept this License. Therefore, by 189 | modifying or distributing the Program (or any work based on the 190 | Program), you indicate your acceptance of this License to do so, and 191 | all its terms and conditions for copying, distributing or modifying 192 | the Program or works based on it. 193 | 194 | 6. Each time you redistribute the Program (or any work based on the 195 | Program), the recipient automatically receives a license from the 196 | original licensor to copy, distribute or modify the Program subject to 197 | these terms and conditions. You may not impose any further 198 | restrictions on the recipients' exercise of the rights granted herein. 199 | You are not responsible for enforcing compliance by third parties to 200 | this License. 201 | 202 | 7. If, as a consequence of a court judgment or allegation of patent 203 | infringement or for any other reason (not limited to patent issues), 204 | conditions are imposed on you (whether by court order, agreement or 205 | otherwise) that contradict the conditions of this License, they do not 206 | excuse you from the conditions of this License. If you cannot 207 | distribute so as to satisfy simultaneously your obligations under this 208 | License and any other pertinent obligations, then as a consequence you 209 | may not distribute the Program at all. For example, if a patent 210 | license would not permit royalty-free redistribution of the Program by 211 | all those who receive copies directly or indirectly through you, then 212 | the only way you could satisfy both it and this License would be to 213 | refrain entirely from distribution of the Program. 214 | 215 | If any portion of this section is held invalid or unenforceable under 216 | any particular circumstance, the balance of the section is intended to 217 | apply and the section as a whole is intended to apply in other 218 | circumstances. 219 | 220 | It is not the purpose of this section to induce you to infringe any 221 | patents or other property right claims or to contest validity of any 222 | such claims; this section has the sole purpose of protecting the 223 | integrity of the free software distribution system, which is 224 | implemented by public license practices. Many people have made 225 | generous contributions to the wide range of software distributed 226 | through that system in reliance on consistent application of that 227 | system; it is up to the author/donor to decide if he or she is willing 228 | to distribute software through any other system and a licensee cannot 229 | impose that choice. 230 | 231 | This section is intended to make thoroughly clear what is believed to 232 | be a consequence of the rest of this License. 233 | 234 | 8. If the distribution and/or use of the Program is restricted in 235 | certain countries either by patents or by copyrighted interfaces, the 236 | original copyright holder who places the Program under this License 237 | may add an explicit geographical distribution limitation excluding 238 | those countries, so that distribution is permitted only in or among 239 | countries not thus excluded. In such case, this License incorporates 240 | the limitation as if written in the body of this License. 241 | 242 | 9. The Free Software Foundation may publish revised and/or new versions 243 | of the General Public License from time to time. Such new versions will 244 | be similar in spirit to the present version, but may differ in detail to 245 | address new problems or concerns. 246 | 247 | Each version is given a distinguishing version number. If the Program 248 | specifies a version number of this License which applies to it and "any 249 | later version", you have the option of following the terms and conditions 250 | either of that version or of any later version published by the Free 251 | Software Foundation. If the Program does not specify a version number of 252 | this License, you may choose any version ever published by the Free Software 253 | Foundation. 254 | 255 | 10. If you wish to incorporate parts of the Program into other free 256 | programs whose distribution conditions are different, write to the author 257 | to ask for permission. For software which is copyrighted by the Free 258 | Software Foundation, write to the Free Software Foundation; we sometimes 259 | make exceptions for this. Our decision will be guided by the two goals 260 | of preserving the free status of all derivatives of our free software and 261 | of promoting the sharing and reuse of software generally. 262 | 263 | NO WARRANTY 264 | ----------- 265 | 266 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 267 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 268 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 269 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 270 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 271 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 272 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 273 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 274 | REPAIR OR CORRECTION. 275 | 276 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 277 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 278 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 279 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 280 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 281 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 282 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 283 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 284 | POSSIBILITY OF SUCH DAMAGES. 285 | 286 | --------------------------- 287 | END OF TERMS AND CONDITIONS -------------------------------------------------------------------------------- /core/components/site/docs/readme.txt: -------------------------------------------------------------------------------- 1 | Site package for MODx Revolution. -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.aside.html: -------------------------------------------------------------------------------- 1 |

    2 | {'pdoResources' | snippet : [ 3 | 'parents' => SITE_NEWS_ID, 4 | 'limit' => 3, 5 | 'tpl' => '@INLINE
    6 | {if $img} 7 |
    8 | 9 | {$pagetitle} 10 | 11 |
    12 | {/if} 13 |
    14 |

    {$pagetitle}

    15 |

    {$publishedon | date_format : "%d.%m.%Y г."}

    16 | {$content | striptags | ellipsis : "110"} 17 |
    18 |
    ', 19 | 'includeContent' => 1, 20 | 'includeTVs' => 'img', 21 | 'tvPrefix' => '', 22 | ]} 23 |

    24 |

    Наши специалисты

    25 |
    26 |
    27 | {'pdoResources' | snippet : [ 28 | 'parents' => SITE_SPECS_ID, 29 | 'limit' => 2, 30 | 'sortby' => '{"menuindex":"ASC"}', 31 | 'tpl' => '@INLINE
    32 |
    33 | 34 | {$pagetitle} 35 | 36 |
    37 |

    38 | {$pagetitle}
    39 | {$subtitle} 40 |

    41 |
    42 |
    43 |
    ', 44 | 'includeContent' => 1, 45 | 'includeTVs' => 'img,subtitle', 46 | 'tvPrefix' => '', 47 | ]} 48 | 72 |
    73 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.block_gallery.html: -------------------------------------------------------------------------------- 1 | {var $gallery = SITE_GALLERY_ID | resource : 'elements' | fromJSON} 2 |
    3 | {foreach $gallery as $idx => $galItem} 4 | {if $idx == 3} 5 |
    6 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.child_list.html: -------------------------------------------------------------------------------- 1 |
    2 |
    3 |
    4 | {'!pdoPage' | snippet : [ 5 | 'ajaxMode' => 'default', 6 | 7 | 'tpl' => '@INLINE
    8 | {if $img} 9 |
    10 | 11 | {$pagetitle} 12 | 13 |
    14 | {/if} 15 |
    16 |

    {$pagetitle}

    17 |

    {$publishedon | date_format : "%d.%m.%Y г."}

    18 | {$content | striptags | ellipsis : "250"} 19 |
    20 |
    ', 21 | 'limit' => 15, 22 | 'includeTVs' => 'img', 23 | 'tvPrefix' => '', 24 | 'includeContent' => 1, 25 | 26 | 'tplPageWrapper' => '@INLINE ', 27 | 'tplPage' => '@INLINE
  • {$pageNo}
  • ', 28 | 'tplPageActive' => '@INLINE
  • {$pageNo}
  • ', 29 | 'tplPagePrev' => '@INLINE ', 30 | 'tplPageNext' => '@INLINE ', 31 | 'tplPagePrevEmpty' => '@INLINE ', 32 | 'tplPageNextEmpty' => '@INLINE ', 33 | 'ajaxElemWrapper' => '#child_list', 34 | 'ajaxElemRows' => '#child_list .rows', 35 | 'ajaxElemPagination' => '#child_list .pagination', 36 | 'ajaxElemLink' => '#child_list .pagination a', 37 | ]} 38 |
    39 | {$_modx->getPlaceholder('page.nav')} 40 |
    -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.contact_form.html: -------------------------------------------------------------------------------- 1 | {var $form = $form ?: 'form.contact_form'} 2 | {var $tpl = $tpl ?: 'tpl.contact_form'} 3 | {var $subject = $subject ?: 'Сообщение с сайта ' ~ $_modx->config.http_host} 4 | {var $validate = $validate ?: 'name:required,phone:required,check:required'} 5 | {var $success = $success ?: '

    Ваше сообщение отправлено


    Наши специалисты свяжутся с вами
    в ближайшее время.



    '} 6 | {var $error = $error ?: 'В форме содержатся ошибки!'} 7 | {var $emailto = $emailto ?: $_modx->config.emailto} 8 | 9 | {'!AjaxForm' | snippet : [ 10 | 'snippet' => 'FormIt', 11 | 'hooks' => 'email', 12 | 'form' => $form, 13 | 'emailFrom' => $_modx->config.emailsender, 14 | 'emailSubject' => $subject, 15 | 'emailTo' => $emailto, 16 | 'emailTpl' => $tpl, 17 | 'successMessage' => $success, 18 | 'validate' => $validate, 19 | 'validationErrorMessage' => $error, 20 | 'name.vTextRequired' => 'Пожалуйста, укажите, как к вам обращаться', 21 | 'phone.vTextRequired' => 'Оставьте свой номер телефона, чтобы мы могли с вами связаться', 22 | 'check.vTextRequired' => 'Вы должны дать разрешение на обработку своих персональных данных', 23 | ]} 24 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.content.html: -------------------------------------------------------------------------------- 1 | {var $default = true} 2 | {switch $_modx->resource.id} 3 | {case SITE_START_ID} 4 | {var $default = false} 5 | {include 'content_main'} 6 | {case SITE_SPECS_ID} 7 | {var $default = false} 8 | {include 'content_spec_list'} 9 | {/switch} 10 | {switch $_modx->resource.parent} 11 | {case SITE_SPECS_ID} 12 | {var $default = false} 13 | {include 'content_spec'} 14 | {/switch} 15 | {if $default} 16 | {include 'content_default'} 17 | {/if} 18 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.content_default.html: -------------------------------------------------------------------------------- 1 | {block 'wrapper'} 2 |

    {$_modx->resource.longtitle ?: $_modx->resource.pagetitle}

    3 | {block 'before_content'}{/block} 4 | {block 'content'} 5 | {var $show_on_page = $_modx->resource.show_on_page} 6 | {if $show_on_page | match : '*content*'} 7 | {$_modx->resource.content} 8 | {/if} 9 | {if $show_on_page | match : '*gallery*'} 10 | {include 'gallery'} 11 | {/if} 12 | {if $show_on_page | match : '*children*'} 13 | {include 'child_list'} 14 | {/if} 15 | {/block} 16 | {block 'after_content'}{/block} 17 | {/block} 18 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.content_main.html: -------------------------------------------------------------------------------- 1 | {extends 'content_default'} 2 | {block 'after_content'} 3 | {include 'block.gallery'} 4 | {/block} -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.content_spec.html: -------------------------------------------------------------------------------- 1 | {extends 'content_default'} 2 | {block 'before_content'} 3 | {if $_modx->resource.img} 4 | {$pagetitle} 5 | {/if} 6 | {if $_modx->resource.subtitle} 7 |

    {$_modx->resource.subtitle}

    8 | {/if} 9 | {/block} -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.content_spec_list.html: -------------------------------------------------------------------------------- 1 | {extends 'content_default'} 2 | {block 'after_content'} 3 |
    4 |
    5 |
    6 | {'!pdoPage' | snippet : [ 7 | 'ajaxMode' => 'default', 8 | 9 | 'tpl' => '@INLINE
    10 |
    11 | 12 | {$pagetitle} 13 | 14 |
    15 |

    16 | {$pagetitle}
    17 | {$subtitle} 18 |

    19 |
    20 |
    21 |
    ', 22 | 'limit' => 15, 23 | 'sortby' => '{"menuindex":"ASC"}', 24 | 'includeTVs' => 'img,subtitle', 25 | 'tvPrefix' => '', 26 | 'includeContent' => 1, 27 | 28 | 'tplPageWrapper' => '@INLINE ', 29 | 'tplPage' => '@INLINE
  • {$pageNo}
  • ', 30 | 'tplPageActive' => '@INLINE
  • {$pageNo}
  • ', 31 | 'tplPagePrev' => '@INLINE ', 32 | 'tplPageNext' => '@INLINE ', 33 | 'tplPagePrevEmpty' => '@INLINE ', 34 | 'tplPageNextEmpty' => '@INLINE ', 35 | 'ajaxElemWrapper' => '#child_list', 36 | 'ajaxElemRows' => '#child_list .rows', 37 | 'ajaxElemPagination' => '#child_list .pagination', 38 | 'ajaxElemLink' => '#child_list .pagination a', 39 | ]} 40 |
    41 | {$_modx->getPlaceholder('page.nav')} 42 |
    43 | {/block} -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.footer.html: -------------------------------------------------------------------------------- 1 |
    2 |
    3 |
    4 |
    5 |

    © 6 | {var $year = '' | date : 'Y'} 7 | {if $year == 2016}2016{else}2016—{$year}{/if} 8 | {$_modx->config.site_name} 9 |

    10 |
    11 |
    12 |

    13 | Илья Уткин 14 |

    15 |
    16 |
    17 |
    18 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.form_contact_form.html: -------------------------------------------------------------------------------- 1 |

    Задать вопрос


    2 |
    3 | 4 |
    5 | 6 |
    7 | 8 | 9 |
    10 |
    11 | 12 |
    13 | 14 |
    15 | 16 | 17 |
    18 |
    19 | 20 |
    21 | 22 |
    23 | 24 | 25 |
    26 |
    27 | 28 |
    29 | 30 |
    31 |
    32 | 36 |
    37 |
    38 | 39 |
    40 | 41 |
    42 |
    43 | 44 | 45 |
    46 |
    47 | 48 |
    49 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.gallery.html: -------------------------------------------------------------------------------- 1 | {var $gallery = $_modx->resource.elements | fromJSON} 2 |
    3 | {foreach $gallery as $galItem} 4 |
    5 |
    6 | 8 | {$galItem.title} 9 | 10 |
    11 |
    12 | {/foreach} 13 |
    -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.head.html: -------------------------------------------------------------------------------- 1 | {$_modx->resource.pagetitle} 2 | 3 | 4 | 5 | 6 | 7 | {if $_modx->resource.searchable} 8 | {else}{/if} 9 | {if !$_modx->resource.description && !($_modx->resource.content | ellipsis : "500" | match : '*{*')} 10 | {var $description = $_modx->resource.content | stripmodxtags | striptags | strip : true | ellipsis : "180"} 11 | {else}{var $description = $_modx->resource.description}{/if} 12 | 13 | 14 | {if $_modx->resource.img}{/if} 15 | 16 | 17 | 18 | 19 | 20 | 24 | 25 | {'!MinifyX' | snippet : [ 26 | 'minifyCss' => 1, 27 | 'minifyJs' => 1, 28 | 'cssSources' => 'ASSETS_URLcomponents/SITE_FOLDER_NAME/bootstrap/css/bootstrap.min.css,' ~ 29 | 'ASSETS_URLcomponents/SITE_FOLDER_NAME/fancybox/source/jquery.fancybox.css', 30 | 'jsSources' => 'ASSETS_URLcomponents/SITE_FOLDER_NAME/bootstrap/js/bootstrap.min.js,' ~ 31 | 'ASSETS_URLcomponents/SITE_FOLDER_NAME/fancybox/source/jquery.fancybox.pack.js,' ~ 32 | 'ASSETS_URLcomponents/SITE_FOLDER_NAME/web/js/script.js,' 33 | ]} 34 | {'MinifyX.css' | placeholder} 35 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.header.html: -------------------------------------------------------------------------------- 1 | 20 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.menu.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.scripts.html: -------------------------------------------------------------------------------- 1 | {'MinifyX.javascript' | placeholder} 2 | 19 | -------------------------------------------------------------------------------- /core/components/site/elements/chunks/chunk.tpl_contact_form.html: -------------------------------------------------------------------------------- 1 |

    Пользователь оставил заявку на сайте {'http_host' | config}

    2 |
    3 |

    Контакты

    4 |

    Имя: {$name}

    5 |

    Телефон: {$phone}

    6 |
    7 |

    Сообщение

    8 |

    {$message | nl2br}

    -------------------------------------------------------------------------------- /core/components/site/elements/plugins/plugin.addmanagercss.php: -------------------------------------------------------------------------------- 1 | event->name) { 4 | case 'OnManagerPageInit': 5 | $modx->regClientCSS($modx->getOption('assets_url') . 6 | 'components/SITE_FOLDER_NAME/mgr/style.css'); 7 | break; 8 | default: 9 | break; 10 | } 11 | -------------------------------------------------------------------------------- /core/components/site/elements/plugins/plugin.convertbase64images.php: -------------------------------------------------------------------------------- 1 | getOption('ckeditor.extra_plugins')); 3 | if (in_array('base64image', $plugins)) { 4 | $content = $resource->content; 5 | $content = preg_replace_callback( 6 | '/]+src="?\'?([^"\']+)"?\'?[^>]*>/i', 7 | function ($matches) { 8 | $output = $matches[0]; 9 | if (preg_match('/^data:image\/(\w+);base64,/', $matches[1], $type)) { 10 | $data = substr($matches[1], strpos($matches[1], ',') + 1); 11 | $type = strtolower($type[1]); // jpg, png, gif 12 | if (in_array($type, [ 'jpg', 'jpeg', 'gif', 'png' ])) { 13 | $data = base64_decode($data); 14 | if ($data !== false) { 15 | $path = MODX_ASSETS_PATH . 'images/content/'; 16 | $path .= date('Y-m-d') . '/'; 17 | if (!file_exists($path)) { 18 | mkdir($path, 0777, true); 19 | } 20 | $name = substr(md5($data), 0, 12) . ".{$type}"; 21 | if (!file_exists($path . $name)) { 22 | file_put_contents($path . $name, $data); 23 | } 24 | $url = str_replace(MODX_ASSETS_PATH , MODX_ASSETS_URL, $path . $name); 25 | $output = str_replace($matches[1], $url, $matches[0]); 26 | } 27 | } 28 | } 29 | 30 | return $output; 31 | }, 32 | $content 33 | ); 34 | $resource->set('content', $content); 35 | $resource->save(); 36 | } -------------------------------------------------------------------------------- /core/components/site/elements/plugins/plugin.siteredirect.php: -------------------------------------------------------------------------------- 1 | event->name != "OnHandleRequest" || $modx->context->key == 'mgr') { 3 | return; 4 | } 5 | $tmp = explode('?', $_SERVER['REQUEST_URI']); 6 | $link = trim($tmp[0], '/'); 7 | if (isset($tmp[1]) && $tmp[1]) { 8 | $params = '?' . $tmp[1]; 9 | } else { 10 | $params = ''; 11 | } 12 | $uri = '/' . strtolower($link) . $params; 13 | $http_host = $_SERVER['HTTP_HOST']; 14 | $site_url = str_replace(array('www.', 'http://', 'https://', '/'), '', $modx->getOption('site_url')); 15 | 16 | // for https set true 17 | $https = false; 18 | 19 | if ($https) { 20 | $protocol = 'https://'; 21 | } else { 22 | $protocol = 'http://'; 23 | } 24 | 25 | if ($http_host != $site_url || ($https && !$_SERVER['HTTPS']) || $_SERVER['REQUEST_URI'] != $uri) { 26 | $modx->sendRedirect($protocol.$site_url.$uri, array('responseCode' => 'HTTP/1.1 301 Moved Permanently')); 27 | } 28 | if ($_SERVER['REQUEST_URI'] == '/index.php') { 29 | $modx->sendRedirect($protocol.$site_url, array('responseCode' => 'HTTP/1.1 301 Moved Permanently')); 30 | } 31 | -------------------------------------------------------------------------------- /core/components/site/elements/snippets/snippet.rtrim.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {include 'head'} 5 | 6 | 7 |
    8 | {include 'header'} 9 | {include 'menu'} 10 |
    11 |
    12 | {include 'content'} 13 |
    14 | 17 |
    18 | {include 'footer'} 19 |
    20 | {include 'scripts'} 21 | 22 | --------------------------------------------------------------------------------