I am working with CFv5 and am more than satisfied. Now I used a train ride (without wifi) of eight hours to study CFv6 and its tutorial and exmperimenting a bit locally – but I didn't even manage to show data read out from a database! I am irritated: have I become complete ignorant or is the tutorial not tutoring? :-;
The tutorial says if I don't know how the variable looks like, put {var.pr:read_data1} into a custom field. The result shown in preview is: {var.pr:read_data1}.
I tried ordinary php and asked
But the debugger says there are data:
I need to process those data before I present the results in "Display Section". So I need to know eg. how to reach [gdat].
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
On page 21 you use "Content" as model name. A really bad choice of name. When I was searching for "php syntax" I was shown page 26 with some explanation containing "content" which I misunderstood as some necessary function – without knowing the preconditions of page 21. I suggest you use for customizing examples in tutorials sth. like "mymodelname".
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks for your assistance!
The tutorial says if I don't know how the variable looks like, put {var.pr:read_data1} into a custom field. The result shown in preview is: {var.pr:read_data1}.
I tried ordinary php and asked
echo var_dump($this->data['read_data1']);
. What I got was: NULL.
But the debugger says there are data:
Array
(
[read_data1] => Array
(
[log] => Array
(
[0] => SELECT `jubi`.`id` AS `jubi.id`, `jubi`.`name` AS `jubi.name`, `jubi`.`gdat` AS `jubi.gdat` FROM `gk16_filialfinder_stores` AS `jubi` WHERE `jubi`.`gdat` > '0';
)
[var] => Array
(
[0] => Array
(
[jubi] => Array
(
[id] => 1
[name] => Weggefährten
[gdat] => 08.10.1954
)
I need to process those data before I present the results in "Display Section". So I need to know eg. how to reach [gdat].
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
On page 21 you use "Content" as model name. A really bad choice of name. When I was searching for "php syntax" I was shown page 26 with some explanation containing "content" which I misunderstood as some necessary function – without knowing the preconditions of page 21. I suggest you use for customizing examples in tutorials sth. like "mymodelname".
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks for your assistance!