DMXzone Database Connector PHP Support Product Page
use data from one field in a string inside php tag
Asked 12 Dec 2013 18:47:34
1
has this question
12 Dec 2013 18:47:34 Hans Haverlach posted:
Hi,On a page with dynamic data I've this php script where I build a variable like this:
<?php
$grpath = "../../filemanager/uploaded/{{yearmap.data[0].yearmap_name}}/group1/";
?>
From the bindingspanel I have a datasource from a database. I selected yearmap_name and inserted it in the string. It asked for data repeation, but I don't want data-repeation so I chose Cancel.
The {{yearmap.data[0].yearmap_name}} is not rendered as data when I view the page in the browser.
Now I'm at a loss. How do I just insert the data of one field in a string?
Please advice!
Replies
Replied 12 Dec 2013 21:06:17
12 Dec 2013 21:06:17 George Petrov replied:
Hi Hans,
The HTML5 Data Bindings are rendered in the browser client side, while any PHP code is rendered first server side and then send to the browsers.
So you can't mix those are those are two very different things.
Greetings,
George
The HTML5 Data Bindings are rendered in the browser client side, while any PHP code is rendered first server side and then send to the browsers.
So you can't mix those are those are two very different things.
Greetings,
George