proplem中包含页眉和页脚

proplem中包含页眉和页脚

本文介绍了如何在php withot proplem中包含页眉和页脚的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

抱歉我的英语不好

我在php编写注册4m和mysm中的fourm插入adata



但是当我添加

include'header.php';

include'foter.php';



四分之一的净插入数据并没有向我显示错误



这是文件







foter.php

hello
sorry my inglish is not good
iam coding signup fourm in php and the fourm insert adata in mysql

But when I added
include'header.php';
include'foter.php';

the fourm net insert data and did not show to me an error

this is file

here

foter.php

            <!-- Footer Section -->
           <footer class="footer-section section no-padding-bottom">
                <!-- footer logo -->
                <div class="footer-logo">
                        <img src="http://placehold.it/200x70" alt="logo" />
                    <p class="font-second">
                        Prestito
                    </p>
                </div>
                <!--/ End footer logo -->
                <!-- Social icons -->
                <div class="footer-social">
                    <a href="#." class="fa fa-facebook-square wow fadeIn" data-wow-offset="150" data-wow-delay="0s"></a>
                    <a href="#." class="fa fa-twitter wow fadeIn" data-wow-offset="150" data-wow-delay=".15s"></a>
                    <a href="#." class="fa fa-google-plus wow fadeIn" data-wow-offset="150" data-wow-delay=".3s"></a>
                    <a href="#." class="fa fa-youtube-play wow fadeIn" data-wow-offset="150" data-wow-delay=".6s"></a>
                </div>
                <!--/ End Social icons -->
                <!-- go top pop-up -->
                <div id="go-top" class="go-top go-top-out in-page-scroll">
                    <div class="circle1"></div>
                    <a href="#top" class="square"><span></span></a>
                    <div class="rectangle"></div>
                    <div class="circle2"></div>
                </div>
                <!--/ End go top pop-up -->
                <div class="footer-bottom">
                    <!-- Copyright -->
                    <a class="footer-bottom-text font-second" href="http://prestito.com" target="_blank">Prestito © 2016. All Right Reserved.</a>
                    <!-- End Copyright -->
                </div>
            </footer>
            <!--/ End Footer Section -->
        </div>
        <!--/ #page-2 -->
            <!--/ End Footer Section -->
        </div>
        <!--/ #page-2 -->
    </div>
    <!--/ #page -->
    <!-- JS Scripts -->
    <script src="js/modernizr.min.js"></script>
    <script src="js/mapgo.js"></script>
    <script src="js/jquery-2.1.1.min.js"></script>
    <script src="js/jquery.easing.1.3.min.js"></script>
    <script src="js/jquery.animsition.min.js"></script>
    <script src="js/smoothscroll.js"></script>
    <script src="js/skrollr.min.js"></script>
    <script src="js/wow.min.js"></script>
    <script src="js/waypoints.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
    <script src="js/jquery.counterup.min.js"></script>
    <script src="js/owl.carousel.min.js"></script>
    <script src="js/animateSlider.js"></script>
    <script src="js/animated-headlines.js"></script>
    <script src="js/jquery.mb.YTPlayer.min.js"></script>
    <script src="js/jquery.vide.min.js"></script>
    <script src="js/jquery.particleground.min.js"></script>
    <script src="js/fss.min.js"></script>
    <script src="js/fssinit.js"></script>
    <script src="js/retina.min.js"></script>
    <script src="js/isotope.pkgd.min.js"></script>
    <script src="js/nivo-lightbox.min.js"></script>
    <script src="js/contactForm.js"></script>
    <script src="https://maps.googleapis.com/maps/api/js?sensor=false"></script>
    <script src="js/scripts.min.js"></script>
    <!--/ End JS Scripts -->
</body>

</html>







header.php
<small>
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <title>Prestito</title>
    <!-- Bootstrap  //el8wa2em ele foo8 w3ard el9f7a wtrtebha-->
    <link rel="stylesheet" href="css/bootstrap.min.css">
   <link rel="stylesheet" href="css/mapgo.css">
    <!-- Fonts Icons  el9war ele blno9-->
    <link rel="stylesheet" href="css/custom-icons.css">
    <link rel="stylesheet" href="css/et-line-icons.css">
    <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">
    <!-- Owl Carousel elktabeh ele blno9-->
    <link rel="stylesheet" href="css/owl.carousel.min.css">
    <!-- Nivo Lightbox // social media ele blfoter-->
    <link rel="stylesheet" href="css/nivo-lightbox/nivo-lightbox.css">
    <link rel="stylesheet" href="css/nivo-lightbox/lightbox-theme.css">
    <!-- Animated Headlines elktabeh ele fooq el9ora -->
    <link rel="stylesheet" href="css/animated-hedlines.css">
      <!-- Main Styles  -->
    <link href="css/styles.css" rel="stylesheet">
    <!-- Theme background -->
    <link href="css/theme/light-green.css" rel="stylesheet" data-color="" id="theme">
    <!-- Animsition  loading wb3le8 awal ma tqemha-->
    <link href="css/animsition.min.css" rel="stylesheet">
    <!-- Favicon (retina) -->

</head>

<body>
    <!-- Page Wrapper -->
    <div id="page" class="animsition equal" data-loader-type="loader2" data-page-loader-text="Prestito" data-animsition-in="zoom-outy" data-animsition-out="fade-out-up-sm" style="transform-origin: 50% 50vh;">
        <div id="top"></div>
        <!-- Home Section -->

        <!--/ End Home Section -->
        <!-- Navbar -->
        <div class="position-relative">
            <!-- sticky: 1) remove"transp-nav" class, add class="sticky-navbar" to #nav-wrapper | 2) remove navbar-fixed-top class from #nav [and navbar-transparent class too] -->
            <div id="nav-wrapper" class="transp-nav">
                <nav id="nav" class="navbar navbar-fixed-top navbar-transparent navbar-dark ripple-group-parent init-animation-1" role="navigation">
                    <!-- progressbar -->
                    <div id="scroll-progressbar" class="scroll-progressbar">
                        <div>
                            <span class="scroll-shadow"></span>
                        </div>
                    </div>
                    <div class="container in-page-scroll">
                        <!-- Brand and toggle get grouped for better mobile display -->
                        <div class="navbar-header">
                            <button type="button" id="animated-navicon" class="navbar-toggle" data-toggle="collapse" data-target="#mobile-navbar-collapse">
                                <span class="sr-only">Toggle navigation</span>
                                <span class="icon-bar"></span>
                                <span class="icon-bar"></span>
                                <span class="icon-bar"></span>
                            </button>
                            <a class="navbar-brand ripple-group" href="#top">
                                <div class="navbar-logo pull-left">
                                    <img src="http://placehold.it/100x40" alt="logo" />
                                </div>
                                <p class="pull-left font-second">Prestito</p>
                            </a>
                        </div>
                        <!-- Collect the nav links, forms, and other content for toggling -->
                        <div class="collapse navbar-collapse" id="mobile-navbar-collapse">
                            <ul class="nav navbar-nav navbar-right cl-effect-5">
                                <li>
                                    <a class="ripple-group" href="index.html">
                                        <span data-hover="home">home</span>
                                    </a>
                                </li>
                                <li>
                                    <a class="ripple-group" href="index.html">
                                        <span data-hover="about">about</span>
                                    </a>
                                </li>
                                <li>
                                    <a class="ripple-group" href="index.html">
                                        <span data-hover="services">services</span>
                                    </a>
                                </li>
                                <li>
                                    <a class="ripple-group" href="index.html">
                                        <span data-hover="contact">contact</span>
                                    </a>
                                </li>
                                <li>
                                    <a class="ripple-group" href="signin.html">
                                        <span data-hover="LOGIN">SIGN IN</span>
                                    </a>
                                </li>

                                <li>
                                    <a class="ripple-group" href="signup.html">
                                        <span data-hover="JOIN US">SIGN UP</span>
                                    </a>
                                </li>

                            </ul>
                        </div>
                        <!-- /.navbar-collapse -->
                    </div>
                    <!-- /.container -->
                </nav>
            </div>
        </div>
        <!--/ End Navbar --></div>





test.p hp \"signup\"







test.php "signup"


<?php <br mode="hold" /?>
			include'inclode/config.php';
			include'header.php';

#=============[POST VALUE]=============#
//strip_tags 3$an ymna3 code html
//md5 3$an yshfer elpassworld
$fname = strip_tags($_POST['u_fname']);
$lname = strip_tags($_POST['u_lname']);
$email =  strip_tags($_POST['u_email']);
$pass =  md5($_POST['u_pass']);
$phonenum = strip_tags($_POST['u_phonenum']);

$country = strip_tags($_POST['u_country']);
$street = strip_tags($_POST['u_street']);
$bulnum = strip_tags($_POST['u_bulnum']);

#=============[POST VALUE]=============#

if(isset($_POST['adduser'])){
	$insertuser = mysql_query("INSERT INTO
	user (u_fname,u_lname,u_email,u_pass,u_phonenum,u_country,u_street)
	VALUES
	('$fname','$lname','$email','$pass','$phonenum','$country','$street')
	") or die(mysql_error());

	if(isset($insertuser)){
		echo"
		<h2>insert is done</h2>
		";
		exit;
	}

}
			echo'  <!-- Contact Section -->
            <section id="contact-section" class="section contact-section">
                <div class="container">
                    <div class="section-title">
                        <div class=" section-title-more">
                            Wanna Join us?
                        </div>
                        <div>
                            <h2 class="section-title-heading"><span>REGESTER now</span></h2>
                        </div>
                    </div>

                    <div class="row">
                        <div class="col-md-offset-1 col-md-10">
                            <form id="ajax-contact" class="" method="post" action="test.php">
                                <fieldset>
								<div id="map_wrapper">
    <div id="map_canvas" class="mapping"></div>
</div>
                                    <div class="row">
                                        <!--FIRST NAME -->
										<div class="input col-xs-12 col-sm-6 padding-bottom-xs-50 padding-bottom-40">
                                            <label class="input-label" for="f-name">
                                                <span class="input-label-content font-second" data-content="f-name">First Name *</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_fname" id="f-name" required />
                                        </div>
										<!--LAST NAME -->
										<div class="input col-xs-12 col-sm-6 padding-bottom-xs-50 padding-bottom-40">
                                            <label class="input-label" for="l-name">
                                                <span class="input-label-content font-second" data-content="l-name">last Name *</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_lname" id="l-name" required />
                                        </div>
										<!--E-MAIL -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-50 padding-bottom-50">
                                            <label class="input-label" for="email">
                                                <span class="input-label-content font-second" data-content="email">email *</span>
                                            </label>
                                            <input class="input-field" type="email" name="u_email" id="email" required />
                                        </div>
										<!--PHONE NUMBER -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="phone-num">
                                                <span class="input-label-content font-second" data-content="phone-num">Phone Number</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_phonenum" id="phone-num" />
                                        </div>
										<!--PASSWORLD -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="pass">
                                                <span class="input-label-content font-second" data-content="pass">Passworld</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_pass" id="pass" />
                                        </div>
										<!--CONFIRM PASSWORLD -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="pass">
                                                <span class="input-label-content font-second" data-content="pass">Confim Passworld</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_pass" id="pass" />
                                        </div>
										<!--COUNTRY -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="country">
                                                <span class="input-label-content font-second" data-content="country">Country</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_country" id="country" />
                                        </div>
										<!--STREET -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="street">
                                                <span class="input-label-content font-second" data-content="street">Street</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_street" id="street" />
                                        </div>
										<!--BULDING NUMBER -->
                                        <div class="input col-xs-12 col-sm-6 padding-bottom-xs-60 padding-bottom-50">
                                            <label class="input-label" for="bul-num">
                                                <span class="input-label-content font-second" data-content="bul-num">Bulding Number</span>
                                            </label>
                                            <input class="input-field" type="text" name="u_bulnum" id="bul-num" />
                                        </div>

										<!-- -->
                                        <div class="message col-xs-12 col-sm-12 padding-bottom-xs-40 padding-bottom-30">
                                            <label class="textarea-label font-second" for="message">message *</label>
                                            <textarea class="input-field textarea" name="u_message" id="message" required></textarea>
                                        </div>
                                    </div>
                                    <div id="form-messages" class="form-message"></div>
                                    <div class="col-xs-12 margin-top-30 text-center">
                                        <button name="adduser" id="btn-submit" type="submit" class="btn btn-animated btn-contact ripple-alone" data-text="send it"><span class="btn-icon"><span class="loader-parent"><span class="loader3"></span></span>
                                            </span>
                                        </button>
                                    </div>
                                </fieldset>
                            </form>
                              <!--/ End form -->

                        </div>
                        <!--/ .col -->
                    </div>
                    <!--/ .row -->
                </div>
               // <!--/ .container -->
            </section>
            <!--/ End Contact Section -->

			';
			mysql_close($connectdb);

			include'foter.php';
			?>

\t\t\t

推荐答案




这篇关于如何在php withot proplem中包含页眉和页脚的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-23 02:57