Jump to content

[SOLVED] Math and heredoc


pkedpker

Recommended Posts

how do I compute math like subtraction in heredoc

 

example..

 

<img height="6" width="{100-$myHP}"/>

 

output is.....

 

<img height="6" width="100-28"/>

 

 

you know I want 72.. I'm making HP bars here and no way I cannot use heredoc as there is soo much HTML here its crazy.

 

but if i do ${100-$myHP}  I get a variable called 72 -.-.. but not value!.. so im stuck.

 

Soo I tried {${100-$myHP}}  and still nothing

Link to comment
https://forums.phpfreaks.com/topic/164883-solved-math-and-heredoc/
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.