This document provides an introduction and instructions for connecting a PHP application to a MySQL database. It discusses storing and retrieving data from the database. The key steps covered are:
1. Connecting to the MySQL server from PHP using mysql_connect().
2. Selecting the database to use with mysql_select_db().
3. Executing SQL queries to store/retrieve data with mysql_query().
4. Different mysql_fetch_* functions that can be used to retrieve rows of data from a database query.
An example task is provided where a registration form allows storing user data to a database table, and then retrieving and displaying the stored data in a table.
We are covering following topics:
If...Else...Elseif Statements: if statement executes some code if one condition is true.
Switch Statement: Switch Statement tests a variable against a series of values.
For Loop: For loop executes a block of code a specified number of times.
While Loop: While loop executes a block of code as long as the specified condition is true.
Do…While Loop: Do...While loop will always execute the block of code once, it will then check the condition, and repeat the loop while the specified condition is true.
This is the presentation file about inheritance in java. You can learn details about inheritance and method overriding in inheritance in java. I think it's can help your. Thank you.
This ppt gives information about:
1. OOPs Theory
2. Defining a Class
3. Creating an Object
4. The $this Attribute
5. Creating Constructors
6. Creating Destructors
PHP string function helps us to manipulate string in various ways. There are various types of string function available. Here we discuss some important functions and its use with examples.
We are covering following topics:
If...Else...Elseif Statements: if statement executes some code if one condition is true.
Switch Statement: Switch Statement tests a variable against a series of values.
For Loop: For loop executes a block of code a specified number of times.
While Loop: While loop executes a block of code as long as the specified condition is true.
Do…While Loop: Do...While loop will always execute the block of code once, it will then check the condition, and repeat the loop while the specified condition is true.
This is the presentation file about inheritance in java. You can learn details about inheritance and method overriding in inheritance in java. I think it's can help your. Thank you.
This ppt gives information about:
1. OOPs Theory
2. Defining a Class
3. Creating an Object
4. The $this Attribute
5. Creating Constructors
6. Creating Destructors
PHP string function helps us to manipulate string in various ways. There are various types of string function available. Here we discuss some important functions and its use with examples.
99LMS is a mobile based comprehensive enterprise learning environment in which learning processes of a company can be managed and integrated. It ensures employees have the right skills by enabling course content management, providing classroom training and e-learning. Through the APIs, you can develop your resources before they join your company.
Templates in Django - Python, How to use master page in Django using Templates, How to fix TemplateDoesNotExist at error in Django. How to run Django applications in Windows. How a Django view works.
Session and cookies knowledge is very important for a web developer. In these slides we are going to explore basics of Sessions and Cookies in PHP. How to create and destroy a session. How to create and destroy a cookie. How sessions and cookies are stored.
this ppt will give you information about :
1. Introduction to www
2. History Understanding client/server roles Apache
3. HTML
4. PHP
5. MySQL
6. JS
7. HTML & CSS
8. XAMPP Installation
Introduction
Web Storage
WebSQL
IndexedDB
File System Access
Final Considerations
This presentation has been developed in the context of the Mobile Applications Development course, DISIM, University of L'Aquila (Italy), Spring 2015.
http://www.ivanomalavolta.com
Dicoding Developer Coaching #27: Android | Membuat Aplikasi Support Online Ma...DicodingEvent
Dicoding Developer Coaching merupakan webinar, yang membahas tuntas kendala maupun pertanyaan yang sering ditanyakan di Academy Dicoding.
Tema kali ini adalah "Membuat Aplikasi Support Online Maupun Offline"
Di sini Anda akan belajar mengenai bagaimana cara membuat aplikasi yang mendukung proses Online maupun Offline. Hal ini memungkinkan aplikasi Anda untuk dapat diakses meskipun tidak terhubung dengan internet, dan juga dapat menghemat bandwith atau sumber daya perangkat Anda karena tidak perlu lagi memuat data terus menerus.
Building Lithium Apps (Like a Boss) was a workshop presented on the structure and philosophy of the Lithium framework and its applications, and how best to take advantage of them.
This PPT will help to understand how learning happens in brain. How you can adjust your skill acquisition in the right way so that maximum output is obtained.
Baabtra.com has a solution to provide programming for kids in school. This is based on the CBSE curriculum of India. The main subjects covered are Mathematics and Physics.
2024.06.01 Introducing a competency framework for languag learning materials ...Sandy Millin
http://sandymillin.wordpress.com/iateflwebinar2024
Published classroom materials form the basis of syllabuses, drive teacher professional development, and have a potentially huge influence on learners, teachers and education systems. All teachers also create their own materials, whether a few sentences on a blackboard, a highly-structured fully-realised online course, or anything in between. Despite this, the knowledge and skills needed to create effective language learning materials are rarely part of teacher training, and are mostly learnt by trial and error.
Knowledge and skills frameworks, generally called competency frameworks, for ELT teachers, trainers and managers have existed for a few years now. However, until I created one for my MA dissertation, there wasn’t one drawing together what we need to know and do to be able to effectively produce language learning materials.
This webinar will introduce you to my framework, highlighting the key competencies I identified from my research. It will also show how anybody involved in language teaching (any language, not just English!), teacher training, managing schools or developing language learning materials can benefit from using the framework.
Unit 8 - Information and Communication Technology (Paper I).pdfThiyagu K
This slides describes the basic concepts of ICT, basics of Email, Emerging Technology and Digital Initiatives in Education. This presentations aligns with the UGC Paper I syllabus.
Honest Reviews of Tim Han LMA Course Program.pptxtimhan337
Personal development courses are widely available today, with each one promising life-changing outcomes. Tim Han’s Life Mastery Achievers (LMA) Course has drawn a lot of interest. In addition to offering my frank assessment of Success Insider’s LMA Course, this piece examines the course’s effects via a variety of Tim Han LMA course reviews and Success Insider comments.
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdfTechSoup
In this webinar you will learn how your organization can access TechSoup's wide variety of product discount and donation programs. From hardware to software, we'll give you a tour of the tools available to help your nonprofit with productivity, collaboration, financial management, donor tracking, security, and more.
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
Francesca Gottschalk - How can education support child empowerment.pptxEduSkills OECD
Francesca Gottschalk from the OECD’s Centre for Educational Research and Innovation presents at the Ask an Expert Webinar: How can education support child empowerment?
How to Make a Field invisible in Odoo 17Celine George
It is possible to hide or invisible some fields in odoo. Commonly using “invisible” attribute in the field definition to invisible the fields. This slide will show how to make a field invisible in odoo 17.
Instructions for Submissions thorugh G- Classroom.pptxJheel Barad
This presentation provides a briefing on how to upload submissions and documents in Google Classroom. It was prepared as part of an orientation for new Sainik School in-service teacher trainees. As a training officer, my goal is to ensure that you are comfortable and proficient with this essential tool for managing assignments and fostering student engagement.
The Roman Empire A Historical Colossus.pdfkaushalkr1407
The Roman Empire, a vast and enduring power, stands as one of history's most remarkable civilizations, leaving an indelible imprint on the world. It emerged from the Roman Republic, transitioning into an imperial powerhouse under the leadership of Augustus Caesar in 27 BCE. This transformation marked the beginning of an era defined by unprecedented territorial expansion, architectural marvels, and profound cultural influence.
The empire's roots lie in the city of Rome, founded, according to legend, by Romulus in 753 BCE. Over centuries, Rome evolved from a small settlement to a formidable republic, characterized by a complex political system with elected officials and checks on power. However, internal strife, class conflicts, and military ambitions paved the way for the end of the Republic. Julius Caesar’s dictatorship and subsequent assassination in 44 BCE created a power vacuum, leading to a civil war. Octavian, later Augustus, emerged victorious, heralding the Roman Empire’s birth.
Under Augustus, the empire experienced the Pax Romana, a 200-year period of relative peace and stability. Augustus reformed the military, established efficient administrative systems, and initiated grand construction projects. The empire's borders expanded, encompassing territories from Britain to Egypt and from Spain to the Euphrates. Roman legions, renowned for their discipline and engineering prowess, secured and maintained these vast territories, building roads, fortifications, and cities that facilitated control and integration.
The Roman Empire’s society was hierarchical, with a rigid class system. At the top were the patricians, wealthy elites who held significant political power. Below them were the plebeians, free citizens with limited political influence, and the vast numbers of slaves who formed the backbone of the economy. The family unit was central, governed by the paterfamilias, the male head who held absolute authority.
Culturally, the Romans were eclectic, absorbing and adapting elements from the civilizations they encountered, particularly the Greeks. Roman art, literature, and philosophy reflected this synthesis, creating a rich cultural tapestry. Latin, the Roman language, became the lingua franca of the Western world, influencing numerous modern languages.
Roman architecture and engineering achievements were monumental. They perfected the arch, vault, and dome, constructing enduring structures like the Colosseum, Pantheon, and aqueducts. These engineering marvels not only showcased Roman ingenuity but also served practical purposes, from public entertainment to water supply.
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...Levi Shapiro
Letter from the Congress of the United States regarding Anti-Semitism sent June 3rd to MIT President Sally Kornbluth, MIT Corp Chair, Mark Gorenberg
Dear Dr. Kornbluth and Mr. Gorenberg,
The US House of Representatives is deeply concerned by ongoing and pervasive acts of antisemitic
harassment and intimidation at the Massachusetts Institute of Technology (MIT). Failing to act decisively to ensure a safe learning environment for all students would be a grave dereliction of your responsibilities as President of MIT and Chair of the MIT Corporation.
This Congress will not stand idly by and allow an environment hostile to Jewish students to persist. The House believes that your institution is in violation of Title VI of the Civil Rights Act, and the inability or
unwillingness to rectify this violation through action requires accountability.
Postsecondary education is a unique opportunity for students to learn and have their ideas and beliefs challenged. However, universities receiving hundreds of millions of federal funds annually have denied
students that opportunity and have been hijacked to become venues for the promotion of terrorism, antisemitic harassment and intimidation, unlawful encampments, and in some cases, assaults and riots.
The House of Representatives will not countenance the use of federal funds to indoctrinate students into hateful, antisemitic, anti-American supporters of terrorism. Investigations into campus antisemitism by the Committee on Education and the Workforce and the Committee on Ways and Means have been expanded into a Congress-wide probe across all relevant jurisdictions to address this national crisis. The undersigned Committees will conduct oversight into the use of federal funds at MIT and its learning environment under authorities granted to each Committee.
• The Committee on Education and the Workforce has been investigating your institution since December 7, 2023. The Committee has broad jurisdiction over postsecondary education, including its compliance with Title VI of the Civil Rights Act, campus safety concerns over disruptions to the learning environment, and the awarding of federal student aid under the Higher Education Act.
• The Committee on Oversight and Accountability is investigating the sources of funding and other support flowing to groups espousing pro-Hamas propaganda and engaged in antisemitic harassment and intimidation of students. The Committee on Oversight and Accountability is the principal oversight committee of the US House of Representatives and has broad authority to investigate “any matter” at “any time” under House Rule X.
• The Committee on Ways and Means has been investigating several universities since November 15, 2023, when the Committee held a hearing entitled From Ivory Towers to Dark Corners: Investigating the Nexus Between Antisemitism, Tax-Exempt Universities, and Terror Financing. The Committee followed the hearing with letters to those institutions on January 10, 202
3. What you Benefit ???
By the end of this session you will learn how to use PHP to
● Store the data into database.
● Retrieve data from the backend database in real-time.
4. TASK OF THE DAY
Create the registration form shown here and store the data passed with it into a
database .
10. STEP 3-
QUERY EXECUTION
mysql_query(“query to be executed”);
Eg: mysql_query(“update table baabtra_mentees_tbl
set vchr_cmpny_name=’Baabtra’
where pk_int_branch_id=’Caffit’ ”);
11. Let’s TRY
Why don’t we make it even more interesting by implementing this with our task.
So let’s start
14. Step2
Step 2: Now create a database to store the data passed from registration form
15. Step 2
Lets create the database
create database company_baabtra;
Create a table tbl_baabtra_mentees as shown here
16. Step 3
Step 3: Retrieve the data passed using POST method from register_action.php
Checks if button click is set
File upload
Reading the
checked values from
checkbox
17. Step 4
Step 4: Data is now available at register_action.php. So next step is to store this
data into the database.
23. Step 6
Step 6: Check your database. It should be updated somewhat like that
24. Connecting Database to PHP
Now how do we fetch the data stored in database from frontend ??
25. Retrieving Data From MySQL
There are four different ways to fetch the data from database using PHP.
▪ Mysql_fetch_array()
▪ Mysql_fetch_row()
▪ Mysql_fetch_assoc()
▪ Mysql_fetch_object()
All of the above will return one row from table at a time and then the next row
and so on . So usually we use these functions along with a while loop
26. mysql_fetch_row()
$query = mysql_query (“select * from tbl_baabtra_mentees");
while($fetch=mysql_fetch_row($query))
{
echo $fetch[0]; //prints first column the retrieved row
echo $fetch[1]; //prints second column the retrieved row
}
27. mysql_fetch_assoc()
$query = mysql_query (“select * from tbl_baabtra_mentees");
while($fetch=mysql_fetch_assoc($query))
{
echo $fetch[‘vchr_uname’]; //prints first column the retrieved row
echo $fetch[‘vchr_phone’]; //prints second column the retrieved row
}
28. mysql_fetch_array()
$query = mysql_query (“select * from tbl_baabtra_mentees");
while($fetch=mysql_fetch_array($query))
{
echo $fetch[0]; //prints first column the retrieved row
echo $fetch[‘vchr_phone’]; //prints second column the retrieved row
}
29. mysql_fetch_object()
$query = mysql_query (“select * from tbl_baabtra_mentees");
while($fetch=mysql_fetch_object($query))
{
echo $fetch -> ‘vchr_uname’; //prints first column the retrieved row
echo $fetch -> ‘vchr_phone’; //prints second column the retrieved row
}
30. mysql_fetch_object()
$query = mysql_query (“select * from tbl_baabtra_mentees");
while($fetch=mysql_fetch_object($query))
{
echo $fetch -> ‘vchr_uname’; //prints first column the retrieved row
echo $fetch -> ‘vchr_phone’; //prints second column the retrieved row
}
“Returns an object with properties that correspond to the fetched row and moves
the internal data pointer ahead.”
32. Let’s Get Back With Our Task
Step 7: Set a header to redirect from
‘register_action.php’ to ‘view_baabtra_mentees.php’
header(‘Location: view_baabtra_mentees.php’);
33. Let’s Get Back With Our Task
Step 8: Now fetch the data from tbl_baabtra_mentees and display it in a
table format.