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 | |
| /** | |
| * Display an array as a formatted text table | |
| * | |
| * This class converts an array into a formatted table and supports dynamic column widths, | |
| * text appending, typecasting and customer header naming. | |
| * | |
| * @author Geert Hauwaerts <[email protected]> | |
| * @copyright Copyright (c) 2015, Geert Hauwaerts | 
  
    
      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
    
  
  
    
  | #!/usr/bin/env php | |
| <?php | |
| /** | |
| * team-reflex/discord-php example. | |
| * | |
| * This is a simple example use of team-reflex/discord-php :) | |
| * | |
| * @author Geert Hauwaerts <[email protected]> | |
| * @copyright Copyright (c) Geert Hauwaerts | 
  
    
      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
    
  
  
    
  | diff --git a/common/struct_def.h b/common/struct_def.h | |
| index 08a0bc6..dcca168 100644 | |
| --- a/common/struct_def.h | |
| +++ b/common/struct_def.h | |
| @@ -192,6 +192,7 @@ typedef enum Status { | |
| #define FLAGS_RESTRICT 0x0010 /* restricted user */ | |
| #define FLAGS_AWAY 0x0020 /* user is away */ | |
| #define FLAGS_EXEMPT 0x0040 /* user is exempted from k-lines */ | |
| +#define FLAGS_SPOOFED 0x0080 /* user is spoofed */ | |
| #ifdef XLINE | 
  
    
      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
    
  
  
    
  | import os | |
| import json | |
| from java.net import URL | |
| from java.io import DataOutputStream | |
| data = json.dumps({ | |
| 'content': 'a test' | |
| }) | 
  
    
      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
    
  
  
    
  | ## | |
| # This example is intented for jPython environments (like SikuliX) where you can't use | |
| # requests or urllib2. | |
| ## | |
| import os | |
| import sys | |
| import json | |
| from java.net import URL | 
  
    
      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 | |
| /** | |
| * Create an outage report based on a ping log file. | |
| * | |
| * Command: ping <target> -DO >> ping.log | |
| */ | |
| $report = [ | 
  
    
      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 | |
| /** | |
| * This example assumes: | |
| * _id: entry unique key | |
| * field: a field that is not unique, but you want to remove all | |
| * entries that have the same value while keeping the first entry. | |
| */ | |
| $duplicates = $collection->aggregate([ | 
  
    
      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
    
  
  
    
  | #!/bin/bash | |
| ## | |
| # Fast VoIPBL implementation with iptables-restore. | |
| # | |
| # This is a very fast method (3-5 seconds) to apply and refresh the VoIPBL | |
| # blacklist by using iptables-restore. | |
| # | |
| # The default wget/awk method takes between 30-60 minutes to apply, and | |
| # leaves the server exposed during the 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
    
  
  
    
  | $ composer require slim/slim | |
| $ composer require nesbot/carbon | |
| $ composer require illuminate/database | |
| $ composer require andrewdyer/slim3-session-middleware | 
  
    
      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
    
  
  
    
  | probe matomo_health { | |
| .url = "/"; | |
| .interval = 5s; | |
| .timeout = 3s; | |
| .window = 5; | |
| .threshold =3; | |
| } | |
| backend matomo_1 { | |
| .host = "10.0.0.1"; | 
OlderNewer