Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)
  • Forum: Developing with WordPress
    In reply to: Page load
    Thread Starter soosdani

    (@soosdani)

    My plugin: ~/wp-content/plugins/xyz/xyz.php

    <?php
    
    $foo = // ???
    
    if ( $foo == 'fwd' ) { // https://xyz.com/fwd
    
    header ( 'location:  https://abc.com/dwf' ); // or wp_redirect ();
    
    } else {}
    
    ?>

    My posts/pages slugs: homepage, blog, contact. No fwd slug.

    Questions:

    1. The $foo?
    2. The ~/wp-content/plugins/xyz/xyz.php file is ok or another file write?

    • This reply was modified 4 years, 8 months ago by soosdani.
    • This reply was modified 4 years, 8 months ago by soosdani.
    • This reply was modified 4 years, 8 months ago by soosdani.
    Forum: Developing with WordPress
    In reply to: Page load
    Thread Starter soosdani

    (@soosdani)

    Yes, I would like write own plugin.

    Thread Starter soosdani

    (@soosdani)

    Have you somehow set up the special widgets to be viewable by subscribers?

    Yes, I use add_action ( ‘wp_dashboard_setup’, … ) and wp_add_dashboard_widget. The subscribers see my dashboard widget.

    The code (~/wp-content/plugins/xyz/xyz.php):

        add_filter ( 'login_redirect', 'rdrct' );
    
        function rdrct () {
    
            return 'wp-admin';
    
        }

    It works, but is it good?

    • This reply was modified 4 years, 9 months ago by soosdani.
    • This reply was modified 4 years, 9 months ago by soosdani.
    Thread Starter soosdani

    (@soosdani)

    @bcworkz and @littlepackage yes, I have special dashboard with own dashboard widgets. My plugin: ~/wp-content/plugins/xyz/xyz.php:

    add_filter ( 'login_redirect', 'https://xyz/wp-admin/index.php' );

    Not work and the ~/wp-content/plugins/xyz/functions.php:

    add_filter ( 'login_redirect', 'https://xyz/wp-admin/index.php' );

    Not work too. How to?

    Thread Starter soosdani

    (@soosdani)

    The first seven users have a username and my two manually user is not username because the wp_users.user_login is empty. If I change this, the password reminder emails are sent. The problem is solved. Thank you very much!

Viewing 5 replies - 1 through 5 (of 5 total)