#1 March 8, 2019 1:45pm

doon.mok
Member
Registered: May 6, 2015
Posts: 84

File Referece Field Type

Hello,

I am using the File Reference field type in one of my modules and it puts the file id into the database. I am trying to point to that file in a template but only have the id to refer to. What is the best way to get file information such as name? I can create my own function to get it but is there a bigtree function?

There is a getFile function but that refers to cloud storage.

Thanks

Offline

#2 March 8, 2019 1:46pm

timbuckingham
Administrator
From: Baltimore, MD
Registered: April 2, 2012
Posts: 895

Re: File Referece Field Type

You can use the BigTreeCMS::getResource call to grab that file's information:
https://www.bigtreecms.org/developers/c … etResource

Offline

#3 March 8, 2019 1:59pm

doon.mok
Member
Registered: May 6, 2015
Posts: 84

Re: File Referece Field Type

Great, thanks Tim!

Offline

Board footer

Powered by FluxBB

The Discussion Forum is not available on displays of this size.