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 · 876 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 1998 9 years ago
Archive · by Muut Archive, 9 years ago
2 1341 9 years ago
Archive · by Muut Archive, 9 years ago
2 4547 9 years ago
Archive · by Muut Archive, 9 years ago
1 3401 9 years ago
Archive · by Muut Archive, 9 years ago
3 1491 9 years ago