NineChime forum

Furry stuff, oekaki stuff, and other stuff.

You are not logged in.

#1 10-15-2008 09:38:31

rainbow
Member

"No mode" issue upon posting a comment or adding picture thumbnails.

Apologies for posting another thread, but I have a more serious problem.

Upon posting a comment after the drawing gets done or when I attempt to make (or delete) picture thumbnails, an error message occurs:

Code:

No mode. Is a server filter being used?

In the functions.php file, I've just looked in the $action == 'add' and $mode=make_thumb Apparently, there might be some sort of error in the SQL query that causing this issue. I believe that if users are unable to post a new comment after finishing the drawing, I'll bet that I'll go through all the hassle of having to recover drawings due to this "No mode" glitch.

Why am I getting this "No mode" error and how can I try to correct this?


Edit: I fixed it. Apparently, there is some sort of design limitation regarding this snippet in the commons.php file:

Code:

function w_toalpha ($in) {
    // Note underscore
    return (preg_replace ("/[^a-zA-Z0-9s_]/", '', $in));
}

When you take out the s_ in the return (preg_replace) variable, it causes some of the features to be break and end up with a "No mode" error.

Last edited by rainbow (10-18-2008 14:15:48)

Offline

#2 10-19-2008 02:31:53

Waccoon
Administrator

Re: "No mode" issue upon posting a comment or adding picture thumbnails.

That's why I told you to make a new function for "strict" alphanumeric filtering.  There are parts of the board, including w_gpc(), that require the w_toalpha() function to be exactly the way it is.

Please keep this in mind.  You can't just modify the functions that already exist.  Doing so will cause problems.  Make new functions to perform the custom functionality you want.

Offline

#3 10-19-2008 06:29:23

rainbow
Member

Re: "No mode" issue upon posting a comment or adding picture thumbnails.

Waccoon wrote:

That's why I told you to make a new function for "strict" alphanumeric filtering.  There are parts of the board, including w_gpc(), that require the w_toalpha() function to be exactly the way it is.

Please keep this in mind.  You can't just modify the functions that already exist.  Doing so will cause problems.  Make new functions to perform the custom functionality you want.

That's what I've fixed now and the oekaki is now enforcing the strict alphanumeric filtering in their username upon registration regardless of having Javascript enabled or not in their browser.

Last edited by rainbow (10-19-2008 06:29:43)

Offline

Board footer

Yep, still running PunBB
© Copyright 2002–2008 PunBB