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
RewriteEngine On | |
RewriteCond %{HTTPS} !on | |
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} |
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
// Para obter o token | |
// $json = file_get_contents("https://instagram.com/oauth/authorize/?client_id=33ba683f581e4c8faefd4cd38d948131&redirect_uri=http://www.sofisticatta.dev&scope=public_content&response_type=token"); | |
// $data = json_decode($json); | |
// dd($data); | |
// die(); | |
// $json = file_get_contents("https://api.instagram.com/v1/tags/looksofisticatta/media/recent/?access_token=311684193.33ba683.9dae3610190549e0aa1bf6caa41c065b"); | |
// $data = json_decode($json); |
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
// Exemplo com encapsulamento de métodos | |
var pedidoMesa1 = (function() { | |
var pedido = {}; | |
pedido.alertar = function(msg){ | |
alert(msg); | |
}; | |
pedido.addItem = 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
<platform name="windows"> | |
<icon src="resources/windows/icon/Square150x150Logo.scale-100.png" width="150" height="150" /> | |
<icon src="resources/windows/icon/Square150x150Logo.scale-240.png" width="360" height="360" /> | |
<icon src="resources/windows/icon/Square30x30Logo.scale-100.png" width="30" height="30" /> | |
<icon src="resources/windows/icon/Square310x310Logo.scale-100.png" width="310" height="310" /> | |
<icon src="resources/windows/icon/Square44x44Logo.scale-240.png" width="106" height="106" /> | |
<icon src="resources/windows/icon/Square70x70Logo.scale-100.png" width="70" height="70" /> | |
<icon src="resources/windows/icon/Square71x71Logo.scale-240.png" width="170" height="170" /> | |
<icon src="resources/windows/icon/StoreLogo.scale-100.png" width="50" height="50" /> | |
<icon src="resources/windows/icon/StoreLogo.scale-240.png" width="120" height="120" /> |
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
// Fica escutando o evento do botão voltar | |
// //////////////////////// | |
document.addEventListener("backbutton", function(){ | |
// Se estou na home, então pergunto se quer sair do app | |
if ($location.path() == '/'){ | |
// Mando uma mensagem na cara do usuário, perguntando se quer sair | |
$cordovaDialogs.confirm('' , 'Deseja sair do aplicativo?', ['Sim','Não']).then(function(buttonIndex) { |
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
.spinner { | |
width: 40px; | |
height: 40px; | |
position: relative; | |
margin: 100px auto; | |
} | |
.double-bounce1, .double-bounce2 { | |
width: 100%; | |
height: 100%; |
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
// Realiza a busca na plataforma Firebase | |
function encontrar(uid){ | |
// Inicializa | |
var db = firebase.database(); | |
// Busca a referencia, entenda como uma URL, empresas no Firebase é representando por /empresas | |
var empresas = db.ref('empresas'); | |
// Prepara a busca filtrando |
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
.offline-alert{ | |
position: fixed; | |
top: 0; | |
left: 0; | |
right: 0; | |
bottom: 0; | |
z-index: 28; | |
background: rgba(255, 255, 255, 0.95); | |
display: flex; | |
justify-content: center; |
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
// Valores da imagem original | |
var width = 600, height = 300; | |
// Redução desejada | |
var width_new = 300; | |
// Novo tamanho baseado na redução | |
var height_new = Math.round(((height/width) * width_new)); |
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
.truncate-link { | |
max-width: 100%; | |
display: inline-block; | |
vertical-align: middle; | |
overflow: hidden; | |
white-space: nowrap; | |
text-overflow: ellipsis; | |
} |