Default category when submitting a story?

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 01-23-2008, 03:42 PM
Banned
Pligg Version: 9.9.5
 
Join Date: Oct 2007
Location: Canada
Posts: 784
Can we make the default category when a member submits a story to be nothing.

This would make the member select a category and not always add the story to the first non related default category and in my case it's arts and crafts right now?

I would like it to default to nothing so the members gets prompted to select the appropriate category manually?
Reply With Quote
  #2 (permalink)  
Old 01-23-2008, 05:39 PM
not2serious's Avatar
Pligg Donor
Pligg Version: 1.1.5
Pligg Template: Westie
 
Join Date: Apr 2007
Location: East Coast, USA
Posts: 229
This would be a good idea. Unfortunately, I do not have the ability to make the mod.
Reply With Quote
  #3 (permalink)  
Old 01-24-2008, 10:04 AM
Banned
Pligg Version: 9.9.5
 
Join Date: Oct 2007
Location: Canada
Posts: 784
Can anyone suggest a way for this to be done?
Reply With Quote
  #4 (permalink)  
Old 01-24-2008, 11:14 AM
Banned
Pligg Version: 9.8.
Pligg Template: Custom
 
Join Date: Feb 2007
Location: Canada
Posts: 796
I checked the code that controls this area, and from what I understand it takes the first category listed in the database.

I wasn't able to get it to display a blank no matter what I did.

Still trying though.

Geoserv.
Reply With Quote
  #5 (permalink)  
Old 01-24-2008, 07:23 PM
Constant Pligger/Designer
Pligg Version: 1.0
Pligg Template: silverbullet
 
Join Date: Mar 2007
Posts: 147
Send a message via MSN to skins4webs
9.9 Seems to already have this feature. In submit step 2 it says, please select a category and wont let you submit without doing so.
Reply With Quote
  #6 (permalink)  
Old 01-24-2008, 08:59 PM
Banned
Pligg Version: 9.8.
Pligg Template: Custom
 
Join Date: Feb 2007
Location: Canada
Posts: 796
bbrian I got it working on my site which is version 9.8.2 with changing:

Code:
<label>{#PLIGG_Visual_Submit2_Category#}:</label>{#PLIGG_Visual_Submit2_CatInstruct#}<br/>
		<select name="category"><option value = "Select...">
			{section name=thecat loop=$submit_cat_array}
			   	  {if $submit_cat_array[thecat].spacercount lt $submit_lastspacer}{$submit_cat_array[thecat].spacerdiff|repeat_count:''}{/if}
				  {if $submit_cat_array[thecat].spacercount gt $submit_lastspacer}{/if}
				  {$submit_cat_array[thecat].spacercount|repeat_count:'&nbsp;&nbsp;&nbsp;'}
				  {$submit_cat_array[thecat].name} 
				  &nbsp;&nbsp;&nbsp;       
				  {assign var=submit_lastspacer value=$submit_cat_array[thecat].spacercount}
			  </option>
			{/section}
		</select>
		
		<br/><br/>
to:

Code:
<div><label for="category">{#PLIGG_Visual_Submit2_Category#}:</label><p>{#PLIGG_Visual_Submit2_CatInstruct#}</p>
		<select name="category">
			<option value = "">Select a category
			{section name=thecat loop=$submit_cat_array}
			   <option value = "{$submit_cat_array[thecat].auto_id}">
				  {if $submit_cat_array[thecat].spacercount lt $submit_lastspacer}{$submit_cat_array[thecat].spacerdiff|repeat_count:''}{/if}
				  {if $submit_cat_array[thecat].spacercount gt $submit_lastspacer}{/if}
				  {$submit_cat_array[thecat].spacercount|repeat_count:'&nbsp;&nbsp;&nbsp;'}
				  {$submit_cat_array[thecat].name} 
				  &nbsp;&nbsp;&nbsp;       
				  {assign var=submit_lastspacer value=$submit_cat_array[thecat].spacercount}
			  </option>
			{/section}
		</select>

</div>
I added some styling divs, so just ignore those.

If the submitter doesn't select a category, an error sends them bacvk to fix it. It defaults to "Select a category" but you can remove those words for a blank or change to whatever you want.

Geoserv.
Reply With Quote
  #7 (permalink)  
Old 01-25-2008, 10:19 AM
Banned
Pligg Version: 9.9.5
 
Join Date: Oct 2007
Location: Canada
Posts: 784
Very cool what file are we editing here Geoserv?

Thanks so much for helping me with this!
Reply With Quote
  #8 (permalink)  
Old 01-25-2008, 10:32 AM
graphicsguru's Avatar
Pligg Donor
Pligg Version: 9.9.5
 
Join Date: Aug 2006
Location: USA
Posts: 399
bbrian017 looks like its submit_step_2.tpl
Reply With Quote
  #9 (permalink)  
Old 01-25-2008, 10:53 AM
Banned
Pligg Version: 9.8.
Pligg Template: Custom
 
Join Date: Feb 2007
Location: Canada
Posts: 796
Sorry, yes it is submit_step_2.tpl

Geoserv
Reply With Quote
  #10 (permalink)  
Old 04-01-2008, 04:27 PM
Banned
Pligg Version: 9.9.5
 
Join Date: Oct 2007
Location: Canada
Posts: 784
Sweet ok I will try this tonight!
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Control of meta description - categories Divisive Cotton Questions and Comments 71 03-29-2011 10:03 PM
After Install Pligg 1.0.0 Pligg_Users Table Doesn' t Exist airweb Questions and Comments 2 07-21-2009 03:59 AM
Installation - Tables never created julientarta Questions and Comments 30 03-23-2009 08:41 PM
9.6 error xbizsky Questions and Comments 28 07-04-2007 04:54 AM
Upgrade from 5.10 to 9 bizdiggers Questions and Comments 19 02-11-2007 05:21 AM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development