[Solved] How to suggest another category?

 
Post new topic   Reply to topic   printer-friendly view    b2evolution Forum Index -> Feature requests and Feedback
View previous topic :: View next topic  
Author Message
Afwas
Forum helper

Joined: 03 Jan 2007
Posts: 3559
Reputation: 28.7Reputation: 28.7Reputation: 28.7 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 63

PostPosted: Fri Jan 16, 2009 14:14    Post subject: [Solved] How to suggest another category? Reply with quote

My b2evolution Version: Not Entered

In my blog the standard category is not the one I want. How can I default to another one?

Thanks

_________________

Join us at irc://irc.freenode.net#B2evolution
More B2evo goodies at http://www.blog.hemminga.net


Last edited by Afwas on Sat Jan 17, 2009 12:44; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
sam2kb
da ruski mafia

Joined: 02 Dec 2007
Posts: 2927
Reputation: 162.4Reputation: 162.4 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 53

PostPosted: Fri Jan 16, 2009 16:11    Post subject: Reply with quote

If I understand you right here's what you need.
Edit the following in admin.php

PHP:
/*
 * Asynchronous processing options that may be required on any page
 */
require_once $inc_path.'_async.inc.php';

if( 
param'post_category''integer' ) == NULL set_param'post_category');
if( 
param'post_extracats''array' ) == NULL set_param'post_extracats', array(2,4,7) ); 


I tested it for a couple minutes so don't rely on it Wink

_________________
Russian b2evolution | Download
Back to top
View user's profile Send private message Visit poster's website
Afwas
Forum helper

Joined: 03 Jan 2007
Posts: 3559
Reputation: 28.7Reputation: 28.7Reputation: 28.7 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 63

PostPosted: Fri Jan 16, 2009 16:38    Post subject: Reply with quote

Great sam2kb,

The first line does what I want. It feels a bit trick though. For a second blog in the same install I might not want to default to #15 and #15 may not even exist in that blog.

Thanks anyway. If I find anything suspicious I'll report back to this topic.

--F

_________________

Join us at irc://irc.freenode.net#B2evolution
More B2evo goodies at http://www.blog.hemminga.net
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
sam2kb
da ruski mafia

Joined: 02 Dec 2007
Posts: 2927
Reputation: 162.4Reputation: 162.4 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 53

PostPosted: Fri Jan 16, 2009 16:51    Post subject: Reply with quote

I moved it to the Feature requests, it would be great if the last selected category get saved in user settings.
_________________
Russian b2evolution | Download
Back to top
View user's profile Send private message Visit poster's website
Afwas
Forum helper

Joined: 03 Jan 2007
Posts: 3559
Reputation: 28.7Reputation: 28.7Reputation: 28.7 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 63

PostPosted: Fri Jan 16, 2009 16:59    Post subject: Reply with quote

sam2kb wrote:
[... I]t would be great if the last selected category get saved in user settings.

I was looking at just that Wink
To be saved in BlogCache I suppose and make that Category (int) plus SubCats (array)

--F

_________________

Join us at irc://irc.freenode.net#B2evolution
More B2evo goodies at http://www.blog.hemminga.net
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
Afwas
Forum helper

Joined: 03 Jan 2007
Posts: 3559
Reputation: 28.7Reputation: 28.7Reputation: 28.7 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 63

PostPosted: Sat Jan 17, 2009 12:55    Post subject: Reply with quote

¥åßßå and I (read: ¥åßßå) wrote a plugin that solves this issue. See [plugin] Remember Categories plugin
_________________

Join us at irc://irc.freenode.net#B2evolution
More B2evo goodies at http://www.blog.hemminga.net
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
fplanque
Core Developer
Core Developer

Joined: 13 Jun 2003
Posts: 863
Reputation: 193.4Reputation: 193.4 add or subtract from this member's reputationadd or subtract from this member's reputation
votes: 9

PostPosted: Wed Jan 28, 2009 19:04    Post subject: Reply with quote

You can preset a default category for each blog in b2evolution 3.0.1
_________________
François - Rambling on... State of the Evolution - fplanque.com
b2evolution project maintainer / main developer

Follow b2evolution on twitter and become a fan of b2evolution on facebook
Back to top
View user's profile Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    b2evolution Forum Index -> Feature requests and Feedback All times are GMT - 5 Hours
Page 1 of 1


 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
b2evolution Support Forum RSS Feed Forums powered by php Bulletin Board