Created
July 9, 2021 15:00
-
-
Save medigeek/9f9f1aacb2e4ea7822527002cfbedf43 to your computer and use it in GitHub Desktop.
Invalidate magento 2 reindex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//set your indexer to update on schedule | |
//and make sure your cronjob for magento is running | |
header("Content-type: text/plain"); | |
//Assuming the php script is in pub/ subfolder. You can put it wherever. | |
chdir(__DIR__.'/../'); | |
$out = shell_exec('php bin/magento indexer:reset'); | |
echo("\n".$out."\n"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment