PEAK XOOPS - maybe altsys feature?: blocks admin in user side in englishin japanese

maybe altsys feature?: blocks admin in user side

  • You cannot open a new topic into this forum
  • Guests cannot post into this forum
Previous post - Next post | Parent - Children.1 | Posted on 2006/8/24 1:11
irmtfan  三等軍曹   Posts: 96
i saw this idea in xoops.org forum and apply it in my theme in 2.2.4:

	<{if $xoops_isadmin}>
							     <div class="edit">
							     <a href="<{$xoops_url}>/modules/system/admin.php?fct=blocksadmin&op=edit&id=<{$block.id}>"><img border="0" src="<{$xoops_imageurl}>images/edit.gif" title="<{$smarty.const._MA_NAV_EDITBLOCK}>" alt="<{$smarty.const._MA_NAV_EDITBLOCK}>"  /></a>
							     <a href="<{$xoops_url}>/modules/system/admin.php?fct=blocksadmin&op=delete&id=<{$block.id}>"><img border="0" src="<{$xoops_imageurl}>images/delete.gif" title="<{$smarty.const._MA_NAV_DELETEBLOCK}>" alt="<{$smarty.const._MA_NAV_DELETEBLOCK}>"  /></a>
							     </div>
 					        <{/if}>

so after that admin can edit and delete blocks directly in user side.

questions:
1- it doesnt work in 2.0

2- how to add that in smarty variables like $block.title? is this possible? i think it would be a great feature.

Gijoe do you think it can be done with hack in core files? or apply in Altsys?
Votes:2 Average:5.00
Previous post - Next post | Parent - Children.1 | Posted on 2006/8/24 1:53
GIJOE  先任軍曹   Posts: 4110
Quote:
irmtfan wrote:
Quote:
1- it doesnt work in 2.0
2.0 does not assign block's id.

Quote:
2- how to add that in smarty variables like $block.title? is this possible? i think it would be a great feature.

It is necessary to add some codes into header.php for 2.0.

eg)
            $xoopsTpl->append('xoops_lblocks', array('title' => $block_arr[$i]->getVar('title'), 'id' => $block_arr[$i]->getVar('bid'), 'content' => $bcontent));


Votes:4 Average:5.00
Previous post - Next post | Parent - No child | Posted on 2006/8/24 7:17
irmtfan  三等軍曹   Posts: 96
thank You,
you help me and other xoops members a lot.

also the way to do it for 2.0.14 is a little different and i add it to $block.title smarty variable and not use a new defined smarty.

i send it to xoops.org forum:
http://www.xoops.org/modules/newbb/viewtopic.php?topic_id=52332&start=0#forumpost232606

i know it has not a nice look but it is what i want for themes.
Votes:7 Average:1.43

  Advanced search


Login
Username or e-mail:

Password:

Remember Me

Lost Password?

Register now!