• 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

PHP header location absolute URL

php


PHP Snippet 1:

header("location:http://www.example.com/path/to/myfile.php");
exit;

PHP Snippet 2:

$url = $_SERVER["HTTP_HOST"]."/path/to/myfile.php";
header("location:".$url);
exit;

Related Snippets

JQuery content editable div and text box on submit not sending POST

How to assert parameter attribute sub-structures in PHPUnit mock call expectations

PHP Get value from JSON [duplicate]

MOODLE: What does it mean to aggregate h5p assets?

How can I make this nested location configuration use the correct path to call a php program?

Render the content of default_filter.php in Joomla front-end

Too few arguments to function PendingResourceRegistration::name(),1 passed in C:xampphtdocsproject outesweb.php on line 18 and exactly 2 expected

Apply filter array/return terms

Woocommerce Edit Message "An account is already registered with your email address. Please log in."

Changing font color in javascript

How to change HTML structure inside WP <head>

How to find phpcs current default standard

PHPExcel export HTML table to xlsx

Docker & Laravel : configure: error: Package requirements (oniguruma) were not met

(PHPUnit) PHP Fatal error: Uncaught Error: Call to undefined function each()

About Contact Privacy policy Terms and conditions