Solved

web variable question?

Posted on 2003-11-24
3
235 Views
Last Modified: 2008-07-03
Hi export, I just start to use php and has a web variable question:

I have this php file:
<html>
<head>
 <title>
   PHP take ssn input
 </title>
</head>
<body>
<pre>
  <?php
    echo "<h1> hello $ssn !</h1>"; ?>
</pre>
</body>
</html>


and I run this URL:
   http://194.128.100.100/e5_1.php?ssn=123454


What I get is:

hello !.

The $ssn value doesn't display.

Can you help me out here?

Thanks a lot.
0
Comment
Question by:zouwei
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 24

Expert Comment

by:shivsa
ID: 9815248
<?php
$ssn = $_POST['firstname'];

echo( "<h1> hello $ssn !</h1>"; " );

?>
0
 
LVL 24

Accepted Solution

by:
shivsa earned 125 total points
ID: 9815251
sorry type mistake.
<?php
$ssn = $_POST['ssn'];
echo( "<h1> hello $ssn !</h1>"; " );
?>
0
 

Expert Comment

by:GMorgan
ID: 9819843
I always find it better if you seperate the html from the php...not that it makes it work any different :)  I would suggest this....

<? $ssn = $_POST['ssn']; ?>

<h1> hello <? $ssn; ?></h1>


but again that's just a suggestion

Cheers
Glen
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PHP function parameters defined 14 43
Make check boxes work 8 47
PHP encrypted string and passing to a ASP Page 12 50
How to use 2 ON statements in inner join 3 27
Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
Things That Drive Us Nuts Have you noticed the use of the reCaptcha feature at EE and other web sites?  It wants you to read and retype something that looks like this.Insanity!  It's not EE's fault - that's just the way reCaptcha works.  But it is …
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question