Thank Post MOD 0.4.0 + simple hide bbcode problem

Hier kommen die Support Anfragen für phpBB 3.0.x MODs hinein.
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

Your phpBB Version: 3.0.4
Your phpBB Type: Standard phpBB (also called Vanilla (phpBB2) or Olympus (phpBB3))
MODs installed: Yes
Your knowledge: Beginner

What have you done before the problem was there?
I installed Thank Post MOD Version 0.4.0 and simple hide bbcode

What have you already tryed to solve the problem?
I tried to change the file read of simple hide BBCode in viewtopic

Description and Message
HI, I am Italian, and i don't speak German. In my site I installed the mod and Simple Hide BBCode and Thank Post Mod 0.4.0, which was issued by the Italian media to phpbb (http://www.phpbb.it) I have tried in every way to adapt the simple hide BBCode to thanks, but there aren't successful. Someone tell me how could I do?
I have edited the viewtopic.php file with this code:

Code: Alles auswählen

// Check if the topic viewer has posted in a topic
$unhide = false; 
if ($user->data['user_id'] != ANONYMOUS)
{
	$sql = "SELECT user_id, post_id 
		FROM " . THANKS_TABLE . "
		WHERE post_id = $topic_id 
		AND user_id = " . $user->data['user_id']; 

	$result = $db->sql_query($sql);
	$unhide = $db->sql_affectedrows($result) ? true : false;
	$db->sql_freeresult($result);
}

I attached the version released by phpbb.it

Thanks[/i]
Dateianhänge
Thank Post MOD 0.4.0 funzionante.rar
(37.72 KiB) 231-mal heruntergeladen
Thank Post MOD 0.4.0 funzionante.rar
(37.72 KiB) 231-mal heruntergeladen
Zuletzt geändert von s1m0n33 am 11. Jun 2009 11:00, insgesamt 1-mal geändert.
Benutzeravatar
Mahony
Site Admin
Site Admin
Beiträge: 792
Registriert: 3. Dez 2006 22:09
Hat sich bedankt: 22 Mal
Danksagung erhalten: 6 Mal

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von Mahony »

Hello
Look here Thank Mod 4 > HIDE PROBLEM!

best regards Mahony
Diejenigen, die lautstark darüber diskutieren, warum es nicht geht, mögen bitte jene nicht stören, die es gerade tun.
Klug ist, wer nur die Hälfte von dem glaubt, was er hört. Weise ist, wer erkennt, welche Hälfte richtig ist.

Bild
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

I have to follow the instructions in this post?
Thank Post Mod (hide MOD compatible )
Benutzeravatar
Mahony
Site Admin
Site Admin
Beiträge: 792
Registriert: 3. Dez 2006 22:09
Hat sich bedankt: 22 Mal
Danksagung erhalten: 6 Mal

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von Mahony »

Hello
s1m0n33 hat geschrieben:I have to follow the instructions in this post?
Thank Post Mod (hide MOD compatible )
Note: The bug fixes are for the Thank Post Mod (hide MOD compatible ) 0.2.0

The Thank Post Mod (hide MOD compatible ) 0.2.0 and the Thank Post MOD Version 0.4.0 are NOT the same. They are not compatible with each other.

The error must be in the Hide MOD installation. Check again all the changes in the files.
After the installation - clear the cache.

best regards Mahony
Diejenigen, die lautstark darüber diskutieren, warum es nicht geht, mögen bitte jene nicht stören, die es gerade tun.
Klug ist, wer nur die Hälfte von dem glaubt, was er hört. Weise ist, wer erkennt, welche Hälfte richtig ist.

Bild
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

Hello sorry I still do not understand. What am I to do? I have the thanks mod 0.4.0 and simple hide BBCode
Benutzeravatar
Mahony
Site Admin
Site Admin
Beiträge: 792
Registriert: 3. Dez 2006 22:09
Hat sich bedankt: 22 Mal
Danksagung erhalten: 6 Mal

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von Mahony »

Hello
Your "Thank Post MOD 0.4.0" is in order.
To combine the MODS, you have the following in the viewtopic.php paste.

Code: Alles auswählen

// Check if the topic viewer has posted in a topic
$unhide = false;
if ($user->data['user_id'] != ANONYMOUS)
{
   // If moderator or admin, skip reply check, auto unhide
   if ($auth->acl_get('m_', $forum_id))
   {
      $unhide = true;
   }
   else if (already_thanked($post_id, $user->data['user_id']))
   {
      $unhide = true;
   }
   else
   {
   $sql = "SELECT poster_id, topic_id
      FROM " . POSTS_TABLE . "
      WHERE topic_id = $topic_id
      AND poster_id = " . $user->data['user_id'];

   $result = $db->sql_query($sql);
   $unhide = $db->sql_affectedrows($result) ? true : false;
   $db->sql_freeresult($result);
   }
}
The error must be in the Hide MOD installation. Check again all the changes in the files.


best regards Mahony
Diejenigen, die lautstark darüber diskutieren, warum es nicht geht, mögen bitte jene nicht stören, die es gerade tun.
Klug ist, wer nur die Hälfte von dem glaubt, was er hört. Weise ist, wer erkennt, welche Hälfte richtig ist.

Bild
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

Hi,
i check again all the changes in the files of simple hide bbcode. But I was not able to solve the problem, attached the modified files, please, could control them?

thank you very much!
Dateianhänge
Nuova cartella.rar
(82.67 KiB) 217-mal heruntergeladen
Nuova cartella.rar
(82.67 KiB) 217-mal heruntergeladen
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

Help, I am desperate, I do not know what to do
Benutzeravatar
Mahony
Site Admin
Site Admin
Beiträge: 792
Registriert: 3. Dez 2006 22:09
Hat sich bedankt: 22 Mal
Danksagung erhalten: 6 Mal

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von Mahony »

Hello s1m0n33
In your viewtopic.php is an error

Find

Code: Alles auswählen

// Check if the topic viewer has posted in a topic
$unhide = false;
if ($user->data['user_id'] != ANONYMOUS)
{
   $sql = "SELECT user_id, post_id
      FROM " . THANKS_TABLE . "
      WHERE post_id = $topic_id
      AND user_id = " . $user->data['user_id'];

   $result = $db->sql_query($sql);
   $unhide = $db->sql_affectedrows($result) ? true : false;
   $db->sql_freeresult($result);
}
Replace with

Code: Alles auswählen

// Check if the topic viewer has posted in a topic
$unhide = false;
if ($user->data['user_id'] != ANONYMOUS)
{
   // If moderator or admin, skip reply check, auto unhide
   if ($auth->acl_get('m_', $forum_id))
   {
      $unhide = true;
   }
   else if (already_thanked($post_id, $user->data['user_id']))
   {
      $unhide = true;
   }
   else
   {
   $sql = "SELECT poster_id, topic_id
      FROM " . POSTS_TABLE . "
      WHERE topic_id = $topic_id
      AND poster_id = " . $user->data['user_id'];

   $result = $db->sql_query($sql);
   $unhide = $db->sql_affectedrows($result) ? true : false;
   $db->sql_freeresult($result);
   }
}

Open includes/ucp/ucp_pm_compose.php

Find

Code: Alles auswählen

$sql = "SELECT poster_id, topic_id
               FROM " . POSTS_TABLE . "
               WHERE post_id = $msg_id
               AND poster_id = " . $user->data['user_id'];

         $result = $db->sql_query($sql);
         $unhide = $db->sql_affectedrows($result) ? true : false;
         $db->sql_freeresult($result);
Add before

Code: Alles auswählen

// If moderator or admin, skip reply check, auto unhide
      if ($auth->acl_get('m_', $msg_id['forum_id']))
      {
         $unhide = true;
      }
      else
      {
Add after

best regards Mahony
Diejenigen, die lautstark darüber diskutieren, warum es nicht geht, mögen bitte jene nicht stören, die es gerade tun.
Klug ist, wer nur die Hälfte von dem glaubt, was er hört. Weise ist, wer erkennt, welche Hälfte richtig ist.

Bild
s1m0n33
Beiträge: 12
Registriert: 18. Mai 2009 15:47
Hat sich bedankt: 0
Danksagung erhalten: 0

Re: Thank Post MOD 0.4.0 + simple hide bbcode problem

Beitrag von s1m0n33 »

Hello, I made the changes but when I read a topic, I am facing a white page :(
Antworten