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
| // access chrome://dino in you Google Chrome Browser | |
| // inspect element and go to console | |
| // tip each command below | |
| // close the Inspect Element's Window | |
| // start the game and the dino wont'b be effected with cactus and birds | |
| var original = Runner.prototype.gameOver; | |
| Runner.prototype.gameOver = 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
| // design mode allows you try websites out editing its contents (like ContentEditable attribute in HTML's tags) | |
| // you can put bold, italic and common texts and add another contents (it's usefull when you program with TomCat like me LOL) | |
| // to use design mode, just opens Inspect Element Window in the website, go to Console tab an tip this command | |
| document.designMode = "on"; | |
| // to desable it, tip this | |
| document.designMode = "off"; |
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
| <script> | |
| // suppose that I have a form with two fields: 'email' and 'password' | |
| // to use ajax, first I needa catch the values of these fields like this (I'm using JQuery) | |
| var email = $("#emailField").val(); | |
| var password = $("#passwordField").val(); | |
| // check if the fields are filled | |
| if (email == "" || password == "") { alert("Both fields need be filled"); } | |
| else { | |
| // now, I active Ajax when the 'submit' button are clicked |
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
| <!-- | |
| some types of input tags in HTML have the 'pattern attribute' available | |
| this attribute is used to check some RegEx (Regular Expression), for example, check email, nickname and password | |
| in this example, consider that I have a form with one nickname field, this field must accept just letters, | |
| underscores and numbers. Also, the nickname must have legnth between 5 - 15 chars. I would tip like this: [a-zA-Z1-9_]{5,15} | |
| --> | |
| <form method="POST" action="#"> | |
| <input type="text" title="Only letters, underscores and numbers are accepted. You must tip betwenn 5 - 15 chars" | |
| pattern="[a-zA-Z1-9_]{5,15}" required> | |
| <input type="submit" value="Save!"> |
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
| /* | |
| UUID is used as PRIMARY or UNIQUE KEY in our table's rows. Different of sequencial primary key, that starts from 1 and | |
| are incremented 1 by 1, UUID is a hexadecimal random value that is generated automatically by the RDBMS. | |
| How to explain the pros and cons about UUID Use is not the goal here, I gonna just put how to use and convert the value | |
| from text to byte and vice-versa. | |
| If u wanna read and learn what is and the pros\cons about UUID, check this MySQL's Post: | |
| https://mysqlserverteam.com/mysql-8-0-uuid-support/ | |
| */ |
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
| /* | |
| these classes I use a lotta times programming websites with neomorphismo design, so, I gonna keep the code save here | |
| */ | |
| /** variables **/ | |
| /* light Theme */ | |
| :root { | |
| --primary-background-color: #cbced1; | |
| --secundary-background-color: #414649; | |
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
| // Java program to check if an email address | |
| // is valid using Regex. | |
| import java.util.regex.Matcher; | |
| import java.util.regex.Pattern; | |
| class Test | |
| { | |
| public static boolean isValid(String email) | |
| { | |
| String emailRegex = "^[a-zA-Z0-9_+&*-]+(?:\\."+ |
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
| If you would like to use notepad in your browser, follow these steps | |
| 1 - open a new tab; | |
| 2 - tip this command over the URL input: | |
| data:text/html, <html contenteditable> | |
| 3 - Press 'enter' and use the notepad!!! | |
| 4 - Press CTRL + S to save the file and open whenever nedda use it in the browser |
OlderNewer