Customizing SMF > SMF Coding Discussion

attachment paths and the message body

(1/1)

BradT:
Hey guys. What I am trying to do is to include certain attachment types into the message body itself. Basically I am trying to embed audio and video attachments into a player in the message body. Right now we are using youtube and soundcloud for this, but I would like to be able to do some of the smaller items on the site.

I have been able to access the attachment arrays and place that data on the message. I've got the player showing up appropriately.  I just can't seem to figure out how to locate the path to the actual attachment so I can load it into the player.

Does anyone know how/where these paths are built? Is there some resource I have overlooked that will explain more about how attachments are handled?

BradT:
Found it. It was right there in my face. I didn't realize that the href property in the array returned the actual file since it didn't appear to be a direct link.

Navigation

[0] Message Index

Go to full version