fix(core): cache-busting thumbnail via bump version 1.1.5 dan perbaikan rute redirect aktivasi
This commit is contained in:
+6
-3
@@ -42,11 +42,14 @@ function edukarsa_admin_scripts( $hook ) {
|
||||
add_action( 'admin_enqueue_scripts', 'edukarsa_admin_scripts' );
|
||||
|
||||
// 4. REDIRECT SETELAH AKTIVASI TEMA
|
||||
|
||||
// 4. REDIRECT AMAN SETELAH AKTIVASI TEMA
|
||||
function edukarsa_activation_redirect() {
|
||||
global $pagenow;
|
||||
if ( is_admin() && 'themes.php' === $pagenow && isset( $_GET['activated'] ) ) {
|
||||
wp_redirect( admin_url( 'admin.php?page=edukarsa_settings' ) );
|
||||
if ( 'themes.php' === $pagenow && isset( $_GET['activated'] ) ) {
|
||||
// Redirect yang aman, dipanggil setelah seluruh menu dan hak akses WordPress siap
|
||||
wp_safe_redirect( admin_url( 'admin.php?page=edukarsa_settings' ) );
|
||||
exit;
|
||||
}
|
||||
}
|
||||
add_action( 'after_switch_theme', 'edukarsa_activation_redirect' );
|
||||
add_action( 'admin_init', 'edukarsa_activation_redirect' );
|
||||
|
||||
Reference in New Issue
Block a user