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
| sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10 | |
| echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list | |
| sudo apt-get update | |
| sudo apt-get install -y mongodb | |
| sudo apt-get install php-mongodb | |
| #for test | |
| mongo |
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> | |
| window.addEventListener('DOMContentLoaded', function() { | |
| $(document).ready(function () { | |
| // here the code go | |
| }); | |
| }); | |
| </script> |
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
| open .bashrc | |
| add this configurations | |
| # custom the title of the terminal | |
| PROMPT_COMMAND="printf \"\033]0;%s\007\" \"You Can Do It\"" | |
| # custom terminal symbol | |
| PS1='\[\033[1;34m\]pwd ⇒ (\w)\n' | |
| PS1=${PS1}'\[\033[1;36m\]whoami ⇒ (\u)\n' | |
| PS1=${PS1}'\[\033[1;33m\]hostname ⇒ (\h)\n' |
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
| use Illuminate\Support\Facades\Storage; | |
| // this will clear the file and put hello world | |
| Storage::disk('local')->put('html.txt','hello world'); | |
| // this will append to the file | |
| Storage::disk('local')->append('html.txt','hamada'); |
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
| ssh [email protected] | |
| cd /var/www/html/ |
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
| { | |
| "scripts": [], | |
| "showConsole": true | |
| } |
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
| // names here like ahmed belong to the owner of the problem | |
| let prtext = "Egy"; | |
| let ahmed = function() { | |
| let a = Math.floor(Math.random() * prtext.length); | |
| let b = ""; | |
| let whichRange = getRandomIntBetweenTwoValues(1, 2); | |
| // to handle the critical values | |
| if(a==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
| <html> | |
| <head> | |
| <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> | |
| </head> | |
| <body> | |
| <div id="app"> | |
| <div class="title">vuejs countries example: </div> | |
| <select> | |
| <option slected>Select country</option> | |
| <option v-for="country in countries" :value="country.name"> |
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
| [{"name":"AFGHANISTAN"},{"name":"ALBANIA"},{"name":"ALGERIA"},{"name":"AMERICAN SAMOA"},{"name":"ANDORRA"},{"name":"ANGOLA"},{"name":"ANGUILLA"},{"name":"ANTARCTICA"},{"name":"ANTIGUA AND BARBUDA"},{"name":"ARGENTINA"},{"name":"ARMENIA"},{"name":"ARUBA"},{"name":"AUSTRALIA"},{"name":"AUSTRIA"},{"name":"AZERBAIJAN"},{"name":"BAHAMAS"},{"name":"BAHRAIN"},{"name":"BANGLADESH"},{"name":"BARBADOS"},{"name":"BELARUS"},{"name":"BELGIUM"},{"name":"BELIZE"},{"name":"BENIN"},{"name":"BERMUDA"},{"name":"BHUTAN"},{"name":"BOLIVIA"},{"name":"BOSNIA AND HERZEGOVINA"},{"name":"BOTSWANA"},{"name":"BRAZIL"},{"name":"BRUNEI DARUSSALAM"},{"name":"BULGARIA"},{"name":"BURKINA FASO"},{"name":"BURUNDI"},{"name":"CAMBODIA"},{"name":"CAMEROON"},{"name":"CANADA"},{"name":"CAPE VERDE"},{"name":"CAYMAN ISLANDS"},{"name":"CENTRAL AFRICAN REPUBLIC"},{"name":"CHAD"},{"name":"CHILE"},{"name":"CHINA"},{"name":"CHRISTMAS ISLAND"},{"name":"COCOS (KEELING) ISLANDS"},{"name":"COLOMBIA"},{"name":"COMOROS"},{"name":"CONGO"},{"name":"CONGO, THE DEM |