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
* { | |
margin: 0; | |
padding: 0; | |
box-sizing: border-box; | |
} | |
body { | |
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif; | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; |
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
body { | |
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, | |
Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; | |
background-color: #f0f2f5; | |
display: flex; | |
justify-content: center; | |
align-items: center; | |
height: 100vh; | |
margin: 0; | |
} |
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
// RESOLVER PROMESAS 1: THEN - CATCH | |
function getPokemonThen(name = 'ditto') { | |
return fetch(`https://pokeapi.co/api/v2/pokemon/${name}`) | |
.then(response => { | |
if (!response.ok) { | |
throw new Error(`Error HTTP ${response.status}`); | |
} | |
return response.json(); | |
}) | |
.then(pokemon => { |
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
# Tool for creating background code: https://cssgradient.io/ | |
# Go to Advanced Tab → Custom CSS → Free Form CSS and add this code: | |
selector::before { | |
content: ""; | |
display: block; | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 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
import logo from '@/assets/react.svg' | |
import '@/styles/form.css' | |
const Signup = () => { | |
return ( | |
<main className='form-signin w-100 m-auto'> | |
<form> | |
<img className='mb-4' src={logo} alt='' width='72' height='57' /> | |
<h1 className='h3 mb-3 fw-normal'>Please sign up</h1> |
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
-- Referencia: https://decodecms.com/crear-usuario-administrador-de-wordpress-desde-la-base-de-datos/ | |
-- Cambiar valores | |
SET @prefix = 'wp_25i9wh_'; -- Prefix de la tabla de la instalación de WP | |
SET @id_user = 1; -- Usuario al que se hará administrador | |
-- Actualiza tabla de usermeta | |
SET @set_value_meta ='SET meta_value = ''a:1:{s:13:"administrator";b:1;}'' WHERE user_id ='; | |
SET @usermeta = CONCAT("UPDATE ", @prefix, "usermeta ", @set_value_meta, @id_user,' AND meta_key = "', @prefix, 'capabilities";' ); |
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
/** | |
* @param { import("knex").Knex } knex | |
* @returns { Promise<void> } | |
* author: César Guerra | |
*/ | |
exports.seed = async function (knex) { | |
// Deletes ALL existing entries | |
// Se necesita borrar las tablas en un orden específico para evitar errores de llave foránea. Y es necesario reiniciar la secuencia de las tablas para que los nuevos registros tengan un id consecutivo que empiece en 1 cada vez que se ejecuta el seed. | |
await knex.raw('TRUNCATE homes RESTART IDENTITY CASCADE') | |
await knex.raw('TRUNCATE users RESTART IDENTITY CASCADE') |
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 logo from '../assets/react.svg' | |
const ReactHookForm = () => { | |
return ( | |
<div className='login'> | |
<div className='login-container'> | |
<img src={logo} alt='logo' /> | |
<form | |
onSubmit={() => { }/* HANDLE SUBMIT */} |
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
/* Animate Wordpress Divi Top and Bottom Dividers */ | |
/* HOW TO USE */ | |
/* Add the following code to the Custom CSS box in Divi Theme Options */ | |
/* Add the class "bg-animate-bottom" or "bg-animate-top" to the divi section divider */ | |
.bg-animate-bottom .et_pb_bottom_inside_divider { | |
-webkit-animation: scroll 150s linear infinite; | |
-moz-animation: scroll 150s linear infinite; | |
-ms-animation: scroll 150s linear infinite; | |
-o-animation: scroll 150s linear infinite; |
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
- Windows Terminal Command to Rename all files in a folder with Year day month format and time using the last writted time (modified date) | |
# Option #1 | |
Get-ChildItem | Rename-Item -NewName {$_.LastWriteTime.ToString("yyyy-dd-MMM HH.mm.ss") + ($_.Extension)} | |
# Option #2 | |
Get-ChildItem | Rename-Item -NewName {$_.LastWriteTime.ToString("yyyy-MM-dd HH.mm.ss") + ($_.Extension)} | |
- Windows Terminal Command to Rename all image files in a folder with Date of the taken time | |
$shell = New-Object -ComObject shell.application |
NewerOlder