Support » Plugin: Social Articles » Direct link to new article.

  • Resolved mikesellr

    (@mikesellr)


    So I’m using the review it theme and so far what I have been able to collect from my theme is that my links in the header location that my code needs to be and from the other thinks the following

    <a href="<?php ?>">New Article</a> <span class="login-divider">|</span>

    So after playing around with it a bit I was able to figure out the the code so far is correct but I’m new to PHP and unsure of how to add in the <?php ?> to get a direct link to the New Article page. Thanks.

    http://wordpress.org/extend/plugins/social-articles/

Viewing 6 replies - 1 through 6 (of 6 total)
  • I also found the new article array but was unable to find much on what to call out to.

    $sub_nav[] = array(
                    'name'            =>  __( 'New Article' , 'social-articles' ),
                    'slug'            => 'new',
                    'parent_url'      => $social_articles_link,
                    'parent_slug'     => SA_SLUG,
                    'screen_function' => 'new_article_screen',
                    'position'        => 20
                );
    Plugin Author Broobe

    (@broobe_dev)

    Hi! In version 1.4, I added the direct link in the top admin bar. I hope this works for you!

    Thanks for using our plugin!

    Unfortunately my admin bar is disabled. I would like to just move that direct link right by the user name in the top. I’m guessing I just need whatever the PHP code is to call to that.

    Plugin Author Broobe

    (@broobe_dev)

    Hi!

    Maybe something like that:

    <?php
    $user_domain = bp_is_user() ? bp_displayed_user_domain() : bp_loggedin_user_domain();
    
    ?>
    
    <a href="<?php echo trailingslashit( $user_domain.'articles/new' )?>">New Article</a>

    Let me know if it works for you!

    lets just say you are awesome. It worked perfectly, thank you so much.

    Plugin Author Broobe

    (@broobe_dev)

    I’m glad that it’s working! Don’t forget to rate the plugin 😉 Keep in touch for future updates! thanks!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Direct link to new article.’ is closed to new replies.