• 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

Reload parent page after submit in iframe

javascriptphpjqueryhtmliframe


PHP Snippet 1:

<form method="POST" action="getForm.php">

PHP Snippet 2:

<?php

    $input = $_POST['input'];
    // process form and do your stuff etc

    echo "<!DOCTYPE html>";
    echo "<head>";
    echo "<title>Form submitted</title>";
    echo "<script type='text/javascript'>window.parent.location.reload()</script>";
    echo "</head>";
    echo "<body></body></html>";

?>

PHP Snippet 3:

window.parent.location.reload();

Related Snippets

PHPSpreadsheet - How Do I Use Auto Migration Tool

The "client_reference_id" argument is not passed

Additional price based on cart item count in WooCommerce

Form repeater send wrong data with last element in Laravel

Confirm Leave on External Links in Wordpress

Laravel Displaying image from database

Why does array_map() with null as callback create an "array of arrays"?

Query Optimization, changing the queries in the loop into a single processing query

Wordpress wpdb->delete issue

MOODLE: What does it mean to aggregate h5p assets?

Uploading video to Youtube using Youtube Data API V3 and Google API Client PHP -- getting 401 (unauthorized) message

Error when uploading certain .png files "Interlace handling should be turned on when using png_read_image"

"Notice: Undefined variable", "Notice: Undefined index", "Warning: Undefined array key", and "Notice: Undefined offset" using PHP

find in set in laravel ? example

How to get variable from JavaScript to PHP [duplicate]

About Contact Privacy policy Terms and conditions