0

Read TML, not HTML.(we are talking about a marco file format)

TML

A client of us had a system build in TML. It has pretty similarities with HTML (it works the same at least) but it use variables and loops in a different way. Now my question is pretty simple, is it possible to use PHP in combination with this? And if so, does somebody know how to apply them (do I need to create a separate file where I declare my variables)?

I couldn't find any real references online about this.

Nisse Engström
  • 4,738
  • 23
  • 27
  • 42
Dorvalla
  • 5,027
  • 4
  • 28
  • 45
  • 1
    did you try and if yes what was the problem ?? – M A SIDDIQUI Jan 16 '17 at 13:08
  • I cant yet, since its a closed system still, i am trying to make an educated guess here on how much work it requires, i am wondering if there is somebody who was experience with this. That is my whole question. – Dorvalla Jan 16 '17 at 13:10
  • I can't seem to find any documentation on the TML you are talking about online. Is it a server side language? Does it have to be compiled before deployment? Based on your description it doesn't seem to be a static file that can simply be served. – Terry Jan 16 '17 at 13:12
  • I searched for tml and there are different result and the link you have given contains nothing.. Can you tell full form of TML – M A SIDDIQUI Jan 16 '17 at 13:12

1 Answers1

4

PHP can output any kind of data you want, it is not limited to outputting HTML.

TML (assuming you are talking about this TML) is a language for embedding various programming languages in a template.

So you could write PHP that would output Perl embedded in TML which would output HTML. (I've worked on systems that used Perl Mason to generate PHP to generate JavaScript to generate HTML … which were horrible).

The challenge would be (assuming you wanted that) to get the webserver to push the output of the PHP program through the TML engine.

The problem would be that this is wildly inefficient as you are adding two different layers of Template + Server Side Programming instead of just using one.

If you're going to work on a system written using TML, then you should continue to use TML. PHP won't give you any capabilities that TML doesn't already offer you. The only advantage is that (presumably) you already know how to write PHP … but that won't help you much when you need to understand existing TML code.

Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335
  • First of, thanks for your answer. I ll mark it as accepted, cause this is as close to an awnser as I think I get. The link indeed provides the output for TML I kind of see, so we are talking about the same kind of file. Sadly I was affraid of that already that maybe TML and PHP wont play ball together in one page, so I think i have to ideally need to work arround it. The true problem are SOAP calls i need to create instead of plain database work, thus I came to PHP, since that is a language I know to work with. – Dorvalla Jan 16 '17 at 13:19