Atis Wiki Code

I was looking at the code for wiki and noticed line 85 in FormatWiki?.pm:

$_ =~ s/\\.*\n/ /g;

From what I gather, this line takes everything from the backslash to newline and replaces it with a space. This is not something that I want to happen, because sometimes I want to display backslashes! I've looked at the rest of the code, but I can't determine if commenting out this line would break something else.

Does anyone know what purpose this like serves? And if it's safe to remove it? Thanks!


From AtisWiki:

Try using the following replacement:

    $_ =~ s/\\[ \t]*\n/ /g; 

...which will only substitute the backslash if it is at the end of a line.

You could just remove that line. The only thing it would affect are the single-line formatting rules like lists. Some browsers don't handle really long lines very well, so if you have a long list-item you might want to break it onto multiple lines. The backslash-code above allows one to use multiple lines, which are combined into one line before the list-item formatting is applied.

Here's an example:

(edit this page to see the backslashes)

If you have further questions about AtisWiki, you might want to contact the author of the program. (If you can't contact the author, you might want to consider using a wiki with more support.)


EditText of this page (last edited April 17, 2003) or FindPage with title or text search