Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Need to parse a csv and send data to a twig template

Started by Muut Archive 11 years ago · 0 replies · 838 views
11 years ago

As I said in the subject I need to parse a csv inside my theme Theme.php inside root folder of the theme and send all the parsed data to a specific template.

theme_folder
ThemeTemplate.php
templates
template.html.twig(the one I need to send parsed data to)

My Theme.php has the following content:
<?php
namespace Grav\Theme;
use Grav\Common\Theme;

class ThemeTemplate extends Theme
{
////read csv here and send all parsed data to template.html.twig
}
?>

Any suggestions/examples in order to achieve this?

Thank you!

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1692 9 years ago
Archive · by Muut Archive, 9 years ago
2 1135 9 years ago
Archive · by Muut Archive, 9 years ago
2 4298 9 years ago
Archive · by Muut Archive, 9 years ago
1 3183 9 years ago
Archive · by Muut Archive, 9 years ago
3 1293 9 years ago