Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'test'

Viewing 25 results - 3,226 through 3,250 (of 11,606 total)
  • Author
    Search Results
  • #167732
    Robkk
    Moderator

    I just split your reply into a topic so that you can have your own topic about this.

    Please do not bump topics, especially topics that are about 8 years old.

    If you are using the latest bbPress plugin.

    To get the user’s username use

    <?php 
      global $current_user;
      get_currentuserinfo();
      echo $current_user->user_login;
    ?>

    https://codex.wordpress.org/Function_Reference/get_currentuserinfo

    You can also just use the WordPress toolbar.

    #167730
    Robkk
    Moderator

    Where do I add those lines of code?

    It is CSS put it in your child themes style.css file, a custom css plugin, or anywhere you can put custom css.

    I assume you want me to edit one of the PHP files

    No, never edit the plugin core files, unless you are 100% sure you know what you are doing. Since you are a novice, just do not do it.

    I don’t know what “multisite” is.

    Since you do not know what it is, I am going to assume you do not have it. You do not need it to solve this issue so no need to install any plugins, just curious if you have it. I see it is probably that you have a test enviroment of WordPress because you are planning on migrating to a WordPress/bbPress install from phpBB.

    Yes, your deleteme user does appear in the Users list.

    Does it have the Participant forum role too?

    Alright, so I assume you’re talking about Peter’s Login Redirect plugin, and I assume I’ll need to edit the settings under Settings -> Login/logout redirects, correct?

    You seem to be getting that together. Not sure why you are redirecting to the forums especially a specific forum, but yeah you got it.

    I created a test Subscriber user, which in fact is redirected upon logging in, but isn’t logged in (of course that code you recommended still needs added in).

    The code I gave you helped remove the bullet list displaying in your forums.

    Again thank you for trying to help Robkk, but I would definitely like it if you could be a bit more descriptive in what I need to do to fix this login problem

    We still have to troubleshoot what is causing the user to not seem to be have access to the forums.

    Try some of these troubleshooting steps listed in this guide to see if it could be theme/custom theme related like if you copied the bbPress customizable templates into your child theme and edited them and messed something up on accident, check to see if a plugin could be causing an issue, you can check to see if caching could be an issue by flushing cache from your site, if you edited the bbPress and ever do not remember what you edited you can reinstall a fresh version of the plugin to see if it fixes the issue also.

    Troubleshooting

    Do not just go deleting cache files from WordPress or code in bbPress.

    #167721
    Pascal Casier
    Moderator

    Very first version of my plugin uploaded in the WP queue today. Will report here when you can start testing.

    #167720
    Mei Ling
    Participant

    Hello,

    We have done this… we are still testing it. Be careful use VPS:

    <?php

    /**
    * Now that you have your custom column, it’s bulk/quick edit showtime!
    * The filters are ‘bulk_edit_custom_box’ and ‘quick_edit_custom_box’. Both filters
    * pass the same 2 arguments: the $column_name (a string) and the $post_type (a string).
    *
    * Your data’s form fields will obviously vary so customize at will. For this example,
    * we’re using an input. Also take note of the css classes on the <fieldset> and <div>.
    * There are a few other options like ‘inline-edit-col-left’ and ‘inline-edit-col-center’
    * for the fieldset and ‘inline-edit-col’ for the div. I recommend studying the WordPress
    * bulk and quick edit HTML to see the best way to layout your custom fields.
    */
    add_action( ‘bulk_edit_custom_box’, ‘manage_wp_posts_be_qe_bulk_quick_edit_custom_box’, 10, 2 );
    //add_action( ‘quick_edit_custom_box’, ‘manage_wp_posts_be_qe_bulk_quick_edit_custom_box’, 10, 2 );
    function manage_wp_posts_be_qe_bulk_quick_edit_custom_box( $column_name, $post_type ) {

    switch ( $post_type ) {
    case ‘topic’:
    switch( $column_name ) {
    case ‘bbp_topic_forum’:
    ?><fieldset class=”inline-edit-col-left”>
    <div class=”inline-edit-col”>
    <label>
    <span class=”title”>Deplacer dans le forum</span>
    <span class=”input-text-wrap”>
    <select name=”deplacer”>
    <option value=”Null”></option>
    <?php /* recuperation des forums “forum” */
    $args = array(
    // ‘post_parent__not_in’=> array( 0 ) ,
    ‘post_type’ => ‘forum’
    );
    $forums = new WP_Query( $args );
    // boucle de test affiche en debug id et titre forum
    if ( $forums->have_posts() ) {
    while ( $forums->have_posts() ) {
    $forums->the_post();
    echo ‘<option value=”‘.$forums->post->ID.'”>’.get_the_title() . ‘</option>’ ;
    }
    }
    wp_reset_postdata();?>

    </select>
    </span>
    </label>
    </div>
    </fieldset><?php
    break;
    }
    break;
    }
    }

    /**
    * When you click ‘Quick Edit’, you may have noticed that your form fields are not populated.
    * WordPress adds one ‘Quick Edit’ row which moves around for each post so the information cannot
    * be pre-populated. It has to be populated with JavaScript on a per-post ‘click Quick Edit’ basis.
    *
    * WordPress has an inline edit post function that populates all of their default quick edit fields
    * so we want to hook into this function, in a sense, to make sure our JavaScript code is run when
    * needed. We will ‘copy’ the WP function, ‘overwrite’ the WP function so we’re hooked in, ‘call’
    * the original WP function (via our copy) so WordPress is not left hanging, and then run our code.
    *
    * Remember where we wrapped our column data in a <div> in Step 2? This is where it comes in handy,
    * allowing our Javascript to retrieve the data by the <div>’s element ID to populate our form field.
    * There are other methods to retrieve your data that involve AJAX but this route is the simplest.
    *
    * Don’t forget to enqueue your script and make sure it’s dependent on WordPress’s ‘inline-edit-post’ file.
    * Since we’ll be using the jQuery library, we need to make sure ‘jquery’ is loaded as well.
    *
    * I have provided several scenarios for where you’ve placed this code. Simply uncomment the scenario
    * you’re using. For all scenarios, make sure your javascript file is in the same folder as your code.
    */
    add_action( ‘admin_print_scripts-edit.php’, ‘manage_wp_posts_be_qe_enqueue_admin_scripts’ );
    function manage_wp_posts_be_qe_enqueue_admin_scripts() {

    // if code is in theme functions.php file
    wp_enqueue_script( ‘manage-wp-posts-using-bulk-quick-edit’, trailingslashit( get_bloginfo( ‘stylesheet_directory’ ) ) . ‘js/bulk_quick_edit.js’, array( ‘jquery’, ‘inline-edit-post’ ), ”, true );

    // if using code as plugin
    //wp_enqueue_script( ‘manage-wp-posts-using-bulk-quick-edit’, trailingslashit( plugin_dir_url( __FILE__ ) ) . ‘js/bulk_quick_edit.js’, array( ‘jquery’, ‘inline-edit-post’ ), ”, true );

    }

    add_action( ‘save_post’, ‘save_deplacer’);
    function save_deplacer() {
    global $wpdb;

    if( $_GET[‘post_type’]=’topic’ && $_GET[‘bulk_edit’]=’Mettre à jour’){

    $post_ids= $_GET[‘post’];
    $forum_id = $_GET[‘deplacer’];
    foreach($post_ids as $post_id){

    $wpdb->query(“UPDATE $wpdb->posts SET post_parent = $forum_id WHERE ID = $post_id “);
    }
    }
    }
    /*echo ‘

    ';
    	print_r($post_type);
    	echo '

    ‘;
    die();

    Array
    (
    [s] =>
    [post_status] => all
    [post_type] => topic
    [_wpnonce] => dcfdf56a2d
    [_wp_http_referer] => /public/wptest/wp-admin/edit.php?post_type=topic&paged=1
    [action] => edit
    [m] => 0
    [bbp_forum_id] =>
    [paged] => 1
    [mode] => excerpt
    [_status] => -1
    [tax_input] => Array
    (
    [topic-tag] =>
    )

    [Deplacer] => 39
    [bulk_edit] => Mettre à jour
    [post_view] => excerpt
    [screen] => edit-topic
    [post] => Array
    (
    [0] => 43
    [1] => 41
    )

    [action2] => -1
    )*/

    /**
    * Step 3: display an admin notice on the Posts page after deplacer
    */
    add_action(‘admin_notices’, ‘custom_bulk_admin_notices’);
    function custom_bulk_admin_notices() {
    global $post_type, $pagenow ;

    if( $_GET[‘post_type’]=’topic’ && $_GET[‘bulk_edit’]=’Mettre à jour’){

    $messages = array();
    $messages[] = bbp_admin_repair_forum_meta();
    $messages[] = bbp_admin_repair_topic_meta();
    $messages[] = bbp_admin_repair_freshness();
    $messages[] = bbp_admin_repair_reply_menu_order();
    $messages[] = bbp_admin_repair_forum_topic_count();
    $messages[] = bbp_admin_repair_forum_reply_count();
    $messages[] = bbp_admin_repair_topic_reply_count();
    $messages[] = bbp_admin_repair_topic_voice_count();
    $messages[] = bbp_admin_repair_user_topic_count();
    $messages[] = bbp_admin_repair_user_reply_count();

    //if($pagenow == ‘edit.php’ && $post_type == ‘topic’ && isset($_GET[‘deplacer’])) {

    $messageori = sprintf( _n( ‘Topic déplacé.’, ‘%s topics déplacés.’, $_REQUEST[‘deplacer’] ), number_format_i18n( $_REQUEST[‘deplacer’] ) );

    foreach ($messages as $message){
    echo'<div class=\”updated\”><p>’.$message[1].'</p></div>’;
    }
    echo “<div class=\”updated\”><p>{$messageori}</p></div>”;
    }
    }

    ?>

    #167716
    mica123
    Participant

    Hello @casiepa, @robkk

    I did more testing, this time I looked at response headers following instructions from this article. I am not sure if this is the right course of action but if you could bear with me could you perhaps have a look at the results below? The first part is from my good site and the second part is from the problematic site:

    My good site results:
    Response headers:
    cache control: max-age=0
    Request headers:
    cache control: “max-age=0”

    bbpress
    Response headers:
    cache control: max-age=2592000, public, proxy-revalidate, public, proxy-revalidate, must-revalidate
    Cache control: max-age=0

    After login:
    Response header:
    Cache control: no-cache, must-revalidate, max-age=0

    My bad site results:
    Response headers:
    Cache control: max-age=3600
    Request header:
    Cache control: max-age=0

    bbpress:
    Response headers:
    Cache control: max-age=2592000
    Request header:
    Cache control: max-age=0

    After successful login response header says:
    Cache control: no-cache, must-revalidate, max-age=0

    However, clicking on page that was viewed before login,
    response header says:
    Cache control: max-age=3600

    #167715
    names_are_useless
    Participant

    Thank you for trying to help Robkk.

    Where do I add those lines of code? I assume you want me to edit one of the PHP files (click “Edit” for bbPress plugin). I just tried adding it to “bbpress/bbpress.php” (since its the first php file that comes up) at the end of the file. I received a “Parse error: syntax error, unexpected ‘-‘, expecting ‘(‘ in /var/www/vhosts/laysofalthas.com/epochgames/wordpress/wp-content/plugins/bbpress/bbpress.php on line 933”. There’s a bunch of other php files, and I have no idea where I’m supposed to put that code snippet (novice here), so I’m just going to delete that code and wait for further instructions.

    I don’t know what “multisite” is. Looking through the plugin list, I see several (Multisite Toolbar Additions, Multisite Global Search, etc). Would you recommend I add one of them? Can you give me the specific name of one?

    Alright, so how can I fix it so “yoursite.com/wordpress/wp-login.php” leads to “yoursite.com/wp-login.php” instead?

    Yes, your deleteme user does appear in the Users list.

    Alright, so I assume you’re talking about Peter’s Login Redirect plugin, and I assume I’ll need to edit the settings under Settings -> Login/logout redirects, correct? I have now set the “administrator” role to go to the URL “yoursite.com/wordpress/wp-admin/” and it works perfectly, so thank you. I have also set it so Subscribers are redirected to “http://epochgames.co.uk/forums/forum/test/&#8221; when they login. I created a test Subscriber user, which in fact is redirected upon logging in, but isn’t logged in (of course that code you recommended still needs added in). Can’t say I’m overjoyed that I have to change the URL to the forums every time I want to login as an administrator account, but at least I can get to the Dashboard now without having to memorize the URL.

    Again thank you for trying to help Robkk, but I would definitely like it if you could be a bit more descriptive in what I need to do to fix this login problem. I am very much a novice still with WordPress.

    #167707
    Robkk
    Moderator

    This fixes the list issue.

    #bbpress-forums li {
        list-style: none !important;
    }

    I created a user called “deleteme” and I see the issue you are talking about.

    Do you have multisite enabled or at least a subsite for testing.

    the wp-login.php page leads to yoursite.com/wordpress/wp-login.php instead of just yoursite.com/wp-login.php.

    Check it out right now to see if I am even a user to just the yoursite.com site. If I am see that I am even have a forum role like participant.

    The redirect to the home page is because of some piece of code in bbPress for the frontend login forms. You can easily fix this by setting it where Admins can go the Admin and other users redirect to the home page using the plugin you have already installed.

    mvaneijgen
    Participant

    I have a small problem. I want to show the most popular topcis on my home page, but now I am running for a while and this feature is kinda killing my SEO performance. This is because there is one topic fairly popular on my forum and has been for over a few months now and because this is represented on the home page Google has picked up on it and this topic is showing up in most of my test search results.

    Now I still want to have this feature, but make it a bit more fair for the other topcis and show the most popular topcis that has stated in the previous few days (lets say 30). Is there a shortcode/feature or function that could achieve this?

    #167658
    #167652
    trusso
    Participant

    Site: http://www.levelupsolutionscenter.com
    Theme: ZippyCourses by Social Trigger
    Wordpress: Latest release
    bbforums: 2.5.8 (Latest)

    I have installed the plugin for bbforums. No issues setting it up. I have created a post that I want to remain at the top of the forum. It is titled, Getting Started. I made it ‘sticky’ believing that this would allow it to be there at the top regardless of what others put in the forum.

    When I go in to test as a user who has purchased a course, the user can get to the forum but cannot see the sticky post content. Just the listing in the forum. I set access to participant and open, with automatic membership.

    I read your documentation and created a forum registration page and put in your shortcode.

    Do users need to register with the forum first to see the content of a post?
    If they do and I have the registration page, I can put it in the menu. Is that what I need to do to get registration to people? Is there anything special I need to know to make registration go through and access be granted? Special in setting up the access page?

    Question really is: how does a user of the educational material get to see the forum questions/posts?

    Thank you!

    #167648
    mica123
    Participant

    Yes, I am testing this as myself, and two different users (one as editor, moderator and the other one just as participant). The same thing. I’ve tested this on both laptop and netbook at home in FireFox, Chrome, IE and Safari – all the same.
    I have to point out that I get this on the live site but not on the site I have on my local computer – it is the same setup which I tested before I set it up on the live site as well.

    #167645
    mica123
    Participant

    Just to let you know that I was testing it all day. I removed Robkk’s redirect code to see if there would be the same problem with Peter’s Redirect plugin and it is the same. So I am at my wits’ end.

    Pascal Casier
    Moderator

    Hi Barbara,

    First principle: test before going live !

    I have my own procedure on cleaning bbPress in case of failure, but let me check if there is an official one. @Robkk any ideas ?

    Pascal.

    barbarabax
    Participant

    Hello Pascal, i didn’t test locally so is live environment. BBpress 2.5.8 and wordpress 4.3.1
    We are talking about 2079 discussion with 17.000 replies
    Thanks

    Pascal Casier
    Moderator

    Hi Barbara,

    Is this a life system ? Did it work correctly in your test environment ?
    What version of bbPress and WordPress are you using ?
    How many lines are you talking about ?

    Pascal.

    #167614
    mica123
    Participant

    I don’t think this is the local caching problem because I tested it on both my laptop and netbook at home. I don’t have this problem when I test it on my site which I set up locally on my computer in xampp. This happens only on the live site.
    I don’t think this is related to your redirect code. So this is a huge unexpected setback – what a shame! It doesn’t seem there is an easy solution and that I have to battle it out with the webhost provider who may not be knowledgeable about this at all.

    #167607
    laberkopp
    Participant

    Thanks @robkk I may come back to your suggestion.


    @all

    I just tested the solution from @robin-w where @cassiepa pointed me to and this works very nicely for me. It is already active and seems not to influence other parts of my site. You can try if you like (link in first post 🙂

    What I like on that solution, is that I just need to add two files and do not need to edit and replace an existing file.

    Let’s see what will happen when I need to update the theme (if subfolder and files keep untouched, I mean).

    But for now I am yery happy. This was easier than I’ve feared 🙂

    Thanks a lot to all of you! I love communities 🙂
    Best wishes,
    Sascha

    #167575
    mica123
    Participant

    Actually,I may be getting somewhere. When I log in as admin, it gets me to the backend, then I type the address mysite.com/forums – then I see that I am not logged in. However, when I type in: mysite.com/forums/community – then I am logged in on that page.
    I wonder if it has anything to do with the redirect I have in functions:

    function rkk_login_redirect($redirect_to, $request, $user) {
        return (is_array($user->roles) && in_array('administrator', $user->roles)) ? admin_url() : site_url('/forums/');
    } 
    add_filter('login_redirect', 'rkk_login_redirect', 10, 3);

    You can see that discussion I had with @robkk here

    I’ll do more testing tomorrow.

    #167573
    mica123
    Participant

    No, I am not in an enterprise environment. I am at home and I am testing the bbpress on the live site. I log in as admin or another user as moderator or another user as participant. It is the same. As it is now close to midnight, I’ll continue testing tomorrow and report back. I wonder if WordPress needs flushing its cache or something – never did it before. Just a thought.

    #167572
    DevynCJohnson
    Participant

    How can I prevent “nofollow” from being added to my internal links on bbPress posts? (I have the latest version of bbPress and WordPress)

    The “nofollow” attribute is being added to my internal links on my website (DCJTech.info). However, this issue only occurs on bbPress posts, but not WordPress pages. Here is an example of the problem (bbPress post) – http://dcjtech.info/topic/general-unixoid-topics/

    I have tried commenting out the below lines from ./includes/core/filters.php, but without success. I also cleared the cache (server and browser) and waited a minute before checking the page’s source code.

    add_filter( 'bbp_get_reply_content', 'bbp_rel_nofollow',   50   );
    add_filter( 'bbp_get_topic_content', 'bbp_rel_nofollow',   50   );

    I used ‘grep -r -e “follow” ./plugins‘ to find all code that may be inserting “nofollow”, and I also searched my theme and mu-plugins. In addition, I searched my SQL database (via phpMyAdmin) for “follow”. I did not find any plugin, setting, etc. that could be causing this problem. There were no “nofollow” attributes in the posts either. I also searched my plugins for “bbp_rel_nofollow”.

    I disabled “External Links” and commented out the previously mentioned bbPress code (and cleared the cache), but the “nofollow” attribute was still on my internal links.

    I thoroughly checked the WordPress codex website, forums (like https://bbpress.org/forums/topic/turning-no-follow-links-to-do-follow/ ), etc., but I cannot find a solution or cause.

    #167568
    Pascal Casier
    Moderator

    Guten Abend laberkopp,

    @robin-w

    I checked your profile picture and I think I have seen you before 🙂

    bbPress profiles are open by default to all, so also users that are not logged in could see your profile. I know Robin has made a quick patch for a previous version (http://www.rewweb.co.uk/bbpress-making-profile-pages-private/) but I’m not sure if it’s still valid for the current version.

    Some other (untested!) snippets can be found here: http://seventhqueen.com/blog/code-snippets/restrict-guest-users-from-accessing-buddypress-or-bbpress-pages.html

    Regards, Pascal.

    #167533
    nhanco
    Participant

    I not test with any role yet. But i’m just install bbpress plugin.

    #167532
    Robkk
    Moderator

    Have you been testing with any custom role and capability plugins?

    #167518
    Robkk
    Moderator

    Sorry guys was probably tired or something, I should have led you guys to this explaining how to deactivate plugins when you cannot get into the admin panel.

    https://codex.wordpress.org/FAQ_Troubleshooting#How_to_deactivate_all_plugins_when_not_able_to_access_the_administrative_menus.3F

    And @bdsand I should have led you to this for the blank screen, but I am glad you fixed it.

    https://codex.wordpress.org/Common_WordPress_Errors#The_White_Screen_of_Death

    As for this issue, bbPress shouldn’t behave like this during deactivation of bbPress.

    See if some of the steps from here can help you.

    https://codex.wordpress.org/Login_Trouble

    I am guessing you guys are both getting the same error notice like this.

    You do not have sufficient permissions to access this page

    • You may also want to see what is the url after you get the permission error, see if there is an extra query in the url like ?restricted or something.
    • Check in a different browser to see if you get the same issue.
    • Check in a different user with a different user role(make sure you create a test user before deactivating bbPress)

    You guys can also test out your themes and plugins in a local test site/test server on your computer to see if you can duplicate the issue there.

    Creating a Test Site

    #167510

    In reply to: reCaptcha question

    Pascal Casier
    Moderator

    Hi,

    First of all, don’t mix the goals of the plugins. Your initial question is about wp-login, so Wangguard and TML are dealing with that.
    If you deviate on Antispam Bee and Akismet, then you more talk about checking what is posted, not the posters.

    Wangguard is free and SHOULD remain free for small non-profit organizations. See FAQ (https://www.wangguard.com/faq) WangGuard is free during these first months after our launch around the world. Later it will continue to be free for all users with personal blogs that do not exceed 200€ per month in revenue or 6,000 requests per month.

    I did not see a specific support question that indicated that Antispam Bee did not work with bbpress, but I never tested.

    Pascal.

Viewing 25 results - 3,226 through 3,250 (of 11,606 total)
Skip to toolbar