By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,278 Members | 1,359 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,278 IT Pros & Developers. It's quick & easy.

Problem with PHP using WAMP

P: 1
I have a problem using php installed using wamp.

Expand|Select|Wrap|Line Numbers
  1. <?php
  2. echo"Hello!";
  3. ?>
The o/p is displayed as in the browser(Mozilla and MSIE)
{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl {\f0\fswiss\fcharset0 Arial;}} {\*\generator Msftedit;}\viewkind4\uc1\pard\f0\fs20 \par \par \par } �

Can anyone please help me
Sep 29 '08 #1
Share this Question
Share on Google+
3 Replies

Expert 5K+
P: 6,050
Wow, that is strange. Are you *sure* that's all you have in the file?
Hm, I'm stumped.. never seen anything like that before.
Sep 29 '08 #2

Expert 5K+
P: 5,058

What program did you use to create this file?
Could it be that it is saving the file as some proprietary text format (like .doc) rather than plain-text?
Sep 29 '08 #3

P: 1

Yes. Simple problem. Your input file is corrupt or is an unknown format. For example, you have created an RTF or DOC file and saved it as text. It looks like text, but has strange characters in it.

To resolve:
1. Open Notepad or Vi
2. Put in your code, eg:
Expand|Select|Wrap|Line Numbers
  1. <?PHP phpinfo(); ?>
3. Save the file eg phpinfo.php
4. Load the page in your browser (eg: http://localhost/phpinfo.php )

The reason you can't see this is that your text editor is nicely handling the viewing of your file.
Mar 22 '12 #4

Post your reply

Sign in to post your reply or Sign up for a free account.