Re: Re: newbie question - php parsing
| From: | Martin Scotta | Date: | Wed, 22 Jul 2009 21:46:06 +0000 |
| Subject: | Re: Re: newbie question - php parsing | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-295717@lists.php.net to get a copy of this message | ||
This is how I'd write this snippet
<?php
if ( 'Home' !== ( $title = the_title('','',FALSE)))
{
echo '<h2 class="entry-header">',
$title,
'</h2>';
}
?>
On Wed, Jul 22, 2009 at 6:31 PM, Lenin <lenin@phpxperts.net> wrote:
> Ted Turner
> <http://www.brainyquote.com/quotes/authors/t/ted_turner.html>
> -
> "Sports is like a war without the killing."
>
> 2009/7/23 Shane Hill <shanehill00@gmail.com>
>
> > 2009/7/22 João Cândido de Souza Neto <joao@consultorweb.cnt.br>
> >
> > > You made a mistake in your code:
> > >
> > > <?php the_title(); ?>
> > >
> > > must be:
> > >
> > > <?php echo the_title(); ?>
> >
> >
> > <?= the_title(); ?>
>
>
> Short tag and not recommended as its deprecated now, would be void at PHP
> 6.0
>
--
Martin Scotta