You are on page 1of 29

Six Weeks industrial training report

On

Machine Learning in php


Submitted in partial fulfilment of the requirement of the award of
Diploma
In
Computer Science and Engineering

Submitted by-
Name=Jaspreet kaur
Roll no=2020/367

Dept. of Computer Science And Engineering


Thapar polytechnic college,
Patiala-147001
Session 2022
Dept. of Computer Science and Engineering
Thapar polytechnic college
Patiala-147001
Session 2022

DECLARATION

I hereby declare that the Industrial Training Report entitled ("Php")


is an authentic record of my own work as requirements of
Industrial Training during the period from July 15, 2022 to august
26,2022 for the award of diploma (Computer Engineering), Thapar
Polytechnic College, Patiala.

Jaspreet kaur
Reg. no=

PAGE 1
Acknowledgement

We have taken efforts in this project. However, it would


not have been possible without the kind support and help of
many. I am highly indebted to Miss. Chahat Arora
for their guidance and constant supervision as well as for
providing necessary information regarding the project & +
also for their support in completing the project. I would like
to express my gratitude towards my parents & Teaching
staff of the Company Solitaire Infosys, Patiala for their
kind co-operation and encouragement which helped us in
completion of this project.

Table of Contents
Table of Contents………………………………….3
Company: Solitaire Infosys………………………………………..4

PAGE 2
PAGE 3
PAGE 4
Company: Solitaire Infosys
Solitaire" as the name suggests that being supreme in
diamonds. The Name was given to the company with a vision in
which the company is beholding the fabric of the 'Solitaire
Diamond' and imbibed in it. Solitaire Infosys Inc. is an
entrepreneurial and leading IT organization aiming to
encompass global IT services reaching and delivering the best to
our clients all over the world. Started off as a vision five years
ago with a team of IT professionals striving to achieve a
farfetched dream, Solitaire Infosys is now a thriving family of
over 150 employees currently competing neck-to-neck in the
world of technology. Solitaire Infosys Inc. is a leading ISO
9001:2008 certified company delivering cutting-edge and
seamless solutions to organizations in India and all around the
world in major global locations including North America,
Europe, Canada and across United Kingdom.
At Solitaire Infosys inc. we generate the possibilities for our
clients to grow by enhancing their business models through
customized strategies and solutions that bring digital
transformation for advanced results in their respective
markets. Our skilled and innovative professionals provide
tailored and streamlined services to accelerate revenue growth
and reinvent the basic business functionalities.
We believe in providing safe, fun and professional work
environment and also focusing on building good relationships
with the industry and other partners. With all the Blue Sky
Thinking and Raft of Measures we aim to be more assiduous,
zealous, and value-based global IT service providers.

Fig:1.1

PAGE 5
Corporate Training
Solitaire Infosys Inc. offers the best corporate training as per the requisites
ot the burgeoning industry with the
most fulfilling training modules. To bridge the competency gap towards
building a skilled and productive workforce
to meet the challenges of global business competitions by corporate,
Solitaire Infosys focuses on productivity
enhancement training. We provide the best integrated learning
environment which helps to promote growth of
every individual alike by programs, which is important for all our
professionals and provide employees with the
basic foundational skills they need.

Industrial Training
Industrial training plays an important role in a student's life after the
degree or diploma as it gives a chance to the
students to learn new technologies rather than just relying on the
textbooks. We help you to enhance and enlarge
the scope of your skills in all current industrial technologies, providing you
an edge over the competition. We offer
an augmented learning experience with the best facilities and faculty
available at every step

Technologies:

PAGE 6
.

What is PHP?

PAGE 7
PHP stands for PHP: Hypertext Preprocessor. Yes, the first letter in the acronym stands
for the whole acronym -- and that may be one of the most confounding things about
the language. It’s considered a relatively easy one to master.

PHP is a scripting language, especially designed to put up web sites. A common use is
data retrieval from SQL databases. The language is also used to create charts and other
graphics. A designer can, for example, create image links or power a thumbnail image
gallery. PHP carries out common website duties like accepting passwords, authenticating
users, and managing forum posts and guest books. Facebook integration is another
common use.

With PHP, you can even make a website that allows users to generate content – that
includes users who don’t even know the basics of HTML!

A major difference between PHP and traditional forms of HTML is that PHP is dynamic.
It’s not an either-or proposition, however. The two languages are easily integrated. HTML
code may be generated by PHP.

History of php
Originally (it is believed) the letters stood for Personal Home Page. The first work was done by
Rasmus Lerdorf and dates back to about 1994. Lerdorf originally used it for his personal page –
specifically to track visitors. Soon, a lot of additional functions were added. It took a few years,
though, for it to become a language and not just a set of tools.

The code was released in the mid-1990s. Israel’s Andi Gutmans and Zeev Suraski did a major
overhaul in 1997 with the goal of using PHP to run an eCommerce site. Their version, termed
PHP 3.0, had more of the features we expect and see today.

PAGE 8
Fig:1.2

The same duo later created Version 4.0. 2004 saw another major revision, PHP 5.0. Although
there has not yet been a 6.0, there have been significant improvements since 5.0, including the
removal of several things that had caused instability or potential security breaches.

What is a PHP File?


 PHP files can contain text, HTML, CSS, JavaScript, and PHP code
 PHP code is executed on the server, and the result is returned to
the browser as plain HTML
 PHP files have extension ".php"

What Can PHP Do?


 PHP can generate dynamic page content
 PHP can create, open, read, write, delete, and close files on the
server
 PHP can collect form data
 PHP can send and receive cookies
 PHP can add, delete, modify data in your database
 PHP can be used to control user-access
 PHP can encrypt data

What Do I Need?

PAGE 9
To start using PHP, you can:

 Find a web host with PHP and MySQL support


 Install a web server on your own PC, and then install PHP and
MySQL

Set Up PHP on Your Own PC


However, if your server does not support PHP, you must:

 install a web server


 install PHP
 install a database, such as MySQL

 Comments in PHP
 A comment in PHP code is a line that is not executed as a part of
the program. Its only purpose is to be read by someone who is
looking at the code.
 <!--………………………--> (many lines comment).
 //………………………….(single line comment).

 Creating (Declaring) PHP Variables


 In PHP, a variable starts with the $ sign

PHP Variables Scope


In PHP, variables can be declared anywhere in the script.

The scope of a variable is the part of the script where the variable can be
referenced/used.

PHP has three different variable scopes:

 local
 global
 static

 Global, Local and static Scope


 A variable declared outside a function has a GLOBAL SCOPE
 A variable declared within a function has a LOCAL SCOPE

PAGE 10
 The static keyword is also used to declare variables in a function which keep
their value after the function has ended.

The PHP print Statement


The print statement can be used with or without
parentheses: print or print()

example
<?php
echo "<h2>PHP is Fun!</h2>";
echo "Hello world!<br>";
echo "I'm about to learn PHP!<br>";

?>

PHP Data Types


PHP supports the following data types:

 String
 Integer
 Float (floating point numbers - also called double)
 Boolean
 Array
 Object
 NULL
 Resource

PHP Operators
Operators are used to perform operations on variables and values.

PHP divides the operators in the following groups:

 Arithmetic operators
 Assignment operators
 Comparison operators
 Increment/Decrement operators

PAGE 11
 Logical operators
 String operators
 Array operators
 Conditional assignment operators

PHP Conditional Statements


 if statement - executes some code if one condition is true
 if...else statement - executes some code if a condition is true and
another code if that condition is false
 Eg…
<?php
$a=18;
If($a<18)
{
Echo”no.is smaller”;
}
Else
{
Echo”no is greater”;
}
?>

 Nested if else statement - executes different codes for more than


two condition
 Eg..

<?php

If(10>5){

Echo”First no. is greater”;

If(15>10){

Echo”second no. is greater”;

If(10==10){

Echo”both no. are equal”;

PAGE 12
}

?>

 switch statement - selects one of many blocks of code to be


executed.

.Leader if else-

 Eg.

<?php

$a=100;

$b=20;

$c=300;

If($a>$b && $a>$c)

Echo”a is greater”;

Else if($b>$a && $b>$c)

Echo”b is greater”;

Else if($c>$a && $c>$b)

Echo”c is greater”;

PAGE 13
?>

 PHP switch Statement
 The switch statement is used to perform different actions based
on different conditions.

PHP Loops
 while - loops through a block of code as long as the specified
condition is true
 do...while - loops through a block of code once, and then repeats
the loop as long as the specified condition is true
 for - loops through a block of code a specified number of times

 PHP Form Handling
 The PHP super global $_GET and $_POST are used to
collect form-data/*

GET vs. POST


 $_GET is an array of variables passed to the current script via the
URL parameters.
 $_POST is an array of variables passed to the current script via the
HTTP POST method

FEATURES OF PHP:

 PHP can generate dynamic page content.


 PHP can create, open, read, write, delete, and close files on the server.
 PHP can collect form data.
 PHP can send and receive cookies.
 PHP can add, delete, modify data in your database.
 PHP can be used to control user-access.
 PHP can encrypt data.

PAGE 14
 Applications of PHP
 Web Pages and Web-Based Applications
 Web Content Management Systems
 eCommerce Applications
 GUI-Based Applications
 Image Processing and Graphic Design
 Data Representation

HARDWARE AND SOFTWARE REQUIREMENT

.HTML SERVER

.CSS INTERNET FACILITY

.BOOTSTRAP COMPUTER

.PHP MOBILES

.MYSQL

Fig:1.3

PAGE 15
.Download Notepad++

fig:1.4

Fig:1.5

Download server

.Download server(Xamp): for run aur programs

PAGE 16
Fig:1.6

Start Apache and Mysql

MAKING DATABASE

.Write Database code in notepad++.

Fig:1.7

Go to localhost/phpMyAdmin to check whether the database create or


not.

PAGE 17
Fig:1.8

.Now create table in our database.and create fields of your requirement.

Life I have created a signup table

Fig:1.9

.Now again check phpMyAdmin whether the table created or not in


database.

PAGE 18
Fig:1.10

I have make 3 different tables for aur project i.e. Query table

Signup table

Tour and travels table

.Now making different insertion program for different tables.

Fig:1.11

Search localhost/foldername/program name in browser/chrome

PAGE 19
Fig:1.12

fig:1.13

Insert the data then submit it. If inserted then check phpMyAdmin.

Whether the data inserted or not.

Fig:1.14

PAGE 20
.Now making program of account exist or not. If exist then write
account already exist else it makes an account.

Fig:1.15

PAGE 21
PROJECT MAKING
.First we have to download tour and travel(project name) template

Fig:1.16

.Now open its pages code in notepad++ and save it in php(.php).

Home page:

Then you have to do changes in it according to your requirements..In


my project

Fig:1.17

PAGE 22
.First I have link home page to the signup table so that all the entries
are inserted in database are inserted in database

Fig:1.18

Fetch images:

Now we have fetch the images from the table.

Fig:1.19

PAGE 23
Fig:1.20

These are the images which are obtained by the table(tour and travel).

Login page:

Now we are making login page

Fig:1.21

In this page, if there is an account then login will be done otherwise it


will be written wrong username and password.

PAGE 24
Fig:1.22

In this also we will insert images from table like home page.

Gallery page:

Now we have inserted a gallery page. The gallery page will only contain
images of packages.

Fig:1.23

PAGE 25
Destination page:

Fig:1.24

Cites page:

Next we have make different cites pages for destination and link with
each other.

Fig:1.25

I use select query: select * from tourandtravels where city=’patiala’;

For linking I use code: <?php echo"<a class='h5 text-decoration-none'


href=single_detail.php?x=$c[0]>";?>

<span><?php echo $c[2] ?></span>

<?php echo"</a>"?>

PAGE 26
For linking pages with each other:

Fig:1.26

[note: All pages making in the same way]

Contact page: Next we will make contact page (i.e.last page).we will
link this page.

Fig:1.27

Data should be inserted in the database.

PAGE 27
Fig:1.28

PAGE 28

You might also like