Jump to content

[SOLVED] Variable substitution (i.e. <?=$Scompany?>)


cdikland

Recommended Posts

I just started back in php again after a 3-4 year break. Recently installed php v 5.2.4 along with apache v2,2 running under windows XP. Everything seems to run ok except when/where i mix php code such as <?=$varname?> within html. The value associated with $varname is never inserted into the html. Instead what appears is exactly what I placed in the html (i.e. <?=$varname?>  will appear within the html instead of its value).

Here is a snippet of the culprit file

 

<!---

<TR><td>Company  </td><td><INPUT NAME='company' value='<?=$Scompany?>'></td></TR>

<TR><td>Vessel Name  </td><td><INPUT NAME='vessel' value='<?=$Svessel?>'></td></TR>

-->

 

The exact same php file executed under version 4.n of php works fine. ???

 

What am I missing? Is there a switch I need to enable/disable in the v5.n php .ini file??

Link to comment
https://forums.phpfreaks.com/topic/71415-solved-variable-substitution-ie/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.