Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Start new discussion - category select reflects current category

edited March 2006 in Vanilla 1.0 Help
I think that if you are browsing a category while starting a new discussion the selectbox for the category in which the discussion is to be created should reflect that. Boy, that was a confusing sentence. Basically, the category you're browsing should be automatically selected (however it's still changeable) when you create a new discussion.

Comments

  • I could have sworn this already happened. The category ID is even passed to the form; but from the code it seems to just be ignoring it.
  • The problem seems to be in the .htaccess file.

    RewriteRule ^post/category/([0-9]+)/$ post.php [QSA,L] should be changed to RewriteRule ^post/category/([0-9]+)/$ post.php?CategoryID=$1 [QSA,L]
  • Hey, Mark. Pay attention.
  • Simple solution: turn mod-rewrite support off.
  • works on mine (http://collegechat.info) running 0.9.2.
  • Sorry. I guess I should've been clearer.

    *clears throat*
    Mark, in case you haven't noticed, the mod_rewrite rules that you're using in your .htaccess file are not passing the category ID to the post form. This is obviously a silly oversight and should be corrected ASAP.
  • it works for me.
  • I see no problems here.
  • Isn't the ([0-9]+) dealing with the Cat ID?
  • Yeah but it's just redirecting it to post.php and as such it loses it's values.
  • I see what he means.
  • MarkMark Vanilla Staff
    Done!
  • lechlech
    edited March 2006
    I just noticed another issue with this when posting a link to someone else via IM. This appears when linking to something from the discussion list without the trailing slash. For example http://lussumo.com/community/discussion/1898/start-new-discussion-category-select-reflects-current-category will result in a 404 while this next one works : http://lussumo.com/community/discussion/1898/start-new-discussion-category-select-reflects-current-category/ the htaccess file might need a slight tweaking to accomodate for urls like like this. Either to complete it and add the trailing slash, or fall back on to the ID number in the given url and ignore everything after the last slash but not ignoring the anchor point.
This discussion has been closed.