本文整理汇总了PHP中Uri::front_create方法的典型用法代码示例。如果您正苦于以下问题:PHP Uri::front_create方法的具体用法?PHP Uri::front_create怎么用?PHP Uri::front_create使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Uri
的用法示例。
在下文中一共展示了Uri::front_create方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: action_hotspot
public function action_hotspot($application = null, $hotspot = null)
{
// Check if we have valid application
$item = \Application\Model_Application::find_one_by_id($application);
// If no, redirect back to home page
if (!$item) {
\Response::redirect(\Uri::front_create('/'));
}
if (\Input::is_ajax()) {
// Check if we have valid hotspot
$hotspot = \Application\Model_Application_Image::find_one_by_id($hotspot);
// If not show error message
if (!$hotspot) {
echo 'Invalid link. Please try again!';
exit;
}
// Load hotspot view
echo \Theme::instance()->view($this->view_dir . 'hotspot')->set('hotspot', $hotspot, false);
} else {
\Response::redirect(\Uri::front_create('application/' . $item->seo->slug));
}
}
示例2: action_final_response
public function action_final_response($param = false)
{
$post = \Input::post();
if (isset($post['payment_status']) && $post['payment_status'] != '') {
\Messages::info(__('Thank you for your order. The current status of your payment is :status. You can check your order and payment status at My Pluris page.', array('status' => $post['payment_status'])));
\Response::redirect(\Uri::front_create('order/checkout/final'));
}
}
示例3: array
<div class="col-sm-6">
<div class="app-content">
<div class="form-group">
<p>Please enter your registered email address. You will then receive an email to reset your password.</p>
</div>
<!-- Forgot Password Form -->
<?php
echo \Form::open(array('action' => \Uri::current(), 'data-validate' => 'parsley'), array('forgot' => 1));
?>
<div class="form-group">
<label for="" class="form-label">Email Address</label>
<?php
echo \Form::input('identity', \Input::post('identity'), array("class" => "required form-control", 'data-type' => 'email', 'data-trigger' => 'change'));
?>
</div>
<button type="submit" class="btn btn-green">Submit</button>
<a href="<?php
echo \Uri::front_create('user/login');
?>
" class="link-default pull-right">Back to login?</a>
<?php
echo \Form::close();
?>
<!-- EOF Forgot Password Form -->
</div>
</div>
</div>
</div>
</div>
示例4:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>User Contact</title>
</head>
<body style="margin:0 auto; width: 620px;">
<table style="margin-top: 20px;" width="620" cellpadding="0" cellspacing="0" border="0">
<tr>
<td style="text-align: center; padding:0 0 20px 0;">
<a href="<?php
echo \Uri::front_create();
?>
">
<?php
echo \Theme::instance()->asset->img('logo.png');
?>
</a>
</td>
</tr>
<tr>
<td style="padding: 0 0 0 15px;">
<p style="font-family: Arial, Helvetica, sans-serif; font-size: 13px; color: #686868;">Hello <?php
echo $email_data['name'];
?>
, you have just sent contact request. Request details are displayed bellow. </p>
</td>
</tr>
<tr>
示例5:
if (strtolower(\Sentry::user()->groups()[0]['name']) == 'club members') {
?>
<li <?php
echo $active == 'orders' ? 'class="active"' : '';
?>
><a href="<?php
echo \Uri::front_create('user/account/referrals');
?>
" class="">Referrals</a></li>
<li><a href="<?php
echo \Uri::front_create('page/referrals');
?>
" class="">Submit A Referral</a></li>
<?php
}
?>
<?php
if ($master_user) {
?>
<li <?php
echo $active == 'users' ? 'class="active"' : '';
?>
><a href="<?php
echo \Uri::front_create('user/account/users');
?>
" class="">Users</a></li>
<?php
}
?>
</ul>
示例6:
Team
</p>
</td>
</tr>
<tr>
<td style="padding: 0 0 20px 15px;">
<p style="font-family: Arial, Helvetica, sans-serif; font-size: 9px; font-style: italic; color: #d3d3d3;">
Please do not reply to this email as it won't reach us. You have received this email as part of your <?php
echo $email_data['site_title'];
?>
account. Please forward any query you have to <a href="mailto:support@myshortlist.net">support@myshortlist.net</a>
</p>
<p style="font-family: Arial, Helvetica, sans-serif; font-size: 13px; color: #686868; font-weight: bold;">
</p>
</td>
</tr>
<tr>
<td style="text-align: left; padding:0 0 20px 15px;">
<a href="http://www.thekidscancerproject.org.au/">
<img src="<?php
echo \Uri::front_create('themes/frontend/images/the-kids-cancer-project-logo-lg.jpg');
?>
" alt="The Kids Cancer Project"/>
</a>
</td>
</tr>
</table>
</body>
</html>
示例7: action_login
public function action_login()
{
if (!(\Sentry::check() && !\Sentry::user()->is_admin())) {
\View::set_global('title', 'Login');
if (\Input::post('login')) {
$val = \User\Controller_Validate::forge('login');
if ($val->run()) {
try {
if (\Sentry::user_exists(\Input::param('identity')) && !\Sentry::user(\Input::param('identity'))->is_admin()) {
// check the credentials.
$valid_login = \Sentry::login(\Input::param('identity'), \Input::param('password'), true);
if ($valid_login) {
\Messages::success('You have logged in successfully');
// \Response::redirect(\Input::referrer(\Uri::front_create('user/account/dashboard')));
\Response::redirect(\Uri::front_create('order/checkout/cost'));
} else {
\Messages::error('Email and/or password is incorrect');
}
} else {
\Messages::error('Email and/or password is incorrect');
}
} catch (\Sentry\SentryAuthException $e) {
// show validation errors
//\Messages::error('<h4>There was an error while trying to login</h4>');
$errors = $e->getMessage();
\Messages::error($errors);
} catch (\Sentry\SentryException $e) {
// show validation errors
//\Messages::error('<h4>There was an error while trying to login</h4>');
$errors = $e->getMessage();
\Messages::error($errors);
}
} else {
if ($val->error() != array()) {
// show validation errors
foreach ($val->error() as $e) {
\Messages::error($e->get_message());
}
}
}
}
}
//Keep existing messages
\Messages::instance()->shutdown();
\Response::redirect(\Uri::front_create('order/checkout/address'));
}
示例8: isset
?>
</td>
<td><?php
echo $item->user->get('metadata.first_name') . ' ' . $item->user->get('metadata.last_name');
?>
</td>
<td><?php
echo isset($order_status[strtolower($item->status)]) ? $order_status[strtolower($item->status)] : '';
?>
</td>
<td><?php
echo $item->accepted == 1 ? 'Yes' : 'No';
?>
</td>
<td class="center"><a href="<?php
echo \Uri::front_create('user/account/order/' . $item->id);
?>
">View</a></td>
</tr>
<?php
}
?>
<?php
} else {
?>
<tr>
<td class="center" colspan="7">There are no orders yet.</td>
</tr>
<?php
}
?>
示例9:
Days remaining)</small>
<?php
}
?>
</td>
<td>
<?php
if ($job->status == 1 || $job->status == 2 && $job->active_to >= strtotime('now')) {
echo 'Active';
} else {
echo 'Expired';
}
?>
</td>
<td><a href="<?php
echo \Uri::front_create('user/account/jobs/' . $job->seo->slug);
?>
" class="arrowLink right">View</a></td>
</tr>
<?php
}
?>
<?php
} else {
?>
<tr>
<td colspan="6"><center>You have no job ads at the moment</center></td>
</tr>
<?php
}
?>
示例10: action_accept_order
public function action_accept_order($id = null)
{
// Get order
$order = \Order\Model_Order::find_one_by_id($id);
if (!$order) {
\Messages::error('Order with that ID does not exist or has been deleted.');
\Response::redirect(\Uri::front_create('user/account/orders'));
}
// Get current user
$user = \Sentry::user();
$master_user = false;
if (isset($user['metadata']['master']) && $user['metadata']['master']) {
$master_user = true;
}
if (!$master_user) {
\Messages::error("You don't have permssion for this action.");
\Response::redirect(\Uri::front_create('user/account'));
}
try {
$order->accepted = 1;
$order->save();
\Messages::success('Order successfully updated.');
\Response::redirect(\Input::referrer(\Uri::front_create('user/account')));
} catch (\Database_Exception $e) {
\Messages::error('There was an error while trying to update order.');
}
}
示例11:
echo $user->get('metadata.phone');
?>
</td>
</tr>
<tr>
<td>Email</td>
<td><?php
echo $user->get('email');
?>
</td>
</tr>
</tbody>
<tfoot>
<tr>
<td colspan="2">
<a href="<?php
echo \Uri::front_create('user/account/details/' . $user->id);
?>
" class="btn btn-green btn-block"><span>Edit details</span></a>
</td>
</tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
示例12: array
<?php
echo \Form::open(array('action' => \Uri::create('user/login'), 'data-validate' => 'parsley'), array('login' => 1));
?>
<div class="form-group">
<label for="" class="form-label">Email Address</label>
<?php
echo \Form::input('identity', \Input::post('identity'), array("class" => "required form-control", 'data-type' => 'email', 'data-trigger' => 'change'));
?>
</div>
<div class="form-group">
<label for="" class="form-label">Password</label>
<?php
echo \Form::password('password', \Input::post('password'), array("class" => "required form-control", 'data-minlength' => '6', 'data-trigger' => 'change'));
?>
</div>
<button type="submit" class="btn btn-green">Login</button>
<a href="<?php
echo \Uri::front_create('user/password');
?>
" class="link-default pull-right">Forgot Password?</a>
<?php
echo \Form::close();
?>
<!-- EOF Login Form -->
</div>
</div>
</div>
</div>
</div>
示例13: date
</td>
</tr>
<tr>
<td style="font-weight: bold; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; text-align: left;">Job Title:</td>
<td style="color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;"><?php
echo $email_data['job']['title'];
?>
</td>
</tr>
<tr>
<td style="font-weight: bold; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; text-align: left;">Job link:</td>
<td style="color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;"><a href="<?php
echo \Uri::front_create('job/' . $email_data['job']->seo->slug);
?>
"><?php
echo \Uri::front_create('job/' . $email_data['job']->seo->slug);
?>
</a></td>
</tr>
<tr>
<td style="font-weight: bold; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; text-align: left;">Order Number:</td>
<td style="color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;"><?php
echo $email_data['order']['id'];
?>
</td>
</tr>
<tr>
<td style="font-weight: bold; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; text-align: left;">Order Date:</td>
<td style="color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;"><?php
echo date('d M Y', $email_data['order']['created_at']);
?>
示例14: foreach
<div class="section-grey">
<div class="container">
<ul class="breadcrumb">
<li><a href="<?php
echo \Uri::front_create('/');
?>
">Home</a></li>
<li>></li>
<li><a href="<?php
echo \Uri::front_create('/page/products');
?>
">Products</a></li>
<?php
if ($category_parents) {
$count = 1;
?>
<li>></li>
<?php
foreach ($category_parents as $parent) {
?>
<li><a href="<?php
echo \Uri::create('product/category/' . $parent->seo->slug);
?>
"><?php
echo $parent->title;
?>
</a></li>
<?php
if (count($category_parents) != $count) {
?>
<li>></li><?php
示例15: date
echo $email_data['job']->title;
?>
</td>
<td style="border: 1px solid #d9d9d9; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;">
<?php
echo date('d M Y', $email_data['job']->active_from ?: $email_data['job']->created_at);
?>
</td>
</tr>
<tr style="border: 1px solid #d9d9d9;">
<td style="border: 1px solid #d9d9d9; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;">
<b>Job Board Link:</b>
</td>
<td colspan="2" style="border: 1px solid #d9d9d9; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; ">
<?php
echo \Html::anchor(\Uri::front_create('job/' . $email_data['job']->seo->slug), null, array('style' => 'color: #229ECA;'));
?>
</td>
</tr>
<tr style="border: 1px solid #d9d9d9;">
<td style="border: 1px solid #d9d9d9; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px;">
<b>Admin Link:</b>
</td>
<td colspan="2" style="border: 1px solid #d9d9d9; color: #646464; font-family: Arial, Helvetica, sans-serif; font-size: 12px; padding: 8px; ">
<?php
echo \Html::anchor(\Uri::create('admin/job/update/' . $email_data['job']->id), null, array('style' => 'color: #229ECA;'));
?>
</td>
</tr>
</table>
</p>