• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Laravel 4 Redirect::back() not going to previous page (refreshing current page)

phpredirectlaravel-4


PHP Snippet 1:

Route::get('/customer', array('as' => 'customer', 'uses' => 'MyController@showCustomer'));

PHP Snippet 2:

function saveCustomer($id) {

    ...

    Redirect::route('customer');
}

PHP Snippet 3:

if(isset($_SERVER['HTTP_REFERER']))
    return Redirect::back();

return Redirect::to('/');

Related Snippets

how to remove %20 in the url in php

Laravel Mix Uncaught ReferenceError: $ is not defined

get folder directory from input type file - PHP

Whats the point of running Laravel with the command 'php artisan serve'?

How to convert the int value to inch in PHP [closed]

How can I get new CSRF token in LARAVEL by using ajax

How to use $this->session->set_userdata in codeigniter

Store / Website Column in Magento 2 Admin Grid - Custom Module

How do I loop through an MS SQL database with VB.NET?

Xdebug 3 not showing in phpinfo on m1 Monterey

How can I make good efficent AJAX live forms with just jQuery and

Cut an arabic string

Group rows by column and sum another column within groups [duplicate]

Call authenticate manually in router middleware

Could not decode a text frame as UTF-8.

About Contact Privacy policy Terms and conditions