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
| git remote prune origin | |
| git branch -r --merged master | egrep -iv '(master|develop)' | sed 's/origin\///g' | xargs -n 1 git push --delete origin |
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
| // Dashboard widget to show number of Manager messages | |
| $id = $modx->user->get('id'); | |
| $output = 'No messages.'; | |
| $total = $modx->getCount('modUserMessage',array( | |
| 'recipient' => $id, | |
| )); | |
| if($total) { | |
| $output = 'You have ' . $total . ' messages'; | |
| $unread = $modx->getCount('modUserMessage',array( | |
| 'recipient' => $id, |
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 | |
| /** | |
| * A sample plugin to display the "welcome message" to all users, login for the first time in Revo manager | |
| * | |
| * @var modX $modx | |
| * @var array $scriptProperties | |
| * @var modPlugin $this | |
| * | |
| * @see modPlugin::process() | |
| * |
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 svg = document.querySelector( "svg" ); | |
| var svgData = new XMLSerializer().serializeToString( svg ); | |
| var canvas = document.createElement( "canvas" ); | |
| var ctx = canvas.getContext( "2d" ); | |
| var img = document.createElement( "img" ); | |
| img.setAttribute( "src", "data:image/svg+xml;base64," + btoa( svgData ) ); | |
| img.onload = function() { |
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
| DECLARE @WorkingSQL VARCHAR(8000) | |
| ,@NewPath VARCHAR(8000) = 'G:\SQL Data\' /* Root location to move files */ | |
| ,@TargetDatabase sysname = '%'; /* Specify a singular database, or % for All Databases */ | |
| SET NOCOUNT ON; | |
| /* Sanitize path */ | |
| IF RIGHT(@NewPath, 1) <> '\' | |
| BEGIN | |
| SET @NewPath = @NewPath + '\'; |
OlderNewer