51
sato-san
Re: system_block_comments.html change
  • 2007/6/18 11:46

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


Hi Giba,

The project is not yet completely finished. @Alfred builds still blocks for the footer area in simple XOOPS (as with XOOPS 2.0.16). Preview gives it here:
http://scrumeducations.sprint-it.com

Clones of a block is very simple. For example - Provide from a comment block:
Edit your /modules/system/xoops_version.php

copy the line (164-170 ???)
Quote:

$modversion['blocks'][10]['file'] = "system_blocks.php";
$modversion['blocks'][10]['name'] = _MI_SYSTEM_BNAME11;
$modversion['blocks'][10]['description'] = "Shows most recent comments";
$modversion['blocks'][10]['show_func'] = "b_system_comments_show";
$modversion['blocks'][10]['options'] = "10";
$modversion['blocks'][10]['edit_func'] = "b_system_comments_edit";
$modversion['blocks'][10]['template'] = 'system_block_comments.html';


search the latest blocknumber (ex. 13)
add the same with new blocknumber and rename the blockname: ex.
Quote:

$modversion['blocks'][14]['file'] = "system_blocks.php";
$modversion['blocks'][14]['name'] = _MI_SYSTEM_BNAME11;
$modversion['blocks'][14]['description'] = "Shows most recent comments";
$modversion['blocks'][14]['show_func'] = "b_system_comments_show";
$modversion['blocks'][14]['options'] = "10";
$modversion['blocks'][14]['edit_func'] = "b_system_comments_edit";
$modversion['blocks'][14]['template'] = 'system_block_comments_block_number_two.html';

add a new template with the new blockname: system_block_comments_block_number_two.html

copy this files via FTP and update the system modul, now you have a new template. If you have a klon of you template, then you can change the code of from the block system_block_comments_block_number_two

Very Easy.


And in this block im have now more extensions to show in this block. (Thanks to Rodrigo!)
Edit the modules/system/block/system_blocks.php and change the "function b_system_comments_show" to:

Quote:

.
.
.
foreach (array_keys($comments) as $i) {
$mid = $comments[$i]->getVar('com_modid');
$com['module'] = '<a href="'.XOOPS_URL.'/modules/'.$modules[$mid]->getVar('dirname').'/">'.$modules[$mid]->getVar('name').'</a>';
if (!isset($comment_config[$mid])) {
$comment_config[$mid] = $modules[$mid]->getInfo('comments');
}
$com['id'] = $i;
$com['title'] = '<a href="'.XOOPS_URL.'/modules/'.$modules[$mid]->getVar('dirname').'/'.$comment_config[$mid]['pageName'].'?'.$comment_config[$mid]['itemName'].'='.$comments[$i]->getVar('com_itemid').'&com_id='.$i.'&com_rootid='.$comments[$i]->getVar('com_rootid').'&'.htmlspecialchars($comments[$i]->getVar('com_exparams')).'#comment'.$i.'">'.$comments[$i]->getVar('com_title').'</a>';
$com['text'] = $comments[$i]->getVar('com_text');
$com['icon'] = htmlspecialchars( $comments[$i]->getVar('com_icon'), ENT_QUOTES );
$com['icon'] = ($com['icon'] != '') ? "subject/".$com['icon'] : 'subject/icon1.gif';
$com['time'] = formatTimestamp($comments[$i]->getVar('com_created'),'m');
$com['link'] = '<a href="'.XOOPS_URL.'/modules/'.$modules[$mid]->getVar('dirname').'/'.$comment_config[$mid]['pageName'].'?'.$comment_config[$mid]['itemName'].'='.$comments[$i]->getVar('com_itemid').'">[de]Mehr[/de][en]More[/en]...</a>';
if ($comments[$i]->getVar('com_uid') > 0) {
$com['poster'] = array();
$poster =& $member_handler->getUser($comments[$i]->getVar('com_uid'));
if (is_object($poster)) {
$com['poster']['link'] = '<a href="'.XOOPS_URL.'/userinfo.php?uid='.$comments[$i]->getVar('com_uid').'">'.$poster->getVar('uname').'</a>';
$com['poster']['id'] = $comments[$i]->getVar('com_uid');
$com['poster']['uname'] = $poster->getVar('uname');
$com['poster']['avatar'] = '<img src="'.XOOPS_URL.'/uploads/'.$poster->getVar('user_avatar').'">';
} else {
$com['poster']['link'] = $GLOBALS['xoopsConfig']['anonymous'];
}
} else {
$com['poster']['link'] = $GLOBALS['xoopsConfig']['anonymous'];
}
$block['comments'][] =& $com;
unset($com);
}
.
.
.


Now you can add in your templtes:
< {$comment.poster.link}>
< {$comment.poster.uid}>
< {$comment.poster.uname}>
< {$comment.poster.avatar}>
< {$comment.text}>
< {$comment.link}>





52
sato-san
Re: system_block_comments.html change
  • 2007/6/18 9:10

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


BIG THANKS for helping! Now works great. I which important in addition learned.



53
sato-san
Re: system_block_comments.html change
  • 2007/6/14 12:41

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


Very well, I changed it for XOOPS 2,2 and functioned. Can you extend that for a further function? I need still another link (URL) for the comment.

ex.
< {$comment.link}>

And im would linke a Klon from this Block however with another layout. Is also possible?



Thank you !!!



54
sato-san
Re: system_block_comments.html change
  • 2007/6/13 16:52

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


Thanks for your fast assistance. I use the XOOPS 2.2.x for this project however I your information to use will be able. Thanks.



55
sato-san
system_block_comments.html change
  • 2007/6/13 12:08

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


Hello,

I would like to change my templetes of "system_block_comments.html". I would like to indicate also the Comment-text and also the picture of the user.

That is my source:
Quote:

<table width="100%" cellspacing="0" class="outer">
<{foreach item=comment from=$block.comments}>
<tr class="<{cycle values="even,odd"}>">
<td><{if $comment.poster.id != 0}><img src="<{$xoops_upload_url}>/<{$comment.poster.avatar}>" width="55" height="63" /><{/if}></td>
<td><{$comment.title}><br><{$comment.text}><br><{$comment.text}><br><{$comment.poster.uname}></td>
</tr>
<tr>
<td colspan="2"> </td>
</tr>
<{/foreach}>
</table>


Im can see only the "<{$comment.title}>".
Why?



56
sato-san
Re: [XoopsTeam] progress - Communications Team - June 10th
  • 2007/6/13 7:30

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


Quote:

tom wrote:
My suggestions, based on my experience with them:

wtravel
Skenow
MadFish
jensclas
sato-san
JAVesey

Anyone else up for some hard work

The tasks list is also not a conclusive one, and suggestions are to be made.


I would like to stand and help for you gladly at your side along. Became conscious to me only now, which is it a very important task.



57
sato-san
Re: [XoopsTeam] progress - design - June 10th
  • 2007/6/10 11:37

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


If someone would ask me: I wish myself also Kris_fr as a leader.



58
sato-san
[XoopsTeam] sato-san - Dokumentation / Design / Beta-Tester - Member
  • 2007/6/8 5:34

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


I work with XOOPS since 2003. In the last months I provided the following projects:
www.conga-award.de
www.propolitik.de
www.scrummotions.com
www.xoops-magazine.com
www.fight-events.de
(in the next time):
http://scrumeducations.sprint-it.com

Resized Image

I have many useful ideas for XOOPS, which one could discuss. XOOPS prepares very much fun for me. I try gladly new modules and translate gladly these modules. At present I write a XOOPS book in German language. XOOPS is important for my job. I support the German Community as moderator and BETA-tester by simple-xoops.



59
sato-san
Re: [ANNOUNCE] Xoops-France open the support to the Xoops-Cube Project
  • 2007/6/6 20:49

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


@Skalpa returns certainly not more. I gave hope up.



60
sato-san
Re: Captcha in Liaise will not show up
  • 2007/6/4 10:22

  • sato-san

  • Quite a regular

  • Posts: 224

  • Since: 2005/7/1 1


I am not the developer of this module. As long as that lives XOOPS-magazines, you can seize on the Download back. I transferred the module also to the German Community (Download-Center).




TopTop
« 1 ... 3 4 5 (6) 7 8 9 ... 11 »



Login

Who's Online

176 user(s) are online (134 user(s) are browsing Support Forums)


Members: 0


Guests: 176


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits