Scoop -- the swiss army chainsaw of content management
Front Page · Everything · News · Code · Help! · Wishlist · Project · Scoop Sites · Dev Notes · Latest CVS changes · Development Activities
"Post As" hack New Code
By Mystic , Section Code []
Posted on Fri Dec 08, 2000 at 12:00:00 PM PST
To make the scoop UI more usefriendly, I suggest that the "Post as" drop-down not be displayed at all if Anonymous post is not allowed on a scoop system. If this is allowed (as it is now), it looks a bit ridiculous because you have a dropdown box, but nothing to choose from.

The hack that I have coded looks as follows. In the Post.pm file (inside Comments dir), look at lines from 129 . It looks something like:
	$form .= qq|
		<TR>
			<TD align="right">%%norm_font%%Post as:%%norm_font_end%%</TD>
			<TD>%%norm_font%%<SELECT SIZE=1 NAME="uid">
			<OPTION VALUE="$S->{UID}">$self|;
	
       if ($S->{UID} > 0 && $S->have_perm('comment_post', 'Anonymous')) {
		my $select = '';
		if ($uid == -1) {
			$select = 'SELECTED';
		}
			$form .= qq|
			<OPTION VALUE="-1"$select>$anon|;
	}
	
	$form .= qq|
			</SELECT>|; 
I suggest that it be changed to (the commented codes are ones that are no longer used, added lines are shown in strong):
if($S->{UID} > 0 && $S->have_perm('comment_post','Anonymous')) {
	$form .= qq|
		<TR>
			<TD align="right">%%norm_font%%Post as:%%norm_font_end%%</TD>
			<TD>%%norm_font%%<SELECT SIZE=1 NAME="uid">
			<OPTION VALUE="$S->{UID}">$self|;
	
       #if ($S->{UID} > 0 && $S->have_perm('comment_post', 'Anonymous')) {
		my $select = '';
		if ($uid == -1) {
			$select = 'SELECTED';
		}
			$form .= qq|
			<OPTION VALUE="-1"$select>$anon|;
	#}
	
	$form .= qq|
			</SELECT>|; 
}
else {
	$form .=qq|
	<TR>
	<TD>%%norm_font%%|;
				      
}	
< Editing stories in queue | Newer comments and mojo calculation >

Menu
· create account
· faq
· search
· report bugs
· Scoop Administrators Guide
· Scoop Box Exchange

Login
Make a new account
Username:
Password:

Related Links
· Scoop
· More on New Code
· Also by Mystic

Story Views
  23 Scoop users have viewed this story.

Display: Sort:
"Post As" hack | 5 comments (5 topical, 0 hidden)
Hm.. That doesnt seem to work !! (none / 0) (#1)
by Mystic on Fri Dec 08, 2000 at 02:03:08 AM PST

I dont think that the code that I have posted above works properly. Sorry about that. I will try to hack the correct code. Anyone who can hack before me, please post it.

Sorry for hurrying up.



Typo error !!! (none / 0) (#2)
by Mystic on Fri Dec 08, 2000 at 09:14:24 PM PST

Opps.. Now I know why it does not work. I had a typo error in my actual code, but not in the code I have listed down in my story. So it should work fine.

Rusty/hurstdog, interested in commiting it to CVS (please do check for stupid mistakes !)??

(\/)



usacheckcashingstore.com/spring-valley (none / 0) (#3)
by Pervez on Sun Apr 22, 2018 at 11:13:24 AM PST

This is exactly awesome noble page. Now I'm largely delighted by any wonderful succeed. You will use quite very beneficial knowledge. At this time follow-up usacheckcashingstore.com/spring-valley Continue. Keep on weblog.



But why (none / 0) (#4)
by annasander12 on Thu Oct 04, 2018 at 01:11:56 AM PST

I had an Oil Change Elkhart, IN and then saw this. Is it hacked or something?



best bathroom remodeling (none / 0) (#5)
by Pervez on Sun Apr 14, 2019 at 12:01:52 AM PST

You need to do possess an accurate possible regarding generating unique information. We prefer the way you really feel together with the way you are a symbol of your present scenery about this web page. My personal partner as well as in my opinion your present mindset. Presently click best bathroom remodeling Many thanks a great deal, regarding indicating



"Post As" hack | 5 comments (5 topical, 0 hidden)
Display: Sort:

Hosted by ScoopHost.com Powered by Scoop
All trademarks and copyrights on this page are owned by their respective companies. Comments are owned by the Poster. The Rest © 1999 The Management

create account | faq | search