ank Posted March 4 Share Posted March 4 Hi i'am trying to resize a image from a child page who has his own template: on the home page i render all the child pages who have there own php template: foreach($page->children() as $section){ echo $section->render(); }; On the child page the php contains: $image = $page->image; $thumb = $image->size(300, 150); echo <img src='$thumb->url'>; the $thumb is not generated and i get a error: "Look out… Fatal Error: Uncaught Error: Call to a member function size() on null in site/templates/welcome.php:23" "welcome.php" is a child template. when i use : echo <img src='$page->image->url'>; it display the image. Link to comment Share on other sites More sharing options...
ank Posted March 4 Author Share Posted March 4 Solved, It was the image itself, with another image everything works well. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now