News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Ignore User

Started by Rudolf, September 12, 2005, 01:00:12 PM

Previous topic - Next topic

J. Williams

Gri,you put to much writing in it
Joshua Jon Williams
Back in Action.

Nitro

#81
ok, i installed this mod, i can see only one buttton below any user next to a topic about 'ignore' but i cannot see where is it in the admin page, you say we can allow or disallow some options but...

am i supposed to do something extra, did i miss it? i cannot see any extra options anywhere.

thanks!

EDIT:
i just tried this mod and it gave me this error:
Unable to load the 'main' template.

any idea why is this? thank you again.
MPF Rocks!!!

Rudolf

First things first:
  are you using 1.1RC? If yes, then read the note, you have to copy the files manually. Very likely they are just empty files.
  When do you get the "Unable to load the main template error"? After you click on what?

The "admin page" is in your Profile -> "Ignore user options". IF you're an administrator under your ignore list there will be a line of text with a checkbox, there you can allow or disallow admin/mod ignoring.
  That's just *one* option.

Rudolf
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

Nitro

yeah, i am using RC1

too much hasle! i am just not in the mood to do this manual, i just opted to unistall.

thanks anyway man.
MPF Rocks!!!

DougD

On a 1.05 forum, in an effort to apply this mod, we receive the following error:

Database Error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'ignore (ID_MEMBER MEDIUMINT( 8 ) UNSIGNED NOT NULL , UNIQUE (ID
File: /home/chevyfan/public_html/cafcna/Packages/temp/Ignoredb.php
Line: 11


This is a highly requested mod, so any help is greatly appreciated!

Rudolf

Most likely it's the version of your MySQL. Thouhg I'm not sure.
Try to execute the following query in phpMyAdmin and see if it gives an error
CREATE TABLE IF NOT EXISTS {$db_prefix}ignore (ID_MEMBER MEDIUMINT( 8 ) UNSIGNED NOT NULL , UNIQUE (ID_MEMBER), ignore_list MEDIUMTEXT)
make sure to replace the {$db_prefix} with your actual prefix.

Nothing else comes in my mind now.
If you're comfortable with sql or phpMyAdmin or coding I can tell you how to do the database modifications manually. It's quite easy.

Rudolf
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

Spamiam

Great mod so far, with one small problem...

Another admin on our board downloaded and installed this via the manager, and it worked fine for the default theme. I just looked at the files so that I could configure it for our other themes, and found that the following files in the archive have been packaged in binary format, not ascii:

Ignore.english.php
Ignore.php
Ignore.template.php
themes.xml

Also the example Display.template.php file in the archive Display.template_EXAMPLE_.zip is packaged in binary.

The rest of the files are as they should be.

Can I get replacements for those in ascii? Thanks!

Rudolf

I'm not sure I understand your issue.
I don't remember exactly how I saved the files, but I think I worked with two different editors at that time.
If you explain to me how to save it in ascii format I will do it.

Rudolf
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

jerm

how about also ignore the persons signature, avatar, and any information written under their nickname?
that way you can fully ignore the person...

Rudolf

That shouldn't be hard to do, and it seems a reasonable request.
I'll try to work on it as soon as possible.

®
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

DougD

Quote from: rudiksz on November 29, 2005, 05:29:01 AM
Most likely it's the version of your MySQL. Thouhg I'm not sure.
Try to execute the following query in phpMyAdmin and see if it gives an error
CREATE TABLE IF NOT EXISTS {$db_prefix}ignore (ID_MEMBER MEDIUMINT( 8 ) UNSIGNED NOT NULL , UNIQUE (ID_MEMBER), ignore_list MEDIUMTEXT)
make sure to replace the {$db_prefix} with your actual prefix.

Nothing else comes in my mind now.
If you're comfortable with sql or phpMyAdmin or coding I can tell you how to do the database modifications manually. It's quite easy.

Rudolf

Same essential result:
#1064 - You have an error in your SQL syntax.  Check the manual that corresponds to your MySQL server version for the right syntax to use near 'ignore (ID_MEMBER MEDIUMINT( 8 ) UNSIGNED NOT NULL , UNIQUE (ID

DougD

SQL-query:
CREATE TABLE `ignore` (
`ID_MEMBER` MEDIUMINT( 8 ) UNSIGNED NOT NULL ,
`ignore_list` MEDIUMTEXT NOT NULL ,
UNIQUE (
`ID_MEMBER`
)
);



Manually did it with phpMyAdmin - that seemed to work.  Now have to test the package.

DougD

Applying the package via package manager still resulted in the same error and no Ignore feature in the standard SMF theme.  I do realize i'll have to alter our theme to use it, but thought I'd see it now in default.

Rudolf

Once you have the table in your database just edit the package-info.xml inside the package by removing the line:
<code>Ignoredb.php</code>

It seems that the problem it's caused by the "IF NOT EXISTS" clause, probably you have an older MySQL version.
Remove the code from the package, and try installing it. IF you don't get any Errors from the source files it should work.

Rudolf
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

jerm

Quote from: rudiksz on December 02, 2005, 06:17:54 AM
That shouldn't be hard to do, and it seems a reasonable request.
I'll try to work on it as soon as possible.

®
cool.. thanks  :)

Rudolf

I upgraded the mod as requested.
It is a simple modification in the template file, no big thing.
To get the new "feature" just uninstall the version you have and then grab the 1.2 version (final, not beta).  Uninstalling the old version you *will not lose* any settings!

Alternatively you can make the changes manually.
The only file changed is the Display.template.php
1.
Search the Javascript function showhide() -somewhere at the beginning of the file.
   and replace it with the following function
function showhide(msgnr)
{  
if (document.getElementById("message"+msgnr).style.display == "")
    {document.getElementById("message"+msgnr).style.display = "none";
     document.getElementById("ignmsgbttns"+msgnr).style.visibility = "hidden";
     document.getElementById("ignoremessage"+msgnr).style.display = "";
     document.getElementById("ignfooter"+msgnr).style.display = "none";
     document.getElementById("showhide"+msgnr).src = "', $settings['images_url'] . '/' . $context['user']['language'] . '/ignshow.gif"' ,';
     document.getElementById("showhide"+msgnr).alt = "', $txt['ignore_show'] ,'";
     document.getElementById("ignprofile"+msgnr).style.display = "none";
    }
    else
    {document.getElementById("message"+msgnr).style.display = "";
     document.getElementById("ignmsgbttns"+msgnr).style.visibility = "visible";
     document.getElementById("ignoremessage"+msgnr).style.display = "none";
     document.getElementById("ignfooter"+msgnr).style.display = "";
     document.getElementById("showhide"+msgnr).src = "', $settings['images_url'] . '/' . $context['user']['language'] . '/ignhide.gif"' ,';
     document.getElementById("showhide"+msgnr).alt = "', $txt['ignore_hide'] ,'";
     document.getElementById("ignprofile"+msgnr).style.display = "";
     }
}

*only two new lines added...

2.
Search the following comment:
// Show the member's custom title, if they have one.
Add before this:
if ($message['is_ignored']==1) echo '<div id="ignprofile' , $message['counter']+1 , '" style="display:none;">'; //IGNORE

3.
Search for:
//IGNORE - START make Ignore/Unignore link in poster_info
Add before:
if ($message['is_ignored']==1) echo '</div>';

And you should be set.
Rudolf
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

darkgear

Nice mod! 

I am running 1.1 B3.  I got this message

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /www/f/flashlightfo/htdocs/Sources/Display.php on line 910


Rudolf

I'm just guessing here, but:
if on the line 910 of your Display.php is this:
'is_ignored' => isIgnored($message['ID_MEMBER'], &$memberContext[$message['ID_MEMBER']]['group_id']), //IGNORE

Then delete the & from there.

That should stop the warning.
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

rgarrison

This script is wonderful.  I love it.

wing

#99
It doesn't seem to install in 1.1 RC2

I had to change 2 things to get it to work in RC2.

I did step 2 and 3 in the first post of this thread.

It seems to work a little different.

Good -
Makes things much smaller it removes everything including avatars
Bad -
The show / hide button never changes to hide, it always says show for some reason the javascript isn't working.

Advertisement: