Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Session 7
- =========
- Introduction to web Architecture and Components
- -----------------------------------------------
- 1. Domain Name
- ---------------
- godaddy.com
- hostgator.com
- 2. Hosting Space
- ----------------
- 000webhost.com
- 3. Server
- ---------
- They are the applications or hardwares which are used to run other programs. server side programs. php script.
- It manages the request and response.
- When a user enters something in the url bar ---> a request is generated
- At the same time, when user receives the data -> a response is received
- Servers are again of 2 types:
- 1. MS OS Based server
- IIS --> Internet Information Services
- 2. Linux Based Servers
- Apache | Tomcat
- 4. Database
- -----------
- It is known as the backbone. It stores the data of the web site or the web application. It stores the data in a tabular way.
- Database --> Tables --> Columns --> Rows (Data)
- Database is again of two type:
- 1. MS OS --> MSSQL
- 2. Linux --> MySQL
- 5. Web Technologies
- -------------------
- These are the coding languages or scripting languages in which our web site or web application is biuld.
- They are also divided into 2 types
- 1. Client Side | Front End Scripting Language
- 2. Server Side | Back End Scripting Language
- 1. Client Side Scripting
- These provides the UI to the web site or the web application. It is what a user sees on the web browser.
- These require just a browser to run.
- HTML
- 2. Server Side Scripting
- These are what works on back end. They require a server to run.
- PHP
- MS OS --> ASP.NET
- Linux --> PHP
- MS OS --> IIS + MSSQL + ASP.NET ---> Money
- Linux --> Apache|Tomcat + MySQL + php ---> Money
- Local Hosting Server
- ====================
- By using these third party application for free, you can launch and host the application or the web site on the LAN and can run the testing for the same. There is no money involved, I can test the application for free.
- 1. Windows Based Server --> WAMPP
- W --> Windows
- A --> Apache
- M --> MySQL
- P --> Perl
- P --> Php
- 2. Linux Based Server --> LAMPP
- L --> Linux
- A --> Apache
- M --> MySQL
- P --> Perl
- P --> Php
- 3. Cross Platform Based Server --> XAMPP
- X --> Cross Platform
- A --> Apache
- M --> MySQL
- P --> Perl
- P --> Php
- After Installing XAMPP
- ======================
- 1. Apache
- 2. MySQL
- we need to start these two services.
- How To Access XAMPP Server
- --------------------------
- There are 3 ways via which we can access the xampp server. Open the browser
- 1. localhost
- 2. 127.0.0.1
- 3. Hosted system's IP Address
- Web Security Misconfigurations
- ------------------------------
- 1. If I do have a good firewall, I am secure.
- 2. If I do have a good IDS and IPS, I am secure.
- 3. If the web site of the web application is using HTTPS, I am secure.
- HTML
- ====
- Hyper Text Markup Language
- --------------------------
- Front end developing language. which requires a browser to run.
- 1. HTML --> Each and everything of the front end is written in this tag.
- <html>
- xxxxxx
- xxxxxx
- xxxxxx
- </html>
- 2. Head --> Contains the meta data
- Links of styles, title, date etc etc
- <head>
- xxxxxx
- xxxxxx
- xxxxxx
- xxxxxx
- </head>
- 3. title --> to provide the title to the tab
- <title>Name_Of_The_Title</title>
- 4. Body --> Which contains the whole of the code of the web site and the web application. I works after the head is closed.
- <body>
- xxxxxx
- xxxxxx
- xxxxxx
- </body>
- 5. Paragraph -->
- <p>.....
- ........
- ........
- ........
- </p>
- 6. Break
- <br> --> It is single tag. It doesnot needed to close
- 7. Heading
- There are 6 types of heading tag
- h1
- h2
- h3
- h4
- h5
- h6
- as the number increases, the font size decreases.
- 8. anchor --> to provide the hyper link to anything
- <a href="#">............</a>
- 9. Image
- <img src=""></img>
- 10. Form
- <form action="Kis page p redirect krna hai after clicking submit button" method="GET|POST">
- </form>
- 11. Input
- <input type="text|number|date|password" id="Unique ID" name="Name Of the Element">
- 12. iframe
- <iframe src="http://www.lucideus.com"></iframe>
- ==========
- pagee.html
- ==========
- <html>
- <head>
- <title>CII</title>
- </head>
- <body>
- <p>
- <h1>Grade 2<br>
- =======</h1>
- <h2>Session 1<br>
- ---------</h2>
- <a href="http://www.lucideus.com"><h3>Introduction To Cryptography</a><br>
- ----------------------------</h3>
- Cryptography --> Conversion of text into another form, which is readable but
- not understandable.
- <br>
- Conversion of plain text into an encrypted text via an algorithm which uses a
- key, after transmission, decryption of the encrypted text into the plain text
- via same algorithm and the key.
- <br>
- Plain Text --> It is a normal Text, which is typed by the user. which is
- readable and understandable to everyone.<br>
- Cipher Text --> Encrypted text, which is the output of the encryption.<br>
- Encryption --> Process of converting plain text into a Cipher text, it is
- readable but not understandable<br>
- Decryption --> Reverse of encryption, conversion of Cipher text into a plain
- text<br>
- Algorithm --> It is the code which is used to encrypt and decrypt the plain
- text into cipher text and cipher text into plain text.<br>
- Key --> it is a special function, encryption and decryption is possible just
- due to this key. <br
- </p>
- <img src="naruto.jpg" height="700"></img>
- <form action="mera.html" method="GET">
- Username :<input type="text" id="uname"><br>
- Password :<input type="password" id="pass"><br>
- <input type="submit" id="but">
- </form>
- </body>
- </html>
- =========
- mera.html
- =========
- <html>
- <head>
- <title>Second Page</title>
- </head>
- <body>
- <p>
- This is my second page</p>
- <iframe
- src="http://www.lucideus.com"></iframe><br>
- <img src="goku.jpg" height="500"></img>
- </body>
- </html>
- PHP Basics
- ==========
- Server Side Scripting Language
- <?php
- xxxx
- xxxx
- xxxx
- xxxx
- ?>
- <?php ---> Start of PHP code
- ?> ---> End of php code
- echo "Hello Guys"
- $var --> var is name of variable
- $hack --> Hack is name of variable
- $ ---> used to declare a variable
- $_POST
- $_GET
- =========
- CALL.html
- =========
- <html>
- <head>
- <title>Calculator</title>
- </head>
- <body>
- <form action="calc.php" method="post" attribute="post">
- First Value : <input type="text" id="first" name="first"><br>
- Second Value : <input type="text" id="second" name="second"><br>
- <input type="radio"
- name="group1" id="add" value="add" checked="true">ADD<br>
- <input type="radio" name="group1" id="subtract" value="subtract">SUBTRACT<br>
- <button type="submit" id="answer" value="answer">Calculate</button>
- </form>
- </body>
- </html>Butt
- ========
- calc.php
- ========
- <html>
- <head>
- <title>Jawab</title>
- </head>
- <body>
- <p>
- <?php
- $first=$_POST['first'];
- $second = $_POST['second'];
- if($_POST['group1'] == 'add')
- {
- $ans=$first+$second;
- echo $ans;
- }
- if($_POST['group1'] == 'subtract')
- {
- $ans=$first-$second;
- echo $ans;
- }
- ?>
- </p>
- </body>
- </html>
Add Comment
Please, Sign In to add comment