Tags:
create new tag
, view all tags

Question

I'm running TagMePlugin 20 May 2006 (V1.009). The problem is that tags on topics in a subweb don't seem to be working.

So I've got tags in the WebLeftBar.

MWSnap_2006-09-12,_18_55_03.jpg

If I add a tag to a topic, it looks like it works.

MWSnap_2006-09-12,_18_55_12.jpg

I add another tag, only the new tag shows.

MWSnap_2006-09-12,_18_55_22.jpg

I load the page from the index, and all tags are gone!

MWSnap_2006-09-12,_18_57_50.jpg

I use the Tags display to locate that topic, and it lists only the first tag for that topic.

There is a slightly newer version, but the notes don't list subweb improvements.

I'll upgrade tonight, but I thought to submit the report anyway.


Second part, likely related or I can open a second ticket.

Performing showalltags in a subweb, the web parameter must be specified with the subweb name using a period, or nothing is displayed.

For example:


%TAGME{ tpaction="showalltags" web="My.Subweb" .....

Without the web parameter, its blank.

Environment

TWiki version: TWikiRelease04x00x04
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin, TagMePlugin
Server OS: Linux
Web server: Apache
Perl version: 5.8.8
Client OS: Linux
Web Browser: Firefox 1.5.0.6
Categories: Missing functionality, Plugins

-- RussellAdams - 12 Sep 2006

Answer

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

That is a known bug, see TagMePluginFailsOnSubWebs, and TagMePluginDev, my note on 06 Apr 2006.

-- PeterThoeny - 13 Sep 2006

Your post on 06 Apr 2006 is in TagMePluginDevArchive.

It also said that problem was fixed on 09 May 2006, are you sure this is the same problem?

I also verified I'm running 1.010, turns out the plugin info is wrong or wasn't updated.

The patch you discussed is in my TagMePlugin.pm:


sub writeTagInfo
{
    my( $webTopic, @info ) = @_;
    $webTopic =~ s/\//\./;
    my $file = "$attachDir/_tags_$webTopic.txt";

I show that the tag file is there and intact, its just it won't add more than one tag to a topic and they don't display right.

-- RussellAdams - 14 Sep 2006

Yes, you are right, there is another bug lurking. Let me investigate...

-- PeterThoeny - 14 Sep 2006

OK, here is the fix, indicated in red:

# =========================
sub readTagInfo
{
    my( $webTopic ) = @_;
    $webTopic =~ s/[\/\\]/\./;
    my $text = TWiki::Func::readFile( "$attachDir/_tags_$webTopic.txt" );
    my @info = grep{ /^[0-9]/ } split( /\n/, $text );
    return @info;
}

# =========================
sub writeTagInfo
{
    my( $webTopic, @info ) = @_;
    $webTopic =~ s/[\/\\]/\./;
    my $file = "$attachDir/_tags_$webTopic.txt";
    if( scalar @info ) {
        my $text = "# This file is generated, do not edit\n"
                 . join( "\n", reverse sort @info ) . "\n";
        TWiki::Func::saveFile( $file, $text );
    } elsif( -e $file ) {
        unlink( $file );
    }
}

The second item should be already in the code. I will update the TagMePlugin.

-- PeterThoeny - 14 Sep 2006

I've patched my local copy, I'll begin testing it immediately. Thank you for your help!

-- RussellAdams - 14 Sep 2006

Both problems appear to have been resolved. I'll reopen if I find any additional errors. Thanks for your quick response! Viva la TWiki!

-- RussellAdams - 14 Sep 2006

 
Change status to:
Topic attachments
I Attachment Action Size Date Who Comment
JPEGjpg MWSnap_2006-09-12,_18_55_03.jpg manage 2.4 K 2006-09-12 - 23:02 RussellAdams  
JPEGjpg MWSnap_2006-09-12,_18_55_12.jpg manage 3.5 K 2006-09-12 - 23:03 RussellAdams  
JPEGjpg MWSnap_2006-09-12,_18_55_22.jpg manage 3.8 K 2006-09-12 - 23:03 RussellAdams  
JPEGjpg MWSnap_2006-09-12,_18_57_50.jpg manage 2.3 K 2006-09-12 - 23:03 RussellAdams  
Topic revision: r5 - 2006-09-14 - RussellAdams
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.