Reply to Embed lots of html code in php & construc objects in php

Your name:

Reply:


Posted by Ming on 05/17/07 06:24

Hi folks,

I have a php file, it contains just a few php codes. The php codes I
need to use is to construct an object, and use it several times, from
html head until the last line of html code.

I know I can construct the same object (I am using php5) several
times, something like $object = new $class, and use several <?php
$object->functionX ?> ... <?php $object->functionZ ?> to include
php code in html code.

However, to construct this object I have to call a remote server, and
rely on its response, which is a bit slow. To construct it several
times takes even more time, and I do not like that.

So my questions are :

1) How can I embed a big chunk of html code in php without using
something like echo "<a href=\"aaa.html\">" all the time

2) Can I just construct an object one time and use it in different <?
php ... ?> blocks?

Thanks,

[Back to original 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

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