문제

I've developed a module which allows the user to upload images to a little gallery widget. When they upload the pics through the admin panel then can also assign which page the image appears on. This all works fine and I have a table in database referencing page IDs with image IDs. The bit I'm not sure about is how to pass the page ID to the plugin so it can display the correct images.

What would be the best approach/syntax here? I'm imagining something like this :

{{ gallery:render id=this_page_id }}

where this_page_id would be the unique ID of the page. Can anyone point me in the right direction?

Cheers, Phil

도움이 되었습니까?

해결책

Solution provided via the @PyroCMS Twitter account -

{{ gallery:render id=page:id }}
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top