This file contains 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
D8 - Services with Dependency Injection | |
... | |
lightning-8/modules/custom/basic/basic.services.yml | |
services: | |
basic.basic_hero_articles: | |
class: Drupal\basic\BasicArticleService |
This file contains 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
D8 - Services | |
... | |
lightning-8/modules/custom/basic/basic.services.yml | |
services: | |
basic.basic_hero_articles: | |
class: Drupal\basic\BasicArticleService |
This file contains 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
Twig Templates | |
Attach Library | |
... | |
lightning-8/modules/custom/basic/css | |
animate.css | |
... |
This file contains 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
Plugins / Annotation / Blocks | |
... | |
lightning-8/modules/custom/basic/src/Plugin/Block/BasicHeroBlock.php | |
<?php | |
namespace Drupal\basic\Plugin\Block; |
This file contains 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
Basic Module | |
Controller / Routes | |
... | |
lightning-8/modules/custom/basic/basic.info.yml | |
name: "Basic" | |
description: "A Basic Module" |
This file contains 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
function sendGoPrivateMessage(channel, user_id, firstName) { | |
let teamId = 'T########'; | |
let post = | |
{ | |
channel: channel, | |
user: user_id, | |
text: 'Hi ' + firstName + ', I can help you book your room. Let\'s work on your new reservation in private.' , | |
attachments: |
This file contains 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 | |
$endpoint = "<the endpoint url for the post>"; | |
function doPost($endpoint) { | |
$items = array( | |
'postitem1' => 'abc', | |
'postitem2' => 'def', | |
); |
This file contains 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
#!/usr/bin/env bash | |
PHP=`which php` | |
$PHP example.php |
This file contains 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
private void GetUpdate() | |
{ | |
try | |
{ | |
StartActivity(new Intent(Intent.ActionView, Android.Net.Uri.Parse("market://details?id=" + PackageName))); | |
} | |
catch (ActivityNotFoundException e) | |
{ | |
// Default to the the actual web page in case google play store app is not installed | |
StartActivity(new Intent(Intent.ActionView, Android.Net.Uri.Parse("https://play.google.com/store/apps/details?id=" + PackageName))); |
This file contains 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
find . -name "*.cs" | while read line; do expand -t 4 $line > $line.new; mv $line.new $line; done |