Skip to content
This repository was archived by the owner on Jan 1, 2020. It is now read-only.

Commit 442a39b

Browse files
committed
Converted all <?php echo statements to <?=
We can assume `<?=` is available now.
1 parent c75f58b commit 442a39b

File tree

4 files changed

+31
-31
lines changed

4 files changed

+31
-31
lines changed

module/Application/view/application/index/index.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<p>
55
Congratulations! You have successfully installed the
66
<a href="https://github.com/zendframework/ZendSkeletonApplication" target="_blank">ZF Skeleton Application</a>.
7-
You are currently running Zend Framework version <?php echo \Application\Module::VERSION ?>.
7+
You are currently running Zend Framework version <?= \Application\Module::VERSION ?>.
88
This skeleton can serve as a simple starting point for you to begin
99
building your application on ZF.
1010
</p>

module/Application/view/error/404.phtml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<h1>A 404 error occurred</h1>
2-
<h2><?php echo $this->message ?></h2>
2+
<h2><?= $this->message ?></h2>
33

44
<?php if (isset($this->reason) && $this->reason): ?>
55

@@ -24,15 +24,15 @@ switch ($this->reason) {
2424
}
2525
?>
2626

27-
<p><?php echo $reasonMessage ?></p>
27+
<p><?= $reasonMessage ?></p>
2828

2929
<?php endif ?>
3030

3131
<?php if (isset($this->controller) && $this->controller): ?>
3232

3333
<dl>
3434
<dt>Controller:</dt>
35-
<dd><?php echo $this->escapeHtml($this->controller) ?>
35+
<dd><?= $this->escapeHtml($this->controller) ?>
3636
<?php
3737
if (isset($this->controller_class)
3838
&& $this->controller_class
@@ -51,19 +51,19 @@ if (isset($this->controller_class)
5151
<?php if(isset($this->exception) && ($this->exception instanceof Exception || $this->exception instanceof Error)): ?>
5252
<hr/>
5353
<h2>Additional information:</h2>
54-
<h3><?php echo get_class($this->exception); ?></h3>
54+
<h3><?= get_class($this->exception) ?></h3>
5555
<dl>
5656
<dt>File:</dt>
5757
<dd>
58-
<pre class="prettyprint linenums"><?php echo $this->exception->getFile() ?>:<?php echo $this->exception->getLine() ?></pre>
58+
<pre class="prettyprint linenums"><?= $this->exception->getFile() ?>:<?= $this->exception->getLine() ?></pre>
5959
</dd>
6060
<dt>Message:</dt>
6161
<dd>
62-
<pre class="prettyprint linenums"><?php echo $this->exception->getMessage() ?></pre>
62+
<pre class="prettyprint linenums"><?= $this->exception->getMessage() ?></pre>
6363
</dd>
6464
<dt>Stack trace:</dt>
6565
<dd>
66-
<pre class="prettyprint linenums"><?php echo $this->exception->getTraceAsString() ?></pre>
66+
<pre class="prettyprint linenums"><?= $this->exception->getTraceAsString() ?></pre>
6767
</dd>
6868
</dl>
6969
<?php
@@ -76,19 +76,19 @@ if (isset($this->controller_class)
7676
<ul class="unstyled">
7777
<?php while($e) : ?>
7878
<li>
79-
<h3><?php echo get_class($e); ?></h3>
79+
<h3><?= get_class($e) ?></h3>
8080
<dl>
8181
<dt>File:</dt>
8282
<dd>
83-
<pre class="prettyprint linenums"><?php echo $e->getFile() ?>:<?php echo $e->getLine() ?></pre>
83+
<pre class="prettyprint linenums"><?= $e->getFile() ?>:<?= $e->getLine() ?></pre>
8484
</dd>
8585
<dt>Message:</dt>
8686
<dd>
87-
<pre class="prettyprint linenums"><?php echo $e->getMessage() ?></pre>
87+
<pre class="prettyprint linenums"><?= $e->getMessage() ?></pre>
8888
</dd>
8989
<dt>Stack trace:</dt>
9090
<dd>
91-
<pre class="prettyprint linenums"><?php echo $e->getTraceAsString() ?></pre>
91+
<pre class="prettyprint linenums"><?= $e->getTraceAsString() ?></pre>
9292
</dd>
9393
</dl>
9494
</li>

module/Application/view/error/index.phtml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
<h1>An error occurred</h1>
2-
<h2><?php echo $this->message ?></h2>
2+
<h2><?= $this->message ?></h2>
33

44
<?php if (isset($this->display_exceptions) && $this->display_exceptions): ?>
55

66
<?php if(isset($this->exception) && ($this->exception instanceof Exception || $this->exception instanceof Error)): ?>
77
<hr/>
88
<h2>Additional information:</h2>
9-
<h3><?php echo get_class($this->exception); ?></h3>
9+
<h3><?= get_class($this->exception) ?></h3>
1010
<dl>
1111
<dt>File:</dt>
1212
<dd>
13-
<pre class="prettyprint linenums"><?php echo $this->exception->getFile() ?>:<?php echo $this->exception->getLine() ?></pre>
13+
<pre class="prettyprint linenums"><?= $this->exception->getFile() ?>:<?= $this->exception->getLine() ?></pre>
1414
</dd>
1515
<dt>Message:</dt>
1616
<dd>
17-
<pre class="prettyprint linenums"><?php echo $this->escapeHtml($this->exception->getMessage()) ?></pre>
17+
<pre class="prettyprint linenums"><?= $this->escapeHtml($this->exception->getMessage()) ?></pre>
1818
</dd>
1919
<dt>Stack trace:</dt>
2020
<dd>
21-
<pre class="prettyprint linenums"><?php echo $this->escapeHtml($this->exception->getTraceAsString()) ?></pre>
21+
<pre class="prettyprint linenums"><?= $this->escapeHtml($this->exception->getTraceAsString()) ?></pre>
2222
</dd>
2323
</dl>
2424
<?php
@@ -31,19 +31,19 @@
3131
<ul class="unstyled">
3232
<?php while($e) : ?>
3333
<li>
34-
<h3><?php echo get_class($e); ?></h3>
34+
<h3><?= get_class($e) ?></h3>
3535
<dl>
3636
<dt>File:</dt>
3737
<dd>
38-
<pre class="prettyprint linenums"><?php echo $e->getFile() ?>:<?php echo $e->getLine() ?></pre>
38+
<pre class="prettyprint linenums"><?= $e->getFile() ?>:<?= $e->getLine() ?></pre>
3939
</dd>
4040
<dt>Message:</dt>
4141
<dd>
42-
<pre class="prettyprint linenums"><?php echo $this->escapeHtml($e->getMessage()) ?></pre>
42+
<pre class="prettyprint linenums"><?= $this->escapeHtml($e->getMessage()) ?></pre>
4343
</dd>
4444
<dt>Stack trace:</dt>
4545
<dd>
46-
<pre class="prettyprint linenums"><?php echo $this->escapeHtml($e->getTraceAsString()) ?></pre>
46+
<pre class="prettyprint linenums"><?= $this->escapeHtml($e->getTraceAsString()) ?></pre>
4747
</dd>
4848
</dl>
4949
</li>
Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
1-
<?php echo $this->doctype(); ?>
1+
<?= $this->doctype() ?>
22

33
<html lang="en">
44
<head>
55
<meta charset="utf-8">
6-
<?php echo $this->headTitle('ZF Skeleton Application')->setSeparator(' - ')->setAutoEscape(false) ?>
6+
<?= $this->headTitle('ZF Skeleton Application')->setSeparator(' - ')->setAutoEscape(false) ?>
77

8-
<?php echo $this->headMeta()
8+
<?= $this->headMeta()
99
->appendName('viewport', 'width=device-width, initial-scale=1.0')
1010
->appendHttpEquiv('X-UA-Compatible', 'IE=edge')
1111
?>
1212

1313
<!-- Le styles -->
14-
<?php echo $this->headLink(['rel' => 'shortcut icon', 'type' => 'image/vnd.microsoft.icon', 'href' => $this->basePath() . '/img/favicon.ico'])
14+
<?= $this->headLink(['rel' => 'shortcut icon', 'type' => 'image/vnd.microsoft.icon', 'href' => $this->basePath() . '/img/favicon.ico'])
1515
->prependStylesheet($this->basePath('css/style.css'))
1616
->prependStylesheet($this->basePath('css/bootstrap-theme.min.css'))
1717
->prependStylesheet($this->basePath('css/bootstrap.min.css'))
1818
?>
1919

2020
<!-- Scripts -->
21-
<?php echo $this->headScript()
21+
<?= $this->headScript()
2222
->prependFile($this->basePath('js/bootstrap.min.js'))
2323
->prependFile($this->basePath('js/jquery-3.0.0.min.js'))
2424
?>
@@ -32,22 +32,22 @@
3232
<span class="icon-bar"></span>
3333
<span class="icon-bar"></span>
3434
</button>
35-
<a class="navbar-brand" href="<?php echo $this->url('home') ?>"><img src="<?php echo $this->basePath('img/zf-logo.png') ?>" alt="Zend Framework <?php echo \Application\Module::VERSION ?>"/>&nbsp;Skeleton Application</a>
35+
<a class="navbar-brand" href="<?= $this->url('home') ?>"><img src="<?= $this->basePath('img/zf-logo.png') ?>" alt="Zend Framework <?= \Application\Module::VERSION ?>"/>&nbsp;Skeleton Application</a>
3636
</div>
3737
<div class="collapse navbar-collapse">
3838
<ul class="nav navbar-nav">
39-
<li class="active"><a href="<?php echo $this->url('home') ?>">Home</a></li>
39+
<li class="active"><a href="<?= $this->url('home') ?>">Home</a></li>
4040
</ul>
4141
</div><!--/.nav-collapse -->
4242
</div>
4343
</nav>
4444
<div class="container">
45-
<?php echo $this->content; ?>
45+
<?= $this->content; ?>
4646
<hr>
4747
<footer>
48-
<p>&copy; 2005 - <?php echo date('Y') ?> by Zend Technologies Ltd. All rights reserved.</p>
48+
<p>&copy; 2005 - <?= date('Y') ?> by Zend Technologies Ltd. All rights reserved.</p>
4949
</footer>
5050
</div> <!-- /container -->
51-
<?php echo $this->inlineScript() ?>
51+
<?= $this->inlineScript() ?>
5252
</body>
5353
</html>

0 commit comments

Comments
 (0)