PEAK XOOPS - Re: Speed up your XOOPS site:-) in englishin japanese

Re: Speed up your XOOPS site:-)

Target News
Subject お手軽高速化!:-) updated
Summary リダイレクトメッセージは、時間がかかって邪魔だと思いませんか?実際、あのリダイレクトメッセージは、無駄なサーバ負荷にもなっています。とうわけで、okuhikiさんの書込をヒントに、メッセージをじっくり読みたい人にも、さくさく作業したい人にも最善と思われるHack...

List posts in the topic

normal Re: Speed up your XOOPS site:-)

msg# 1
depth:
0
Previous post - Next post | Parent - No child | Posted on 2005/10/23 0:01 | Last modified
Mithrandir  二等兵   Posts: 4
Instead of
<{php}>
if( ! empty( $_SESSION['redirect_message'] ) ) {
	if( empty( $this->_tpl_vars['xoops_lblocks'] ) ) $this->_tpl_vars['xoops_lblocks'] = array() ;
	array_unshift( $this->_tpl_vars['xoops_lblocks'] , array( 'title' => 'Message' , 'content' => $_SESSION['redirect_message'] , 'weight' => 0 ) ) ;
	$this->_tpl_vars['xoops_showlblock'] = 1 ;
	unset( $_SESSION['redirect_message'] ) ;
}
<{/php}>
I would suggest simply using the smarty stuff directly - and position the message in its own div or something (matter of taste, I guess)

<{if $smarty.session.redirect_message != ""}>
    <div class="message"><{$smarty.session.redirect_message}></div>
<{/if}>
In the left block, I find that it hides too much.

edit: OK, this will take a little more as the redirect_message is never removed from the session variables.
Fair 'nuff, carry on
Votes:1 Average:10.00

Posts tree

  Advanced search


Login
Username or e-mail:

Password:

Remember Me

Lost Password?

Register now!