You are here: Re: Selective rendering of part of a page « PHP Programming Language « IT news, forums, messages
Re: Selective rendering of part of a page

Posted by seaside on 12/23/06 13:07

Paul E Collins schrieb:

> I want to skip the rendering of certain parts of a Web page if the
> user doesn't have a certain permission (e.g. a cookie). I'd like to do
> it along these lines:
>
> <p>Anybody can see this paragraph.</p>
> <? start_protected_section($got_permission); ?>
> <p>Not everybody can see this paragraph.</p>
> <? end_protected_section(); ?>

Go and download a template engine like Smarty

http://smarty.php.net/

and separate your code from your layout. I use it for quite some time
and maintainability of code is much better.

 

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

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