本文整理汇总了PHP中uri::path方法的典型用法代码示例。如果您正苦于以下问题:PHP uri::path方法的具体用法?PHP uri::path怎么用?PHP uri::path使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类uri
的用法示例。
在下文中一共展示了uri::path方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: path
function path($key = null, $default = null)
{
$path = self::$path;
if (!$path) {
$path = url::strip_query(self::raw());
$path = (array) str::split($path, '/');
self::$path = $path;
}
if ($key === null) {
return $path;
}
return a::get($path, $key, $default);
}
示例2:
?>
">Home</a> |
<a href="<?php
echo uri::path('list/create');
?>
">Create</a> |
<a href="<?php
echo uri::path('page/tools');
?>
">Tools</a> |
<a href="<?php
echo uri::path('page/help');
?>
">Help</a> |
<a href="<?php
echo uri::path('page/about');
?>
">About</a> |
<a href="http://github.com/jmhobbs/MkLst" target="_blank">GitHub</a>
</div>
<div id="core">
<?php
if (isset($flash)) {
?>
<div class="flash">
<?php
echo $flash;
?>
</div>
<?php
}
示例3:
<h1>Welcome To MkLst</h1>
<p>
Make lists. Print them. Share them.
</p>
<p>
<a href="<?php
echo uri::path('page/about');
?>
">Learn More</a>
</p>
<h2>Try It</h2>
<p>
<form action="<?php
echo uri::path('list/create');
?>
">
<button>Create A New List</button>
or, see <a href="http://mklst.com/list/view/66e3cba5510364250589121cfc0793dddd31f20b">if I'm keeping up with my lawn work.</a>
</form>
</p>
<h2>See It</h2>
<object width="480" height="385"><param name="movie" value="http://www.youtube.com/v/mW6k4TiJdTg&hl=en_US&fs=1&color1=0x3a3a3a&color2=0x999999"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/mW6k4TiJdTg&hl=en_US&fs=1&color1=0x3a3a3a&color2=0x999999" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="385"></embed></object>
示例4:
<p>
<em>Lasciate ogne speranza, voi ch'intrate.</em>
</p>
<p>
This can not be undone.
</p>
<h2>Fine, I get it.</h2>
<form method="POST">
<?php
if ($is_protected) {
?>
<label for="password">List Delete Password:</label>
<input id="password" name="password" type="password" />
<br/>
<?php
}
?>
<label for="yesimsure">Yes, I'm sure.</label>
<input type="checkbox" value="yes" name="yesimsure" id="yesimsure" />
<br/>
<input type="submit" value="Delete List" class="label-offset" /> or <a href="<?php
echo uri::path('list/view/' . $id);
?>
">Cancel</a>
</form>
示例5:
<h3>Reordering Items</h3>
<p>
<img src="<?php
echo uri::path('img/help/reorder-items.png');
?>
" /><br/>
Click and drag the item you want to where you want it. Release.
</p>
<h3>Strikethrough An Item</h3>
<p>
<img src="<?php
echo uri::path('img/help/strikethrough-item-1.png');
?>
" /><br/>
Click on the item to edit it. Add a single dash "-" to the very front of the item. Hit "enter" to save."<br/>
<img src="<?php
echo uri::path('img/help/strikethrough-item-2.png');
?>
" /><br/>
</p>
<hr/>
<a name="bugs"></a>
<h2>Reporting Bugs & Requesting Features</h2>
<p>
All version control and issue management is done via <a href="http://github.com/jmhobbs/MkLst">our GitHub page</a>.
</p>
示例6:
<h1>MkLst Tools</h1>
<ul>
<li><a href="<?php
echo uri::path('list/create');
?>
">Create New List</a></li>
<li><a href="<?php
echo uri::path('tools/recover');
?>
">List Recovery</a></li>
</ul>
示例7:
<span class="context-link">(<a href="<?php
echo uri::path('list/edit/' . $alist->getId());
?>
">Edit</a>)</span>
<?php
} else {
?>
<span class="context-link">(<a href="<?php
echo uri::path('list/view/' . $alist->getId());
?>
">View</a>)</span>
<?php
}
?>
<span class="context-link">(<a href="<?php
echo uri::path('list/delete/' . $alist->getId());
?>
">Delete</a>)</span>
</h1>
<?php
if ($edit) {
?>
<div class="buttons">
<button class="add">Add Item +</button>
<button class="save">Save</button>
<ul class="trash"><li class="ignore">Trash</li></ul>
</div>
<?php
}
?>