forum.coppermine-gallery.net

Support => cpg1.4.x Support => Older/other versions => cpg1.4 modpack by Stramm => Topic started by: zac on September 04, 2006, 03:01:26 am

Title: Template error - Failed to find block 'my_friends'
Post by: zac on September 04, 2006, 03:01:26 am
Hi Stramm, thanks for working so hard on this.  It looks to be a really great modification.. however so far I have only managed to screw up my project.  After installing and running the update I now recieve this message:

Code: [Select]
Template error
Failed to find block 'my_friends'(#(<!-- BEGIN my_friends -->)(.*?)(<!-- END my_friends -->)#s) in :  etc ..... 

I tried to dig through the  beefy 29 page over here:

http://forum.coppermine-gallery.net/index.php?topic=28367.0

but I got lost. 

I am running CPG 1.4.9
Thanks to anyone for any support with this.
Title: Re: Template error - Failed to find block 'my_friends'
Post by: zac on September 04, 2006, 03:10:28 am
As usual.. five minutes after I give up and ask the question... I find the answer:

Quote
Open the theme.php of the theme you want to modify and find the var $template_sys_menu_button. If the theme is using the new layout of the sys menu (you can see that if there are already lines existing like the codeline below) then just add the code below where you want it to appeare (maybe after the home link)

Code:

addbutton($sys_menu_buttons,'{MY_BUDDY_LNK}','','{MY_BUDDY_TGT}','my_friends',$template_sys_menu_spacer);



If the theme's using the old style then add something similar to the following and adapt the html to fit your layout
Code:

<!-- BEGIN my_friends -->
                                                <li class="sidebar_menu"><a href="{MY_BUDDY_TGT}" title="{MY_BUDDY_LNK}" class="navmenu">{MY_BUDDY_LNK}</a></li>
<!-- END my_friends -->




It works and this is indeed an excellent hack.. so many things I have wanted from CPG for sometime now.  THANKS!
Title: Re: Template error - Failed to find block 'my_friends'
Post by: Stramm on September 04, 2006, 07:26:50 am
for the reference... the link http://forum.coppermine-gallery.net/index.php?topic=34905.msg163858#msg163858