Topics Created And Participated In

Started by dougiefresh, October 28, 2016, 11:27:37 AM

Previous topic - Next topic

MULITRI

Sorry to bump but i cannot modify my last reply.

doogiefresh... you did it again!! the error is fixed with your last update, so now your Mod is perfect!!

Thanks to you for your excellent job... Regards.

dougiefresh


BellGab.com

Hi.  This mod appears to be generating the following error:

8: Undefined index: TUPC_user_participatedApply Filter: Only show the errors from this file File: /home/michaelv/public_html/bellgab.com/Sources/Subs-Participation.php

22: 'label' => $txt['TUPC_topics'],
23: 'file' => 'Profile-Participation.php',
24: 'function' => 'TUPC_showTopics',
25: 'subsections' => array(
26: 'created' => array($txt['TUPC_user_created'], array('profile_view_own', 'profile_view_any')),
==>27: 'participated' => array($txt['TUPC_user_participated'], array('profile_view_own', 'profile_view_any')),
28: ),
29: 'permission' => array(
30: 'own' => array('profile_view_own'),
31: 'any' => array('profile_view_any'),
32: ),
33: );
34: }
35: }


Any thoughts?

And, btw, you've built a lot of great mods.  I use several.  Thanks.

dougiefresh

Uploaded v2.5 - July 11th, 2017
o Replaced IFNULL with COALESCE in database queries for better Postgres support.




@BellGab.com:  Whoops!  I missed this bug report.  I'll look into it!

dougiefresh

Uploaded v2.6 - July 17th, 2017
o Language settings moved from Profile.english.php to TUPC.english.php.




@BellGab.com:  Thank you for the bug report!  This issue has been resolved with the version 2.6 update.

landyvlad

What is the update process please?  Is it just upload and install the new one, or do I uninstall./delete the old one first?
(It'd be cool if this info was included in the description of the mod, for easy reference)

Thanks
"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

dougiefresh

Quote from: landyvlad on December 18, 2017, 07:29:45 AM
What is the update process please?  Is it just upload and install the new one, or do I uninstall./delete the old one first?
(It'd be cool if this info was included in the description of the mod, for easy reference)
First, Package Manager won't allow you to install a newer version of a mod while an older version is installed.  If the package supports upgrading, Package Manager will give you the option to upgrade to the new version.  Most of my mods do not support upgrades in that fashion, mostly because some servers have issues with multiple install XML files and aren't smart enough to make it work....

The proper way to upgrade any mod that doesn't give the option through Package Manager is to uninstall the current version of the mod, then install  the new version.  Immediately deleting the old version is not mandatory at any stage of the upgrade process, although if you are happy with the new version, deletion of the old version is recommended.

digger

I think wil be better to skip recycled topics.
Russian lang in attachment.

dougiefresh

Uploaded v2.7 - January 15th, 2018
o Added Russian translation, courtsey of digger!
o Fixed queries so that recycle boards are omitted from database queries.




@digger:  You're right, recycle boards should definitely be omitted from the queries!  I've also included your Russian translation in this version.  Thank you very much for it!

landyvlad

Thanks Dougie that's a good explanation - much appreciated.
Perhaps that could be included in the SMF documentation? (I couldn't find it there).
"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

digger

Quote from: dougiefresh on January 15, 2018, 11:58:15 PM
o Fixed queries so that recycle boards are omitted from database queries.
This doesn't work because you forgot to add $modSettings to the global scope. Below is a patch with a few minor fixes


===================================================================
--- forum/Sources/Profile-Participation.php (date 1516189488867)
+++ forum/Sources/Profile-Participation.php (date 1516189488867)
@@ -14,7 +14,7 @@
********************************************************************************/
function TUPC_showTopics()
{
- global $context, $txt, $scripturl, $modSettings, $smcFunc, $sourcedir, $user_info;
+ global $context, $txt, $scripturl, $modSettings, $sourcedir, $user_info;

// Set up for listing the "important" topics:
loadTemplate('ManageAttachments');
@@ -65,7 +65,7 @@
$user = \'<a href="\' . $scripturl . \'?action=profile;user=\' . $rowData["first_member"] . \'">\' . $rowData[\'first_poster\'] . \'</a>\';
else
$user = $rowData["first_member"];
- return $board . " \\\\ " . $topic . \'<div class="smalltext">\' . $txt["started_by"] . " <strong>" . $user . \'</strong></div>\';
+ return $board . " &#187; " . $topic . \'<div class="smalltext">\' . $txt["started_by"] . " <strong>" . $user . \'</strong></div>\';
'),
),
'sort' => array(
@@ -136,7 +136,8 @@
********************************************************************************/
function TUPC_Created_Count()
{
- global $smcFunc;
+ global $smcFunc, $modSettings;
+
$request = $smcFunc['db_query']('', '
SELECT COUNT(*) AS count
FROM {db_prefix}topics AS t
@@ -156,7 +157,7 @@

function TUPC_Created($start, $items_per_page, $sort)
{
- global $smcFunc;
+ global $smcFunc, $modSettings;

  $request = $smcFunc['db_query']('', '
SELECT
@@ -196,7 +197,7 @@
********************************************************************************/
function TUPC_Participated_Count()
{
- global $smcFunc, $user_info, $context;
+ global $smcFunc, $context, $modSettings;

$request = $smcFunc['db_query']('', '
SELECT DISTINCT id_topic AS id_topic
@@ -220,7 +221,7 @@

function TUPC_Participated($start, $items_per_page, $sort)
{
- global $smcFunc, $user_info, $context;
+ global $smcFunc, $context, $modSettings;

// Is the topic list defined?  If not, then do so before continuing:
if (empty($context['TUPC_topics']))


dougiefresh

Uploaded v2.8 - January 19th, 2018
o Integrated digger's patch, which adds $modSettings as global variable.




@digger:  Thank you for the patch!  It's been integrated into this mod....

shnazzle


nofapturkiye

you are smf hero indeed ,  was looking for something like this

-Rock Lee-

I leave another translation more, anything you tell me :) @dougiefresh


Regards!
¡Regresando como cual Fenix! ~ Bomber Code
Ayudas - Aportes - Tutoriales - Y mucho mas!!!

dougiefresh

Uploaded v2.9 - February 12th, 2018
o Added translators section to the readme.txt file.
o Added Spanish Latin translation, courtsey of Rock Lee.
o Added LICENSE file to the mod, to clarify licensing terms.




@Rock Lee:  Thank you for the translation!  It's been included in this version!

digger

@dougiefresh
Mod doesn't track member id when topics list have more then one page. Urls looks like index.php?action=profile;area=threads;sa=created;sort=lastpost;desc;start=20 without member id in this query. When i go to next page in any profile it redirect to my own profile topics page.

ORIONzitos

PT-BR Translation here! 8) anything you tell me :) @dougiefresh
Total of translations: 10

ORIONzitos

Total of translations: 10

Advertisement: