title: Redirect to link with anchor
body: <p>I have a view file 'profile.php' with a tab menu</p>
  
  <pre><code>&lt;ul class="nav nav-tabs"&gt;
      &lt;li class="active"&gt;
          &lt;a href="#profile" data-toggle="tab"&gt;Information&lt;/a&gt;
      &lt;/li&gt;
      &lt;li&gt;
          &lt;a href="#password" data-toggle="tab"&gt;Change password&lt;/a&gt;
      &lt;/li&gt;
      &lt;li&gt;
          &lt;a href="#account" data-toggle="tab"&gt;Delete account&lt;/a&gt;
      &lt;/li&gt;
  &lt;/ul&gt;
  
  &lt;div class="tab-content"&gt;
          &lt;div class="tab-pane fade in active" id="profile"&gt;
              ... profile content
          &lt;/div&gt;
  
          &lt;div class="tab-pane fade" id="password"&gt;
              ... password content
          &lt;/div&gt;
  
          &lt;div class="tab-pane fade" id="account"&gt;
              &lt;?php $form = ActiveForm::begin([
                                       'method' =&gt; 'post',
                                       'action' =&gt; ['user/delete'],
                                        ]);
              ?&gt;
  
              &lt;div class="col-lg-12"&gt;
                  &lt;?php echo $form-&gt;field($model, 'delpassword')
                                  -&gt;passwordInput(['maxlength' =&gt; true,'placeholder' =&gt; 'Password'])
                                  -&gt;label(false) 
                  ?&gt;
              &lt;/div&gt;
  
              &lt;div class="form-group"&gt;
                  &lt;?php echo Html::submitButton('Delete', ['class' =&gt; 'custom-button']) ?&gt;
              &lt;/div&gt;
  
              &lt;?php ActiveForm::end(); ?&gt;
          &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I can go to the account tab by adding #tab_account to the end of url</p>
  
  <p>In UserController i have this action : </p>
  
  <pre><code>public function actionDelete()
  {   
      $id = Yii::$app-&gt;user-&gt;identity-&gt;user_id;
  
      $model = $this-&gt;findModel($id); 
  
      $model-&gt;setscenario('delete_account');
  
      if ($model-&gt;load(Yii::$app-&gt;request-&gt;post()) &amp;&amp; $model-&gt;validate()) {
  
          $model-&gt;delete();
          return $this-&gt;goHome();
  
      } else {
  
          return $this-&gt;render('profile', [
                  'model' =&gt; $model,
          ]);
      }
  }
  </code></pre>
  
  <p>If the account was not deleted for some reason the action renders the profile.php but on the first tab (#tab_profile). I want to redirect directly to the account tab. I tried return $this->refresh(#tab_account); but i end up in a redirect loop.</p>