This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Add RTE for introtext if richtext option is enabled for the resource | |
| // check "OnDocFormRender" event | |
| $modx->regClientStartupHTMLBlock('<script>Ext.onReady(function() { | |
| if(MODx.loadRTE) MODx.loadRTE("modx-resource-introtext"); | |
| });</script>'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if ($modx->getOption('http_host') == 'YOUR_DOMAIN_HERE') { | |
| $op = '<script type="text/javascript"> | |
| Ext.onReady(function() { | |
| document.getElementById("modx-login-username").value = "USER"; | |
| document.getElementById("modx-login-password").value = "PASS"; | |
| document.getElementById("modx-login-btn").click(); | |
| }); | |
| </script>'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Convert a comma separated file into an associated array. | |
| * The first row should contain the array keys. | |
| * | |
| * Example: | |
| * | |
| * @param string $filename Path to the CSV file | |
| * @param string $delimiter The separator used in the file | |
| * @return array |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* | |
| mgThumb by pepebe | |
| --------------------------------------------- | |
| saves the first image in a galley inside a tv | |
| trigger OnDocFormSave | |
| Initial idea: https://gist.github.com/christianseel/557a1e0f2a1f502ce1c5 | |
| Changelog: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * MODX Revolution OnElementNotFound plugin | |
| * Add static elements inside categories for defined packages OnElementNotFound | |
| * | |
| * Author: Jeroen Kenters / www.kenters.com | |
| * Version: 1.0.0-beta | |
| * License: GPL | |
| * | |
| * Warning: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Snippet: [[SnippetName]] | |
| Chunk: [[$ChunkName]] | |
| System Setting: [[++SettingName]] | |
| TV: [[*fieldName/TvName]] | |
| Link tag: [[~PageId? ¶mName=`value`]] | |
| Placeholder: [[+PlaceholderName]] | |
| <?php |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $modAuth = $this->modx->user->getUserToken('mgr'); | |
| $thumbQuery = http_build_query(array( | |
| 'src' => $image['urlAbsolute'], | |
| 'w' => 360, | |
| 'h' => 270, | |
| 'HTTP_MODAUTH' => $modAuth, | |
| //'f' => $thumbnailType, | |
| 'q' => 80, | |
| 'wctx' => 'mgr', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var content = ''; | |
| content += '<h3>Hinweise</h3>'; | |
| content += '<p>Hinweistext</p>'; | |
| content += '<style>.hdkInfo-panel p {margin-bottom: 10px; line-height:1.6;} .hdkInfo-panel h4 {margin-top: 15px; margin-bottom: 5px;}</style>'; | |
| var hdkInfo = function(config) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| class videoThumb { | |
| var $config; | |
| function __construct($config = array()) { | |
| $this->config = array_merge(array( | |
| 'imagesPath' => dirname(__FILE__) . '/images/' | |
| ,'imagesUrl' => '/images/' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* forked from MikeRogers0/twitter-proxy.php */ | |
| /** | |
| * Usage: | |
| * Send the url you want to access url encoded in the url paramater, for example (This is with JS): | |
| * /twitter-proxy.php?url='+encodeURIComponent('statuses/user_timeline.json?screen_name=MikeRogers0&count=2') | |
| */ |