+ 1

PHP help

Hi, Please, When we work with PHP using many blocks in a page for example. How can i transmit a variable from a block to another Example : <?php // I am using here for example the $data variable ? > <!--some HTML code--> <?php //OK right there, I want using that $data variable on the first block ? > Thank you.

8th Sep 2018, 4:30 PM
Med Arezki
Med Arezki - avatar
2 Answers
+ 1
Just use it, it should work. I have a lot of blocks but never problems regarding the variables. Edit: I just tried it in the playground, also works here <?php $a = 45; ?> <html> some text </html> <?php echo $a; ?>
8th Sep 2018, 4:38 PM
Matthias
Matthias - avatar
+ 1
OK thank you so much, maybe I did an error somewhere.
9th Sep 2018, 2:22 PM
Med Arezki
Med Arezki - avatar