I don't know how to call it, I don't know where to ask, ... please give me a hint
My problem:
I should answer with a php program JUST text
No doctype, head, body, ... just a simple text.
How to do? Where to ask?
I don't know how to call it, I don't know where to ask, ... please give me a hint
My problem:
I should answer with a php program JUST text
No doctype, head, body, ... just a simple text.
How to do? Where to ask?
I am from the government, I am here to help you! Just ask!
And don't expect more to be happen than with any other government!
If you are serving up plain text, you can set the MIME type to "plain/text"
See the function header()Code:<?php header('Content-Type: text/plain'); echo ("Hello, world!"); ?>
http://www.php.net/manual/en/function.header.php
It did not work for me:
Now it displays:
But I need only:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>title</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<meta name="generator" content="Geany 0.21" />
<link rel="stylesheet" type="text/css" href="mnp.css" />
</head>
<body>
MyText
</BODY>
</HTML>
MyText
I am from the government, I am here to help you! Just ask!
And don't expect more to be happen than with any other government!
You might double-check the actual content of the file. It looks like the document itself is HTML. Some of the HTML markup there implies that the page was manually written as HTML, not as some artifact of PHP. What is the output of the file if you use a terminal window and open up the file using "cat" or "less" ?
It is a php program and it calculates some values, which I should display in PURE text.
When I just "echo $text" it looked fine, but the other machine sees all the other code, ...
I can now make it "visible" with your methode, but I want to avoid it all together. How can I do that?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>title</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<link rel="stylesheet" type="text/css" href="mnp.css" />
</head>
<body>
Hello, world!<p>
</BODY>
</HTML>
I am from the government, I am here to help you! Just ask!
And don't expect more to be happen than with any other government!
I solved it: Just don't write the HTML tags, ...
It was simple too easy to think of that!!!
I am from the government, I am here to help you! Just ask!
And don't expect more to be happen than with any other government!
Bookmarks