Commit info for scoop/lib/Scoop/Admin:

Modified Files:
	EditBoxes.pm 
Log Message:
Bug fix for Box admin form. This would mangle boxes by not handling \|
correctly after a save. This would result in the content of the text
field in the form not matching the actual box content. If you then
saved again, it would save the | as %%, causing scoop to hang the
apache process when the box was run.

For some reason, < and > were getting stripped out of the posted
box data. This would cause a box that referenced < and > in code
to fail, as it would now be looking for < and > instead.

hulver.


Index: EditBoxes.pm
===================================================================
RCS file: /cvs/scoop/scoop/lib/Scoop/Admin/EditBoxes.pm,v
retrieving revision 1.9
retrieving revision 1.10
diff -r1.9 -r1.10
73a74
> 	my $write  = $S->{CGI}->param('write');
93a95,98
> 		if ($write) {
> 			$formData->{admin_boxes_content} =~ s/\|/%%/g;
> 			$formData->{admin_boxes_content} =~ s/\\%%/\|/g;
> 		}
97a103,105
> 			$formData->{admin_boxes_content} =~ s/&amp;/&amp;amp;/g;
> 			$formData->{admin_boxes_content} =~ s/&lt;/&amp;lt;/g;
> 			$formData->{admin_boxes_content} =~ s/&gt;/&amp;gt;/g;
224,225c232,236
< 	$write_cont =~ s/&lt;/</g;
< 	$write_cont =~ s/&gt;/>/g;
---
> 	#$write_cont =~ s/&lt;/</g;
> 	#$write_cont =~ s/&gt;/>/g;
> 	#NO! Don't filter < and >, because the posted data doesn't contain 
> 	#those characters. The posted data is the exact data we WANT, apart
> 	#from the | and %% characters.