나는 header.php과 footer.php 파일을 가지고 있습니다. 내 HTML 헤더는 header.php이고 나는 index.php 파일을 가지고 있습니다.이전에 포함 된 PHP 파일로 데이터를 보내는 방법은 무엇입니까?
require 'header.php';
$example_code = 'example';
︙
require 'footer.php';
그리고 내 header.php : 난 그렇게 (index.php를)를 사용하고
<html>
<head>
<title>
???
<title>
<meta name="description" content="???" />
<meta name="keywords" content="???" />
</head>
<body>
︙
내가 의 index.php에서 일부 데이터를 보낼 to header.php 거기에 인쇄하십시오 (???
참조). header()
함수를 생각하고 있지만 PHP 설명서에서 예제를 볼 수 없습니다.
달성하고자하는 것을 분명히 할 수 있습니까? –