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
div.container { | |
padding-top: 60px; | |
padding-bottom: 60px; | |
} | |
.navbar-default { | |
background-color: rgba(250, 250, 250, 0.95); | |
color: #fff; | |
} | |
ul.navbar-nav li:hover { | |
background-color: rgb(240, 240, 240); |
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
<IfModule mod_headers.c> | |
Header set Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" env=HTTPS | |
Header always set Content-Security-Policy "default-src 'self' *.cloudflare.com *.google-analytics.com; script-src 'self' 'unsafe-inline' 'unsafe-eval' *.cloudflare.com *.google-analytics.com https://sharebutton.net *.sharebutton.net; style-src 'self' 'unsafe-inline'; img-src data: *; object-src 'none'" | |
Header set X-Content-Type-Options nosniff | |
Header set X-Frame-Options DENY | |
Header set X-XSS-Protection "1; mode=block" | |
Header always set Referrer-Policy "same-origin" | |
Header always set Feature-Policy "microphone 'none'; payment 'none'; sync-xhr 'self' https://o-seu-dominio.com" | |
</IfModule> |
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
$sql = "SELECT userID, nome, apelido FROM usuarios WHERE userID = ?"; | |
$user = $_SESSION['user_portal']; | |
if ($stmt = mysqli->prepare($sql)) { | |
mysqli_stmt_bind_param($stmt, "i", (int)$user); | |
/* execute query */ | |
mysqli_stmt_execute($stmt); | |
/* bind result variables */ |
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 bash | |
# https://docs.docker.com/install/linux/docker-ce/ubuntu/ | |
sudo apt-get install apt-transport-https ca-certificates curl software-properties-common | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | |
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable" | |
sudo apt-get update | |
sudo apt-get install docker-ce | |
# https://docs.docker.com/compose/install/ |
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
Option Explicit | |
' From: https://blogs.msdn.microsoft.com/jjameson/2009/11/03/deleting-empty-folders/ | |
If (WScript.Arguments.Count <> 1) Then | |
WScript.Echo("Usage: cscript DeleteEmptyFolders.vbs {path}") | |
' If at least 1 argument is passed, list them | |
If (WScript.Arguments.Count > 0) Then | |
Dim strArg |
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
Option Explicit | |
' | |
' Syncronize folders, in both ways, recursivelly | |
' | |
' Usage: cscript SyncFolders.vbs {source} {dest} [{logfile}] [/nolog] [/noecho] [/oneway] [/backup] | |
' | |
' {source} - Source path | |
' {dest} - Target path | |
' {logfile} - Log file. If not passed, "SyncFolders_YYYYMMDDHHMMSS.log" will be created. |
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
Option Explicit | |
If (WScript.Arguments.Count <> 2) Then | |
WScript.Echo("Usage: cscript BackupFolders.vbs {source} {dest}") | |
' If at least 1 argument is passed, list them | |
If (WScript.Arguments.Count > 0) Then | |
Dim strArg | |
Dim i |
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
Option Explicit | |
Dim objFSO | |
Set objFSO=CreateObject("Scripting.FileSystemObject") | |
If (WScript.Arguments.Count <> 2) Then | |
WScript.Echo("Usage: cscript ListEmptyFolders.vbs {path} {list file}") | |
' If at least 1 argument is passed, list them | |
If (WScript.Arguments.Count > 0) Then |
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
Write-Output "Finding $($args[0])..." | |
Get-ChildItem –Path C:\ -Include $args[0] -Recurse -ErrorAction SilentlyContinue |
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 | |
# Install Composer on Centos, Ubuntu, Debian | |
# Inspired by: https://gist.github.com/virbo/c3169ed490564f36f0c239d6fd16f749 | |
user_allow="root" | |
if [ "$(whoami)" != $user_allow ]; then | |
echo "===================================================================" | |
echo " Falha na instalação. O composer deve ser instalado com o user: "$user_allow" =" | |
echo "===================================================================" |
OlderNewer