### Normal redirect from path to path ###

RewriteRule ^source/path/?$   /target/path [R=301,L]


### Redirect from query parameters ###

# For every path
RewriteCond %{QUERY_STRING} ^id=1&lang=de&newsid=30&subcat=8$
RewriteRule ^(.*)$   /target/path [R=301,L]

# Only for specific source path (here /index.php)
RewriteCond %{QUERY_STRING} ^lang=de&id=1$
RewriteRule ^index\.php$   /target/path [R=301,L]

# To purge the query parameters, add a ? at the end of the target path.
# The target path from the previous example would then be "/target/path?"


# To strip query parameters from the source in the editor, search-replace with the following regex:
# find: (.*\?(?!\$))(.*)\s/
# replace: $1$ /