Write the php script to output the session contents, PHP Web Programming

Assignment Help:

Question:

(a) A website wishes to use sessions to store the user's name and display a welcome message on all its pages. The user enters his username in a textbox called "username".

(i) Write the PHP script to create the session and store the user's name in that session.

(ii) Write the PHP script to output the session contents to the user only if the session exists and it is not empty.

(b) Write the PHP script that allows you to:

(i) Create a file named "logfile.log" in the same folder.

(ii) Insert the text "Monday 12 Oct" in this file.

(c) A website wishes to store user complaints in a database. The user enters his comments in a textarea called "complaints" and the form uses the POST method.

Write the PHP script to retrieve and clean up the user input before it can be safely stored in the database and explain your code.

(d) Outline the md5() function and provide an example of a situation where it is necessary to use the md5() function.


Related Discussions:- Write the php script to output the session contents

Javascript with html, Events are actions which can be detected through Java...

Events are actions which can be detected through JavaScript.  An example would be the on Mouse Over event that is detected while the user moves the mouse on an object.  Another eve

I need help in erp/manufacturing website, I need help in ERP/Manufacturing ...

I need help in ERP/Manufacturing Website Seeking an internal-use ERP/Manufacturing Website developed for use at a Paper Mill. Modules/areas would comprising Customers, Sales Ord

I am seeking to build a site where people will sign-up, Social Integration ...

Social Integration site I am seeking to build a site where people will sign up for an account. Therefore every time they log in to my site, it will likewise log them into their

Need drupal expert to check website downtime after migrating, Need Drupal e...

Need Drupal expert to check website downtime after migrating to drupal 7.0 CMS We are looking for help to check on our website which has been experiencing intermittent downtime

Wordpress website redesign and integrations needed, Wordpress website redes...

Wordpress website redesign and integrations (PHP) We want to redesign our wordpress site with our very own custom template. There are as well several integrations with services,

We need help in online map indicating locations of web page, We need help i...

We need help in online map indicating locations of web page visitors Seeking someone who can program a global map that indicates the locations of visitors for a 24-hour period (

Creating a web application, 1. Introduction The assignment is a continua...

1. Introduction The assignment is a continuation of the first assignment. You will use all your knowledge of web and internet to develop a fully functional site. We expect your

Want someone who can create wordpress plugin, Wordpress plugin Want some...

Wordpress plugin Want someone who can create (or modify existing) WP plugin to act like Desired Skills are PHP, WordPress

We want a very skilful wp theme bug fix, WordPress theme bug fix We inst...

WordPress theme bug fix We installed a bought WP theme It was working acceptable at the beginning Most probable for the reason that of WP upgrades or other plugin upgrades

Looking for a good programmer to work with my graphic design, I am looking ...

I am looking for a good programmer to work with my graphic design/illustrator on my team to actively blend animation with gameplay and create a fun, simple and easy, 2d iPhone gam

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd