User Defined Scopes

Generally, there is no difference between user defined or programming language defined scopes - both processed same way.

You are not able to defined you own scopes (collapsing region) everywhere you want - syntax should allow this. Otherwise you will get compiling errors. But there is a trick.

You can place you user defined scope blocks inside of the comment:

test_region.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
 <head>
  <title>Untitled</title>
  <meta name="generator" content="HippoEDIT" />
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 </head>
 <body>
  <?php
  ## region MyArea   
  for ($i = 0; $i < 10; $i++)
  {
  	# some code 
  }
  ## endregion
  ?>
 </body>
</html>

And this looks like this:
User defined regions in PHP

To make it nicer, just create new style (for example called Format Tag) with color different from standard comment and with prefix started with language dependent comment symbol (as # for PHP):

<Style id="format_tag" name="Format tags" bold="0" italic="0" underline="0" clr="Format tag" bkclr="#FFFFFFFF">
   <Blocks>
      <Block open="##" close="\n"/>
   </Blocks>
</Style>

When you have new style, create new scope, that allowed only in this style:

<Scope open="region" close="endregion" has_name="true" decoration="true">
   <Containers open="format_tag"/>
</Scope>