phpBB Mood Swings

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in the Customisations Database.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTICE: This forum is only for the announcement of new releases and/or updates of MODs. Any MOD support should be obtained through the Customisations Database in the support area designated for each MOD.

A direct link to support for each MOD is in the first post of the respective topic.
Locked
JasonWade
Registered User
Posts: 287
Joined: Mon Jun 05, 2006 9:22 am

Re: phpBB Mood Swings

Post by JasonWade » Sat May 09, 2009 8:02 am

Xanta Media wrote:
JasonWade wrote:hmm when I go to my profile I now get:

*fixed*?

**Edit: guess more went wrong, when going to a random user's profile I get:

Code: Select all

Fatal error: Cannot redeclare get_user_mood() (previously declared in /home/.tiara/backstreetforums/backstreetforums.com/includes/functions_mood.php:25) in /home/.tiara/backstreetforums/backstreetforums.com/includes/functions_mood.php on line 54
line 54 is:

Code: Select all

}

right after:
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" />' . $row['mood_name'] . '';
	}

	return $mood;
**edit: and when viewing the memberlist I get:

Code: Select all

Fatal error: Cannot redeclare get_user_mood() (previously declared in /home/.tiara/backstreetforums/backstreetforums.com/includes/functions_mood.php:25) in /home/.tiara/backstreetforums/backstreetforums.com/includes/functions_mood.php on line 54
aswell

**(last?) edit:
I also saw that in the admin panel I only see the images, but not the option to turn it on or off or whatever

**edit (again yep ;)): I managed to add a mood to my own profile and when going to a topic it does show fine there, so that's the one part that does seem to have done ok
Did you complerely remove the old Mod before installing this one?
yep removed all that was left in the main files and on this template it wasn't even installed so in the template files there was nothin gfor me to delete

JasonWade
Registered User
Posts: 287
Joined: Mon Jun 05, 2006 9:22 am

Re: phpBB Mood Swings

Post by JasonWade » Sat May 09, 2009 8:16 am

Ok, sorry, seems like I did forgot some things. The memberlist and profile work again, but just 2 questions:

1) Am I supposed to see the mood in the memberlist? Cause I don't...
2) In the acp panel I still only see the images, not the option to turn them off or use txt or anything, is that not in the same place or is something still off there?

cbourne
Registered User
Posts: 109
Joined: Sun May 25, 2008 6:49 am

Re: phpBB Mood Swings

Post by cbourne » Sat May 09, 2009 9:59 am

I have a continuing problem with this mod that I thought i'd uninstalled

In AutoMOD it shows up as being installed 3 times. When I try and uninstall it says that it's been uninstalled but with a load of errors underneath.

--------------------------------------------------------------------------------------------
));
//End: Mood Swing

?>
--------------------------------------------------------------------------------

Replace With
?>The Find specified by the MOD could not be found styles/prosilver/template/memberlist_body.htmlFind
<th class="posts"><a href="{U_SORT_POSTS}#memberlist">{L_POSTS}</a></th>

<!-- IF S_MOOD_MEMBERLIST_ENABLED --><th class="posts">{L_MOOD}</th><!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<th class="posts"><a href="{U_SORT_POSTS}#memberlist">{L_POSTS}</a></th>The Find specified by the MOD could not be found Find
<td colspan="<!-- IF U_SORT_ACTIVE || S_MOOD_MEMBERLIST_ENABLED -->5<!-- ELSE -->4<!-- ENDIF -->">&nbsp;</td>
--------------------------------------------------------------------------------

Replace With
<td colspan="<!-- IF U_SORT_ACTIVE -->5<!-- ELSE -->4<!-- ENDIF -->">&nbsp;</td>The Find specified by the MOD could not be found Find
<th class="posts"><a href="{U_SORT_POSTS}#memberlist">{L_POSTS}</a></th>

<!-- IF S_MOOD_MEMBERLIST_ENABLED --><th class="posts">{L_MOOD}</th><!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<th class="posts"><a href="{U_SORT_POSTS}#memberlist">{L_POSTS}</a></th>The Find specified by the MOD could not be found Find
<td class="posts"><!-- IF memberrow.POSTS --><a href="{memberrow.U_SEARCH_USER}" title="{L_SEARCH_USER_POSTS}">{memberrow.POSTS}</a><!-- ELSE -->{memberrow.POSTS}<!-- ENDIF --></td>

<!-- IF S_MOOD_MEMBERLIST_ENABLED --><td class="posts">{memberrow.USER_MOOD}</td><!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<td class="posts"><!-- IF memberrow.POSTS --><a href="{memberrow.U_SEARCH_USER}" title="{L_SEARCH_USER_POSTS}">{memberrow.POSTS}</a><!-- ELSE -->{memberrow.POSTS}<!-- ENDIF --></td>The Find specified by the MOD could not be found styles/prosilver/template/memberlist_view.htmlFind
<!-- IF LOCATION --><dt>{L_LOCATION}:</dt> <dd>{LOCATION}</dd><!-- ENDIF -->

<!-- IF USER_MOOD --><dt>{L_MOOD}:</dt> <dd>{USER_MOOD}</dd><!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<!-- IF LOCATION --><dt>{L_LOCATION}:</dt> <dd>{LOCATION}</dd><!-- ENDIF -->The Find specified by the MOD could not be found styles/prosilver/template/ucp_profile_profile_info.htmlFind
<dl>
<dt><label for="interests">{L_INTERESTS}:</label></dt>
<dd><textarea name="interests" id="interests" class="inputbox" rows="3" cols="30">{INTERESTS}</textarea></dd>
</dl>

<!-- IF S_MOODS_ENABLED -->
<dl>
<dt><label for="mood"><strong>{L_MOOD}:</strong></label><br /><span>{L_MOOD_EXPLAIN}</span></dt>
<dd>{S_MOOD_OPTIONS}</dd>
</dl>
<!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<dl>
<dt><label for="interests">{L_INTERESTS}:</label></dt>
<dd><textarea name="interests" id="interests" class="inputbox" rows="3" cols="30">{INTERESTS}</textarea></dd>
</dl>The Find specified by the MOD could not be found styles/prosilver/template/viewtopic_body.htmlFind
<!-- IF postrow.POSTER_POSTS != '' --><dd><strong>{L_POSTS}:</strong> {postrow.POSTER_POSTS}</dd><!-- ENDIF -->

<!-- IF postrow.POSTER_MOOD --><dd><strong>{L_MOOD}:</strong> {postrow.POSTER_MOOD}</dd><!-- ENDIF -->
--------------------------------------------------------------------------------

Replace With
<!-- IF postrow.POSTER_POSTS != '' --><dd><strong>{L_POSTS}:</strong> {postrow.POSTER_POSTS}</dd><!-- ENDIF -->The Find specified by the MOD could not be found memberlist.phpFind
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);

//Begin: Mood Swing
include($phpbb_root_path . 'includes/functions_mood.' . $phpEx);
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);The Find specified by the MOD could not be found Find
u.user_posts, u.user_allow_pm
--------------------------------------------------------------------------------

In-Line Find
This MOD has an invalid instruction, or an in-line find operation failed.The Find specified by the MOD could not be found Find
else
{
$group_name = ($row['group_type'] == GROUP_SPECIAL) ? $user->lang['G_' . $row['group_name']] : $row['group_name'];
$u_group = append_sid("{$phpbb_root_path}memberlist.$phpEx", 'mode=group&g=' . $row['group_id']);
}

//Begin: Mood Swing
if ($config['allow_moods'] && !empty($row['user_mood']))
{
$user_mood = get_user_mood($row['user_mood']);
}
else
{
$user_mood = '';
}
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
else
{
$group_name = ($row['group_type'] == GROUP_SPECIAL) ? $user->lang['G_' . $row['group_name']] : $row['group_name'];
$u_group = append_sid("{$phpbb_root_path}memberlist.$phpEx", 'mode=group&g=' . $row['group_id']);
}The Find specified by the MOD could not be found Find
'U_VIEW_PROFILE' => get_username_string('profile', $row['user_id'], $row['username'], $row['user_colour']),

//Begin: Mood Swing
'USER_MOOD' => $user_mood,
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'U_VIEW_PROFILE' => get_username_string('profile', $row['user_id'], $row['username'], $row['user_colour']),The Find specified by the MOD could not be found Find
'S_CHAR_OPTIONS' => $s_char_options,

//Begin: Mood Swing
'S_MOOD_MEMBERLIST_ENABLED' => ($config['mood_view_memberlist']) ? true : false,
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'S_CHAR_OPTIONS' => $s_char_options,The Find specified by the MOD could not be found Find
$age = (int) ($now['year'] - $bday_year - $diff);
}
}

//Begin: Mood Swing
if ($config['allow_moods'] && !empty($data['user_mood']))
{
$user_mood = get_user_mood($data['user_mood']);
}
else
{
$user_mood = '';
}
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
$age = (int) ($now['year'] - $bday_year - $diff);
}
}The Find specified by the MOD could not be found Find
'USER_JABBER_IMG' => ($data['user_jabber']) ? $user->img('icon_contact_jabber', $data['user_jabber']) : '',

//Begin: Mood Swing
'USER_MOOD' => $user_mood,
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'USER_JABBER_IMG' => ($data['user_jabber']) ? $user->img('icon_contact_jabber', $data['user_jabber']) : '',The Find specified by the MOD could not be found viewtopic.phpFind
include($phpbb_root_path . 'includes/bbcode.' . $phpEx);

//Begin: Mood swing
include($phpbb_root_path . 'includes/functions_mood.' . $phpEx);
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
include($phpbb_root_path . 'includes/bbcode.' . $phpEx);The Find specified by the MOD could not be found Find
'age' => '',

//Begin: Mood Swing
'mood' => '',
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'age' => '',The Find specified by the MOD could not be found Find
else
{
$user_cache[$poster_id]['icq_status_img'] = '';
$user_cache[$poster_id]['icq'] = '';
}

//Begin: Mood Swing
if ($config['allow_moods'] && !empty($row['user_mood']))
{
$user_cache[$poster_id]['mood'] = get_user_mood($row['user_mood']);
}
else
{
$user_cache[$poster_id]['mood'] = '';
}
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
else
{
$user_cache[$poster_id]['icq_status_img'] = '';
$user_cache[$poster_id]['icq'] = '';
}The Find specified by the MOD could not be found Find
'POSTER_AGE' => $user_cache[$poster_id]['age'],

//Begin: Mood Swing
'POSTER_MOOD' => $user_cache[$poster_id]['mood'],
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'POSTER_AGE' => $user_cache[$poster_id]['age'],The Find specified by the MOD could not be found

-------------------------------------------------------------------------------------------------------------------------------[/color] //End: Mood Swing
--------------------------------------------------------------------------------

Replace With
include($phpbb_root_path . 'includes/functions_profile_fields.' . $phpEx);The Find specified by the MOD could not be found Find
$data['user_birthday'] = sprintf('%2d-%2d-%4d', $data['bday_day'], $data['bday_month'], $data['bday_year']);
}

//Begin: Mood Swing
if ($config['allow_moods'])
{
$data['mood'] = request_var('mood', $user->data['user_mood']);
}
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
$data['user_birthday'] = sprintf('%2d-%2d-%4d', $data['bday_day'], $data['bday_month'], $data['bday_year']);
}The Find specified by the MOD could not be found Find
//Begin: Mood swing
//Currently set to validate up to 100, if you want more
//moods than 100 change to the amount you want
if ($config['allow_moods'])
{
$validate_array = array_merge($validate_array, array(
'mood' => array('num', true, 0, 100),
));
}
//End: Mood Swing

if ($config['allow_birthdays'])
{
$validate_array = array_merge($validate_array, array(
--------------------------------------------------------------------------------

Replace With
if ($config['allow_birthdays'])
{
$validate_array = array_merge($validate_array, array(The Find specified by the MOD could not be found Find
//Begin: Mood SwingFile edits
adm/style/acp_users_profile.htmlFind
<dd>{L_DAY}: <select id="birthday" name="bday_day">{S_BIRTHDAY_DAY_OPTIONS}</select> {L_MONTH}: <select name="bday_month">{S_BIRTHDAY_MONTH_OPTIONS}</select> {L_YEAR}: <select name="bday_year">{S_BIRTHDAY_YEAR_OPTIONS}</select></dd>
</dl>

<dl>
<dt><label for="mood"><strong>{L_MOOD}:</strong></label><br /><span>{L_MOOD_EXPLAIN}</span></dt>
<dd>{S_MOOD_OPTIONS}</dd>
</dl>
--------------------------------------------------------------------------------

Replace With
<dd>{L_DAY}: <select id="birthday" name="bday_day">{S_BIRTHDAY_DAY_OPTIONS}</select> {L_MONTH}: <select name="bday_month">{S_BIRTHDAY_MONTH_OPTIONS}</select> {L_YEAR}: <select name="bday_year">{S_BIRTHDAY_YEAR_OPTIONS}</select></dd>
</dl>The Find specified by the MOD could not be found includes/acp/acp_board.phpFind
'load_cpf_viewtopic' => array('lang' => 'LOAD_CPF_VIEWTOPIC', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => false),

//Begin: Mood Swings
'legend3' => 'ACP_MOOD_SETTINGS',
'allow_moods' => array('lang' => 'YES_MOODS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'mood_type' => array('lang' => 'MOOD_TYPE', 'validate' => 'int', 'type' => 'select', 'method' => 'mood_type_select', 'explain' => true),
'mood_view_memberlist' => array('lang' => 'MOOD_VIEW_MEMBERLIST', 'validate' => 'int', 'type' => 'radio:yes_no', 'explain' => true),
//End: Mood Swings
--------------------------------------------------------------------------------

Replace With
'load_cpf_viewtopic' => array('lang' => 'LOAD_CPF_VIEWTOPIC', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => false),The Find specified by the MOD could not be found Find
<input type=\"text\" name=\"config[$key]\" id=\"$key\" value=\"$value\" maxlength=\"30\" />";
}

//Begin: Mood Swings
/**
* Select Mood behaviour
*/
function mood_type_select($value, $key = '')
{
global $user;

return '<option value="1"' . (($value == 1) ? ' selected="selected"' : '') . '>' . $user->lang['MOOD_TEXT'] . '</option><option value="2"' . (($value == 2) ? ' selected="selected"' : '') . '>' . $user->lang['MOOD_IMAGE'] . '</option><option value="3"' . (($value == 3) ? ' selected="selected"' : '') . '>' . $user->lang['MOOD_BOTH'] . '</option>';
}
//end: mood Swings
--------------------------------------------------------------------------------

Replace With
<input type=\"text\" name=\"config[$key]\" id=\"$key\" value=\"$value\" maxlength=\"30\" />";
}The Find specified by the MOD could not be found includes/acp/acp_users.phpFind
include($phpbb_root_path . 'includes/functions_profile_fields.' . $phpEx);

//Begin: Mood Swing
include($phpbb_root_path . 'includes/functions_mood.' . $phpEx);
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
include($phpbb_root_path . 'includes/functions_profile_fields.' . $phpEx);The Find specified by the MOD could not be found Find
'bday_year' => 0,

//Begin: Mood swings
'mood' => request_var('mood', $user_row['user_mood']),
//End: mood Swings
--------------------------------------------------------------------------------

Replace With
'bday_year' => 0,The Find specified by the MOD could not be found Find
'user_birthday' => array('date', true),

//Begin: Mood Swings
'mood' => array('num', true, 0, 100),
//End: Mood Swings
--------------------------------------------------------------------------------

Replace With
'user_birthday' => array('date', true),The Find specified by the MOD could not be found Find
'user_birthday' => $data['user_birthday'],

//Begin: Mood Swing
'user_mood' => $data['mood'],
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'user_birthday' => $data['user_birthday'],The Find specified by the MOD could not be found Find
'S_BIRTHDAY_YEAR_OPTIONS' => $s_birthday_year_options,

//Begin: Mood Swing
'S_MOOD_OPTIONS' => list_all_moods($user->data['user_id']),
//End: Mood Swing
--------------------------------------------------------------------------------

Replace With
'S_BIRTHDAY_YEAR_OPTIONS' => $s_birthday_year_options,The Find specified by the MOD could not be found includes/ucp/ucp_profile.phpFind
include($phpbb_root_path . 'includes/functions_profile_fields.' . $phpEx);

//Begin: Mood swing
include($phpbb_root_path . 'includes/functions_mood.' . $phpEx);
if ($config['allow_moods'])
{
$sql_ary['user_mood'] = $data['mood'];
}
//End: Mood Swing

if ($config['allow_birthdays'])
{
$sql_ary['user_birthday'] = $data['user_birthday'];
}
--------------------------------------------------------------------------------

Replace With
if ($config['allow_birthdays'])
{
$sql_ary['user_birthday'] = $data['user_birthday'];
}The Find specified by the MOD could not be found Find
'S_BIRTHDAYS_ENABLED' => true,
));
}

//Begin: Mood Swings
if ($config['allow_moods'])
{
$s_mood_options = list_all_moods($user->data['user_id']);

$template->assign_vars(array(
'S_MOOD_OPTIONS' => $s_mood_options,
'S_MOODS_ENABLED' => true,
));
}
//End: Mood Swings
--------------------------------------------------------------------------------

Replace With
'S_BIRTHDAYS_ENABLED' => true,
));
}The Find specified by the MOD could not be found includes/constants.phpFind
// Additional tables

//Begin: Mood Swings
define('MOODS_DATA_TABLE', $table_prefix . 'moods');
define('USER_MOOD_TEXT', 1);
define('USER_MOOD_IMAGE', 2);
define('USER_MOOD_BOTH', 3);
//End: Mood Swings
--------------------------------------------------------------------------------

Replace With
// Additional tablesThe Find specified by the MOD could not be found language/en/common.phpFind
//Begin: Mood Swing
$lang = array_merge($lang, array(
'MOOD' => 'Mood',
'MOOD_EXPLAIN' => 'How do you feel today?',

------------------------------------------------------------------------------------------------------------------------------

A 'Manage Moods' tab is now showing up in users.

When I open my ftp client I get an error message because it is looking for php_BB_Mood_Swings_1.0.1 which is unavailable and in store/mods I keep seeing an uninstall folder. When I delete that and restart the ftp client another folder appears.

Can anyone help me here. :o

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 1:25 pm

JasonWade wrote:Ok, sorry, seems like I did forgot some things. The memberlist and profile work again, but just 2 questions:

1) Am I supposed to see the mood in the memberlist? Cause I don't...
2) In the acp panel I still only see the images, not the option to turn them off or use txt or anything, is that not in the same place or is something still off there?
The settings is found in a different panel. From the front page of the ACP click "Board Features" on the left and scroll to the bottom. You have the options to turn the mod, choose between image or text and to show in the memberlist (which is off by default.)

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 1:29 pm

cbourne wrote:I have a continuing problem with this mod that I thought i'd uninstalled

In AutoMOD it shows up as being installed 3 times. When I try and uninstall it says that it's been uninstalled but with a load of errors underneath.

.................

A 'Manage Moods' tab is now showing up in users.

When I open my ftp client I get an error message because it is looking for php_BB_Mood_Swings_1.0.1 which is unavailable and in store/mods I keep seeing an uninstall folder. When I delete that and restart the ftp client another folder appears.

Can anyone help me here. :o
It sounds like you have quite a few problems. Can you please PM me a list of Mods that you have installed aswell as the styles that you use. I will set up a default board with those Mods and styles installed and working.

JasonWade
Registered User
Posts: 287
Joined: Mon Jun 05, 2006 9:22 am

Re: phpBB Mood Swings

Post by JasonWade » Sat May 09, 2009 1:46 pm

Xanta Media wrote:
JasonWade wrote:Ok, sorry, seems like I did forgot some things. The memberlist and profile work again, but just 2 questions:

1) Am I supposed to see the mood in the memberlist? Cause I don't...
2) In the acp panel I still only see the images, not the option to turn them off or use txt or anything, is that not in the same place or is something still off there?
The settings is found in a different panel. From the front page of the ACP click "Board Features" on the left and scroll to the bottom. You have the options to turn the mod, choose between image or text and to show in the memberlist (which is off by default.)
Ah I thought I checked there too, guess I missed that one, found it, thanks!

JasonWade
Registered User
Posts: 287
Joined: Mon Jun 05, 2006 9:22 am

Re: phpBB Mood Swings

Post by JasonWade » Sat May 09, 2009 1:51 pm

Sorry I'm beign a pain in the but, but the " and to show in the memberlist (which is off by default.)" memberlist part you mentioned there...
I don't see that with the board features (just the image/text and to enable it or not thing what youy also see in the pic on your demoboard)

Now I'll admit seeing it in the memberlist isn't the most important thing to me, but I hate not knowing what I did wrong ;)

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 2:12 pm

JasonWade wrote:Sorry I'm beign a pain in the but, but the " and to show in the memberlist (which is off by default.)" memberlist part you mentioned there...
I don't see that with the board features (just the image/text and to enable it or not thing what youy also see in the pic on your demoboard)

Now I'll admit seeing it in the memberlist isn't the most important thing to me, but I hate not knowing what I did wrong ;)
Don't Panic, It's not your fault! :) I'm Guessing you have not updated to the latest version yet. It has been submitted to the Mod team and awaiting validation so at the moment it is only avaliable on my site.

You can find the update here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=6 to update look in the contrib folder.

And if you want the preview image in the UCP then that is an addon that you can find here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=15 make sure to update to 1.0.1 before you install the addon.
Last edited by Xanta Media on Sat May 09, 2009 2:13 pm, edited 1 time in total.

Stretcher25
Registered User
Posts: 21
Joined: Thu Apr 30, 2009 11:55 am

Re: phpBB Mood Swings

Post by Stretcher25 » Sat May 09, 2009 2:13 pm

Xanta Media wrote:
Stretcher25 wrote:I'm using version v1.0.1, everything works find except that it does not display in the view topic screen. If I put the original functions_mood.php file back it then displays. That is why it has to be something in that file. Thanks
But how can it be an error in that file when it works fine on the demo and when I install it on a new board?

The only thing I can suggest is that you have a conflict with another mod that you have installed.

Can you send me a PM a list of every Mod that you have installed and I will look for conflicts.

Ok, I fixed the problem that I was having. In the new file functions_mood.php for the add-on mood I changed the following code:

I changed:

Code: Select all

	if ($simple == true)
	{
		$mood = $row['mood_image'];
	}
	else if ($display == USER_MOOD_TEXT)
	{
		$mood = $row['mood_name'];
	}
	else if ($display == USER_MOOD_IMAGE)
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" title="' . $row['mood_name'] . '" />';
	}
	else if ($display == USER_MOOD_BOTH)
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" title="' . $row['mood_name'] . '" />' . $row['mood_name'] . '';
	}

	return $mood;
}

To this:

Code: Select all

	if ($simple == true)
	{
		$mood = $row['mood_image'];
	}
	else if ($display == 2)//2 = Image
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" />';
	}
	else// it's not 1 or 2 so it must be 3 which is both
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" />' . $row['mood_name'] . '';
	}

	return $mood;
}
Now the mood add-on works fine and the mood displays everywhere like it should.

Thanks for the great mod.

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 2:14 pm

Stretcher25 wrote:
Xanta Media wrote:
Stretcher25 wrote:I'm using version v1.0.1, everything works find except that it does not display in the view topic screen. If I put the original functions_mood.php file back it then displays. That is why it has to be something in that file. Thanks
But how can it be an error in that file when it works fine on the demo and when I install it on a new board?

The only thing I can suggest is that you have a conflict with another mod that you have installed.

Can you send me a PM a list of every Mod that you have installed and I will look for conflicts.

Ok, I fixed the problem that I was having. In the new file functions_mood.php for the add-on mood I changed the following code:

I changed:

Code: Select all

	if ($simple == true)
	{
		$mood = $row['mood_image'];
	}
	else if ($display == USER_MOOD_TEXT)
	{
		$mood = $row['mood_name'];
	}
	else if ($display == USER_MOOD_IMAGE)
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" title="' . $row['mood_name'] . '" />';
	}
	else if ($display == USER_MOOD_BOTH)
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" title="' . $row['mood_name'] . '" />' . $row['mood_name'] . '';
	}

	return $mood;
}

To this:

Code: Select all

	if ($simple == true)
	{
		$mood = $row['mood_image'];
	}
	else if ($display == 2)//2 = Image
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" />';
	}
	else// it's not 1 or 2 so it must be 3 which is both
	{
		$mood = '<img src="' . $phpbb_root_path . 'images/moods/' . $row['mood_image'] . '" alt="' . $row['mood_name'] . '" />' . $row['mood_name'] . '';
	}

	return $mood;
}
Now the mood add-on works fine and the mood displays everywhere like it should.

Thanks for the great mod.
If that is the problem you were having then I would say that your problem was that you didn't make the change in constants.php

JasonWade
Registered User
Posts: 287
Joined: Mon Jun 05, 2006 9:22 am

Re: phpBB Mood Swings

Post by JasonWade » Sat May 09, 2009 2:44 pm

Xanta Media wrote:
JasonWade wrote:Sorry I'm beign a pain in the but, but the " and to show in the memberlist (which is off by default.)" memberlist part you mentioned there...
I don't see that with the board features (just the image/text and to enable it or not thing what youy also see in the pic on your demoboard)

Now I'll admit seeing it in the memberlist isn't the most important thing to me, but I hate not knowing what I did wrong ;)
Don't Panic, It's not your fault! :) I'm Guessing you have not updated to the latest version yet. It has been submitted to the Mod team and awaiting validation so at the moment it is only avaliable on my site.

You can find the update here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=6 to update look in the contrib folder.

And if you want the preview image in the UCP then that is an addon that you can find here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=15 make sure to update to 1.0.1 before you install the addon.
thnx. The update files says to ifnd "language/en/mods/acp_moods.php" do you mean "info_acp_moods.php"?

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 2:47 pm

JasonWade wrote:
Xanta Media wrote:
JasonWade wrote:Sorry I'm beign a pain in the but, but the " and to show in the memberlist (which is off by default.)" memberlist part you mentioned there...
I don't see that with the board features (just the image/text and to enable it or not thing what youy also see in the pic on your demoboard)

Now I'll admit seeing it in the memberlist isn't the most important thing to me, but I hate not knowing what I did wrong ;)
Don't Panic, It's not your fault! :) I'm Guessing you have not updated to the latest version yet. It has been submitted to the Mod team and awaiting validation so at the moment it is only avaliable on my site.

You can find the update here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=6 to update look in the contrib folder.

And if you want the preview image in the UCP then that is an addon that you can find here: http://www.xantamedia.co.uk/viewtopic.php?f=5&t=15 make sure to update to 1.0.1 before you install the addon.
thnx. The update files says to ifnd "language/en/mods/acp_moods.php" do you mean "info_acp_moods.php"?
Yes, sorry my mistake :oops:

User avatar
Aurora Primavera
Registered User
Posts: 7
Joined: Sat May 09, 2009 4:45 am

Re: phpBB Mood Swings

Post by Aurora Primavera » Sat May 09, 2009 3:27 pm

Aurora Primavera wrote:Hi there! First off - Really awesome mod! But seeing as it's been forever since I've done anything like this, I'm very rusty. :p

I did okay with everything up until it was time to install. I went through the whole process and then go this message:

Code: Select all

phpBB Mood Swings
PHP Version: 5.2.6
DBMS: MySQL 5.0.67-userstats-log
phpBB3 Version: 3.0.4

Test images inserted.
SQL ERROR Table 'focsforums.MOODS_DATA_TABLE' doesn't exist
What could I have missed?
Um, hi. Just wanted to make sure I got my question answered. I've been playing around with it and redoing things and still get the same error. I'm so confused. :?

Xanta Media
Registered User
Posts: 213
Joined: Sat Dec 27, 2008 4:33 pm

Re: phpBB Mood Swings

Post by Xanta Media » Sat May 09, 2009 3:31 pm

Aurora Primavera wrote:
Aurora Primavera wrote:Hi there! First off - Really awesome mod! But seeing as it's been forever since I've done anything like this, I'm very rusty. :p

I did okay with everything up until it was time to install. I went through the whole process and then go this message:

Code: Select all

phpBB Mood Swings
PHP Version: 5.2.6
DBMS: MySQL 5.0.67-userstats-log
phpBB3 Version: 3.0.4

Test images inserted.
SQL ERROR Table 'focsforums.MOODS_DATA_TABLE' doesn't exist
What could I have missed?
Um, hi. Just wanted to make sure I got my question answered. I've been playing around with it and redoing things and still get the same error. I'm so confused. :?
Sorry I may of missed that one! That error is telling me that you either haven't made the change to includes/constants.php or you have not uploaded it.

User avatar
Aurora Primavera
Registered User
Posts: 7
Joined: Sat May 09, 2009 4:45 am

Re: phpBB Mood Swings

Post by Aurora Primavera » Sat May 09, 2009 3:49 pm

Xanta Media wrote:Sorry I may of missed that one! That error is telling me that you either haven't made the change to includes/constants.php or you have not uploaded it.
Oh goodness, could it really be simple as that? I'll give it a go and let you know. Thank you so much for the quick response. :D

Locked

Return to “[3.0.x] MOD Database Releases”