• 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

Trying to iterate over a mongodb cursor twice - failing

Laravel lang slug in url

PHP mail sending empty mails

PHP - Store information with NO database

Hide specific products from unlogged users based in product category in WooCommerce

Boolean assignment operators in PHP

Access relation of pivot table in Laravel

Login if user is active using Laravel Breeze

phpunit - mockbuilder - set mock object internal property

Natural ORDER in Laravel Eloquent ORM

Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255

PHP echo values of all sub keys [duplicate]

If action is on a different page do I use fwrite function

Download & Save Zoom Recording in directory by PHP

httpd.conf on Windows: can't locate API model structure `php8_module`

About Contact Privacy policy Terms and conditions