Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1061975
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T18:33:14+00:00 2026-05-16T18:33:14+00:00

i have a php code here and wondering how can this display what you

  • 0

i have a php code here and wondering how can this display what you have wrote in the box:
i did this and it did display this one: “$input”; ?> “

 <html>
 <head></head>
 <body>
 <form action="message.php" method="post">
 Enter your message: <input type="text" name="msg" size="30">
 <input type="submit" value="Send">
 </form>
 </body>
 </html> 

===============
this is my message.php

   <html>
   <head></head>
   <body>

     <?php
     // retrieve form data
     $input = $_POST['msg'];
      // use it
     echo "You said: <i>$input</i>";
     ?>

    </body>
    </html> 

=======

This is what i get as view page source:

        <html>
        <head></head>
         <body>

          <?php
           // retrieve form data
          $input = $_POST['msg'];
        // use it
         echo "You said: <i>$input</i>";
            ?>

            </body>
             </html> 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T18:33:15+00:00Added an answer on May 16, 2026 at 6:33 pm

    If you view a html file from Notepad++, it will open in the browser from its location on the disk. Then the link in the form points to your php file on the disk. (The address field will read file:/// and the php won’t be parsed.)
    Notepad++ doesn’t know that the same file can be reached via http://localhost/namedform.htm so you’ll have to access it via localhost in order to get the php parsing for message.php to work. Now your address field should start with http://. Later you can just hit “reload” in your browser after you made and !saved! any changes.

    edit:
    Although reloading php pages after edit & save seems to me like the natural thing even after years of php programming, here are some solutions that let you preview your file from notepad++ via the web server:

    1. Add some javascript to the html file you want to preview that checks if the address starts with http:// or file:///. If it is the latter, reload the file from http://localhost.
    2. Search the settings of notepad++ for the default preview options. Change to preview from localhost. Maybe you need an extension for that. I’m not that deep into the subject.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this code here in PHP using Codeigniter framework, I can't seem to
i have this code right here: <select name=group> <option value=>Choose a group....</option> <?php foreach($groups
I'm wondering how I can make this code safer, I'm using it as login.php:
So I have some PHP code that looks like: $message = 'Here is the
here is my mysql and php code layout: I have 3 tables tableA stores
Here my code, I need to insert into mysql database I have mysql,php,android 1)
I am modifying my PHP network's code to have user roles like wordpress here
I have found some code on measuring execution time here http://www.dreamincode.net/forums/index.php?showtopic=24685 However, it does
I have a php code like this,and I need to convert it to .NET
I have this PHP code to highlight the Query on search results. if (isset($_REQUEST['k'])){

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.