You are here: Re: NO book i read did sticky form correctly « PHP Programming Language « IT news, forums, messages
Re: NO book i read did sticky form correctly

Posted by Jerry Stuckle on 10/13/07 13:25

Summercool wrote:
> On Oct 13, 5:29 am, Michael Fesser <neti...@gmx.de> wrote:
>
>> Actually this is a pretty simple task, in fact the PHP code for a single
>> input field could be reduced to a single line if necessary. So I'm quite
>> curious how it's done in your books.
>
> <form action="self.php" method="get">
> <input name="val" type="text" value="<?= $_GET["val"] ?>">
> <input type="submit" value="Post it">
> </form>
> </div>
>
> usually they do something like this...
>
> GET and POST are just the same...
>
> none of them work for foo "bar" foo
> and foo 'bar' foo
>
>
>
>

Other than the fact they're using short tags, it should work fine.
They're assuming short tags are on, and your server probably has them
off. It doesn't mean they are wrong - just that the configuration on
your server doesn't match what the book assumes.

Change

<input name="val" type="text" value="<?= $_GET["val"] ?>">

to:

<input name="val" type="text" value="<?php echo $_GET["val"] ?>">

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация