开发者

PHP Echo function

I'm using a comment script on this page im building. I want for eacht page the comments to say: "Reaction on (each page different name)".

So I found the line what says this but it wont grab on to the echo function. This is the line:

<H3>{$COM_LANG['header']}</H3>

The header is the part of "Reaction on" and I want to echo behind the company name thats different for each page.

I tried:

<H3>{$COM_LANG['header']} $companyname; </H3>

But it w开发者_开发知识库ont work...

EDIT: Sorry if i'm not clear, maby its because i'm dutch and don't know hoe to explaine something in english.

Here a piece of code where this is all about:

<div id="usernotes">
 <div class="head">
 <H3>{$COM_LANG['header']} </H3>
 <br>
 </div>
EOF;

 if ($comments_count) {
  for($i=0; $i<$comments_count; $i++) {
   if ($dont_show_email[$i] != '1' && $email != '') { $author[$i] = "<a href=\"mailto:{$email[$i]}\">{$author[$i]}</a>"; }
   $text[$i] = str_replace(chr(13), '<br />', $text[$i]);

   print<<<EOF
 <div class="note">
  <strong>{$author[$i]}</strong><br />
  <small>{$time[$i]}</small>
  <div class="text">
  {$text[$i]}
  </div>
 </div>

Thanks in advance!


if <H3>{$COM_LANG['header']}</H3> does output what it's supposed to you can try either <H3>{$COM_LANG['header'] . $companyname}</H3> or <H3>{$COM_LANG['header']} . {$companyname}</H3>

Anyway you'd make things easier to everybody showing the PHP code that transforms the above declaration into HTML: is there a template engine, maybe?


The application might be using a templating language. This on looks like Latte. So you might want this:

<H3>{$COM_LANG['header']} {$companyname} </H3>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜