Project

General

Profile

« Previous | Next » 

Revision 14113

web/username_prefix.php: category comments: added support for a shorter syntax than [x_-_]y@url : x+y@url -> y@url

View differences:

username_prefix.php
16 16
	# the _ are needed to work in Google spreadsheets
17 17
	$path = str_replace('_-_', '', $path);
18 18
	
19
	# remove category comments: x+y@url -> y@url
20
	# this special syntax is shorter than [x_-_]y@url
21
	# a UI can replace + with ' ' to produce a linewrap
22
	# can't use : for this because Firefox will not update the "password" for
23
	#  the website with the new value after the :
24
	$path = preg_replace('^.*?\+', '', $path);
25
	
19 26
	# remove insertion comments: [c]x[d]@url -> x@url
20 27
	# use [] because in writing, [] denotes insertion
21 28
	# insertion indicates that the semantic meaning of the [] portion also
22 29
	#  applies, even though it's not included in the linked term name
23
	# can't use : for this because Firefox will not update the "password" for
24
	#  the website with the new value after the :
25 30
	$path = preg_replace('/\[.*?\]/', '', $path);
26 31
	
27 32
	# remove deletion comments: (-c_-)x@url -> c_x@url

Also available in: Unified diff