Forum Replies Created

Viewing 15 replies - 1 through 15 (of 140 total)
  • Thread Starter Tranny

    (@tranny)

    @thelmachido it would appear that I wasn’t reasonably specific to make it clear what it is that I seek and I just wasted your time. I apologize for the lack of clarity in the previous response.

    I wasn’t in fact looking for a way to make part of a paragraph bold, but rather the text which precedes the displayed tags. You helped me to remove the author’s name. With the author’s name removed, all that’s shown after the content of the single post are the tags. There is command in the CSS file which displays the text string “Tags: ” which is then followed by actual tags (which are added to the post when the post is being written). The CSS code which displays the text string is:

    .single .tags-links::before {
        content: "Tags: ";
    }

    I would like to display this text string in bold. This text string is not part of a paragraph and by adding the <strong> HTML tags to the CSS code all I achieve is that the HTML code is displayed as part of the text string. Was this explanation clearer as to what it is I’m after?

    Thread Starter Tranny

    (@tranny)

    @thelmachido thank you. That worked ??

    Would you happen to know how to display the word “Tags: ” in bold? Putting it between the <strong> tags just displays the tags as well. Obviously, it displays whatever is between the parentheses, which makes it trickier to figure out.

    Thread Starter Tranny

    (@tranny)

    @zoonini thank you. I think I just needed to hear that to get out of the endless loop of failure I was trapped in. I did scrap the css file and went back to start over with your previous advice. So now my file contains the following code:

    .single .post-thumbnail {
      display: none;
    }
    
    /* Move post meta from left to below posts, expand all to fill column */
    @media screen and (min-width: 61.5625em) {
        body:not(.search-results) article:not(.type-page) .entry-footer,
        body:not(.search-results) article:not(.type-page) .entry-content {
            float: none;
            width: 100%;
        }
    }
    
    body:not(.search-results).single article:not(.sticky) .posted-on,
    body:not(.search-results) article:not(.type-page) .entry-footer .avatar {
        display: none;
    }
    .single .byline {
        margin-top: 15px;
    }
    .single .byline::before {
        content: "Posted by: ";
    }
    .single .tags-links::before {
        content: "Tags: ";
    }

    This did the trick. Seeing the margin-top: 15px; command, I presumed it controlled the margin above the Author/Tags field and changed the value, which increased the margin more to my liking (it’s not so tightly packed together now). Thank you so much.

    While still dealing with this bit of CSS code, if I were to remove this bit:

    .single .byline::before {
    content: "Posted by: ";
    }

    Would it remove the whole “Author” part? Is it safe to do, or do I need to do more mods to get rid of the author mention all together (maybe replace it with a long dash, to separate the Tags from the Content better)?

    EDIT: I tried it – it removed the words “Posted by:”, but the hyperlinked username remains. Another bit that’s a bit above my paygrade level to resolve :/

    • This reply was modified 1 year, 7 months ago by Tranny.
    Thread Starter Tranny

    (@tranny)

    @mrfoxtalbot I added your suggested code into my child theme’s CSS file, and stripped the code from the functions.php you suggested could be a cause of concern, leaving just the base code behind, but I’m having a hard time understanding what this code was actually supposed to achieve.

    I thought that maybe it will achieve what currently is done with the index.php file, but when I removed the file from the server, I lost the current styling of the blog posts page.

    From what I could visually observe, the only change it’s done is move the author and tags to the top of individual posts – which is not really what I wanted to achieve. Not sure whether it’s from the addition of the code to the CSS or from removing the code from the functions.php file.

    The entries in the CSS file are not very clear to me in the their names as to which one is which and how to work with them. I swapped the 1 and 3 numbers with each other, but didn’t observe any change.

    Would you be willing to cast some light into this for me?

    • This reply was modified 1 year, 7 months ago by Tranny.
    Thread Starter Tranny

    (@tranny)

    @mrfoxtalbot Thank you so much for your input. I’m presently away, but will try your CSS suggestion as soon as I’m back on the computer.

    When you said “the first snippet you shared and it will cause your site to crash.” – did you mean the code I have in the functions.php file? What should I revert it into should that be the case?

    I apologize for stuffing too many questions into one thread. Once I’ve resolved the primary issue, I will follow your direction and open a new thread with a relevant title for easy lookup by future WP users.

    Thread Starter Tranny

    (@tranny)

    @zoonini you’re just totally amazing. Not only are you a great asset to the WordPress community with your willingness to help, but you also get everything right the first time. Thank you so much.

    I don’t mean to be an advantage taker, but since you’re clearly second to none in your WP themes expertise, would you be willing to also review the code I plastered together on my own from research I could find on the internet? My primary concerns are to make sure I did not mess something up too badly, that I did not add unnecessary code that would needlessly call on too many resources, and while I somewhat achieved the desired effect, I also broke a few things. Here’s what my child theme’s functions.php file looks like:

    <?php
    add_action( 'wp_enqueue_scripts', 'enqueue_parent_styles' );
    
    function enqueue_parent_styles() {
       wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' );
    }
    function twenty_sixteen_child_setup() {
        // Add custom excerpt function
        remove_filter( 'get_the_excerpt', 'wp_trim_excerpt' );
        add_filter( 'get_the_excerpt', 'twenty_sixteen_child_custom_excerpt' );
    
        add_action( 'wp_head', 'twenty_sixteen_child_excerpt_width' );
    }
    add_action( 'after_setup_theme', 'twenty_sixteen_child_setup', 11 );
    
    function twenty_sixteen_child_custom_excerpt( $text ) {
        global $post;
    
        $text = '';
    
        if ( has_excerpt( $post->ID ) ) {
            $text .= get_the_excerpt();
        } else {
            $text .= wp_trim_words( get_the_content(), 55 );
        }
    
        $text .= '<p><a href="'. get_permalink() .'" class="more-link">'. __( 'Read more', 'twenty-sixteen-child' ) .'</a></p>';
    
        return $text;
    }
    ?>

    And here’s my index.php file:

    <?php
    /**
     * The main template file
     *
     * This is the most generic template file in a WordPress theme
     * and one of the two required files for a theme (the other being style.css).
     * It is used to display a page when nothing more specific matches a query.
     * E.g., it puts together the home page when no home.php file exists.
     *
     * @link https://developer.www.ads-software.com/themes/basics/template-hierarchy/
     *
     * @package WordPress
     * @subpackage Twenty_Sixteen
     * @since Twenty Sixteen 1.0
     */
    
    get_header(); ?>
    
    	<div id="primary" class="content-area">
    		<main id="main" class="site-main">
    
    		<?php if ( have_posts() ) : ?>
    
    			<?php if ( is_home() && ! is_front_page() ) : ?>
    				<header>
    					<h1 class="page-title screen-reader-text"><?php single_post_title(); ?></h1>
    				</header>
    			<?php endif; ?>
    
    	<?php
    		// Start the loop.
    		while ( have_posts() ) :
    			the_post();
    	?>
    
    		<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    			<header class="entry-header">
    				<?php the_title( '<h1 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h1>' ); ?>
    			</header><!-- .entry-header -->
    
    			<?php if ( has_post_thumbnail() ) : ?>
    				<div class="post-thumbnail">
    					<a href="<?php the_permalink(); ?>" aria-hidden="true"><?php the_post_thumbnail( 'post-thumbnail' ); ?></a>
    				</div><!-- .post-thumbnail -->
    			<?php endif; ?>
    
    			<div class="entry-summary">
    				<?php the_excerpt(); ?>
    			</div><!-- .entry-summary -->
    
    		</article><!-- #post-<?php the_ID(); ?> -->
    
    	<?php endwhile; ?>
    
    	<?php the_posts_navigation(); ?>
    
    <?php else : ?>
    
    	<?php get_template_part( 'template-parts/content', 'none' ); ?>
    
    <?php endif; ?>
    
    		</main><!-- .site-main -->
    	</div><!-- .content-area -->
    
    <?php get_sidebar(); ?>
    <?php get_footer(); ?>
    

    Basically, my goal was to show the featured image followed by an excerpt, because Twenty Sixteen by default shows whole posts on the index page.

    I more or less achieved that goal, but by doing so, the font of the excerpt changed, and quite frankly, I like it better than what’s in the actual post and wouldn’t mind changing the font into that for all posts, pages and attachments.

    Secondly, the pagination on the index page changed as well. Twenty Sixteen has quite cool default pagination which I liked, but after my tweaks, the pagination changed into that less cool “Older posts” and “Newer posts” links. I have no idea how to bring the default pagination back.

    And lastly, the index page no longer shows footer widgets. They still show up on other pages (expectedly, since I didn’t tweak those), but do not appear on the index page. I somewhat got around it by replacing the credits text in the footer with the Warning text I had in the footer widget, but should I need to use a different widget, it would still not show up on the index page.

    Here’s the index page: https://www.markmarek.com/articles/ (NSFW)

    You already helped me a lot and I know I’m probably pushing the envelope a little too far now, but if you could help me with any of my remaining concerns, I’d sincerely appreciate it. At least by reviewing the code to make sure there is nothing redundant, or even of concern there, despite the front end seemingly doing what I was after. But if you could also suggest tweaks that would help me apply changes I’d like to see, that would be exalting.

    Thank you a thousand times… :o)

    Thread Starter Tranny

    (@tranny)

    OMG @zoonini, I’m actully quite embarrassed at how this simple code did it. I spent a lot of time trying to tweak various codes with my limited knowledge, and always hit the wall, and yet it could have been with a little tweak to the CSS file, hehe. Thank you so much.

    Might I also be this bold and ask you for additional help styling the data moved to the end of the content? I wouldn’t mind having the Date completely removed, and a word “Tags: ” placed in front of the tags, so it’s clear what that is as right now it’s all just lumped there one under the other.

    Maybe even remove the avatar and add text before the author’s name saying “Posted by ” then the author’s name, followed by a comma and the text “Tags: ” followed by the tags.

    Could this be done equally easily by tweaking the CSS file?

    You are the best, by the way. Thank you so much :o)

    Thread Starter Tranny

    (@tranny)

    Thank you for responding @zoonini

    As you noted, I’ve done some changes of my own, but they’re all quite rough around the edges, and with some I achieved a desired result, but broke something else. So it’s still very much works in progress for me.

    What I’m totally falling short of is the ability to move the Author, Date and Tags to the end of the content, so it doesn’t take up the space to the left of the content (its default location). I’m simply not good enough to work this out on my own. Is that something you could help me with?

    Eventually, if the move of these is successful, I’d like to stretch the width of the content to full available space (filling up the space currently used by the Author, Date and Tags).

    Would really appreciate some help with this. An example link of a single post page which (as all posts) still has the Author, Date and Tags in the column to the left of the content is (NSFW link):

    https://www.markmarek.com/photography/articles/history-culture-significant-nude-photography-different-part-of-world/ (NSFW)

    Thread Starter Tranny

    (@tranny)

    @wpexpertssupportteam I appreciate the care. I can now report that my webhost changed autoload for mycred-cache-keys to NO, and the server load came down so my site is responsive again. Unfortunately it took me 5 days to narrow the issue down, so it was very stressful 5 days when nomatter what I did, the DB server would always time out.

    I’m still hoping you can follow up with the instruction on how to properly remove the orphaned records from the database.

    Thread Starter Tranny

    (@tranny)

    @wpexpertssupportteam thanks for responding. I used the latest version of the plugin, updated 2 weeks ago to 1.8.12. Somehow it seems to me as though it was this latest update that sent things spiriling out of control, as after a few years of use, this was the first time it happened that it would cripple my database.

    As I said earlier, I had deactivated the plugin, but since then, I also deleted it in hopes that the deletion would remove the bloated mycred-cache-keys section of the database. Unfortunately, the 76MB of data was left in the database after the deletion of the plugin.

    I have requested my host to change the autoload setting in the database to NO, but still waiting for them to do it, because I have no direct access to the database.

    Still, my question remains – how can I get rid of it properly from the database, especially now after I have already deleted the plugin.

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

    (@tranny)

    @yehudah thank you so much for responding.

    That’s indeed the plugin. I have it installed and have all emails to the administrator disabled. I recently installed your plugin, which is great, but I go get those emails to the administrator, such as new user notification, password change notification, etc. I see them in Email Log of your plugin being shown as “Sent” to the administrator email.

    Is it me who’s doing something wrong?

    • This reply was modified 5 years, 1 month ago by Tranny.

    I have the same problem, and it is not isolated to specific installation or plugins, because it happens on all 3 of my sites. The problem started with upgrade to 4.6 and I posted about it in the forum, but it got deleted.

    I only upgraded my least important site to 4.6 and because it made it unusable, I did not go with the upgrade on my more important sites. I waited for the next update, thinking this owuld be fixed, but it wasn’t, and now even my main site is unusable.

    Basically, since 4.6, there are two problems:

    1 – some form of over caching causes newly made posts/pages not appear, unless a CTRL refresh is done to the page.

    2 – creating new posts becomes impossible, because of some kind of conflict with post numbering in the database, so a guy goes to create a new page, but data from the latest existing post is loaded up, so if this new post is saved, it will overwrite the existing post. Whereas each attempt to create a new post loads up an ID of an existing post, one can’t create a new post without destroying the old one, so the options are either to not make new posts, or sacrifice the latest one for a new one as its replacement.

    Thread Starter Tranny

    (@tranny)

    https://www.miscopy.com (warning: graphic content)

    Computer restart and clearing off browser cache did nothing with the issue. I’m basically no longer able to publish any posts.

    [Moderator note: This site features upsetting and strong graphic content.]

    Forum: Plugins
    In reply to: [Comet Cache] Does Nothing?
    Thread Starter Tranny

    (@tranny)

    Thanks for your responses man. I appreciate every developer who puts time and effort toward making plugins. This one simply did not work out for me. I spent too much time trying to make use of it, but could not. If a plugin takes so much time to get going, and it doesn’t even go after that, it’s just not worth the hassle anymore.

    I’m saddened by W3 developer abandoning his plugin, which I used for many years, but obviously it’s time to go, especially since W3 still uses PHP rules that are no longer supported in PHP7. But with other caching plugins available, spending excessive amount of time trying to tinker one that just wouldn’t work doesn’t make sense. I got rid of it and moved on to a different one.

    Forum: Plugins
    In reply to: [Comet Cache] Does Nothing?
    Thread Starter Tranny

    (@tranny)

    I guess my issue was Cloudflare stripping notes from HTML, then (I did have those blank lines at the bottom). But that changes nothing on the fact that the difference between running with just Nginx and no caching plugin, and Nginx with Comet Cache is non existent. I run a very busy website with a lot of use activity on a dedicated server. When run without any caching plugin, my server load is in the neighborhood of 12. Activating W3TC keeps it around 1. Fastest Cache keeps it around 8. But Comet Cache around 12 – the same as with no caching plugin at all.

Viewing 15 replies - 1 through 15 (of 140 total)