Hardcoding Advertisement Block into Page Type
Permalink Browser Info Environment
Hi there, I've actually got what I think should work (have had success embedding blocks before) but it isn't displaying anything. Maybe I'm missing something in my code.
Any pointers?
$bt_ads = BlockType::getByHandle('advertisement'); $bt_ads->controller->existing_source = 'group'; $bt_ads->controller->existing_agID = '1'; $bt_ads->controller->numAds = '3'; $bt_ads->render('view');
Any pointers?
Type: | Discussion |
---|---|
Status: | New |