最佳答案
一旦将它们作为数据传递到 Controller 中,在 Blade 模板中,您应该将它们作为对象进行回显:
{{ $images[0]->id }}
{{ $images[0]->host_image->path }}
关于php - 在 Laravel Blade 中访问嵌套对象,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43243846/
最佳答案
一旦将它们作为数据传递到 Controller 中,在 Blade 模板中,您应该将它们作为对象进行回显:
{{ $images[0]->id }}
{{ $images[0]->host_image->path }}
关于php - 在 Laravel Blade 中访问嵌套对象,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43243846/