• 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

How to install LDAP in Docker php-fpm alpine

Wordpress wpdb->delete issue

Transpose and flatten two-dimensional indexed array where rows may not be of equal length

How to update array value in Laravel

Make certain characters of a word from string bold

oauth-private.key does not exist or is not readable

yii2 and mssql insert varbinary into model

What is PHP's equivalent of JavaScript's "array.every()"?

MISSING UPDATES FOR: MEDIA Drupal 9

Log file is not being written in Laravel 5.5

PHPUnit gives error: Target [IlluminateContractsViewFactory] is not instantiable

How to show a popup modal in codeIgniter?

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

Laravel database insert with combining array and string

Fatal error: Uncaught Error: Call to undefined method mysqli_stmt::fetch_assoc() [duplicate]

About Contact Privacy policy Terms and conditions