



<!-- Modal -->

<div class="modal fade" id="modal-login" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">

  <div class="modal-dialog">

    <div class="modal-content">

      <div class="modal-header">

        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>

        <h4 class="modal-title" id="myModalLabel">Login</h4>

      </div>

      <div class="modal-body">

          <a href="<?=base_url("site/login")?>" class="btn btn-success">Entrar</a>

        </form>

      </div>

    </div>

  </div>

</div>



<script>

    //chama modal de login via url

    var url = window.location.href

    if(url.search("logar")>0){

        $("#modal-login").modal("show");

    } 

</script>