Forum Replies Created

Viewing 15 replies - 121 through 135 (of 151 total)
  • After looking into the source code of the plugin, that constant is defined at the top of it, so it might be fine to define it in your functions.php file.

    For example:

    define('PMPRO_LPV_LIMIT', 100);

    Alright, I came up with a more complex CSS. After you apply it, it will look like this (chrome):
    Screenshot

    .two-columns .homepage_pane {
        width: 33% !important;
    }
    
    h3.post-title {
        width: 100%;
    }
    
    h3.post-title a {
       margin: 0;
    }
    
    .homepage_pane {
        text-align: center;
    }
    
    .homepage_pane > a {
        display: block;
    }
    
    .homepage_pane img {
        float: none;
    }
    
    .clearfix:before {
        display: none;
    }

    If it is not what you wanted, let me know ?? Happy New Year!

    Well, you can center the text which is wrapped in the <a> easily by making it being displayed as block but then other things start to break (there are no longer 3 columns on each line). This is the code for it:

    h3.post-title a {
        text-align: center;
        margin-left: 0;
    }

    I’m not familiar with all your css so if you know how to fix this next issue, good. I’m going to try to come up with something too.

    It would be nice if you could provide a screenshot with an arrow pointing to the text you want to be centered. Otherwise I would have to guess.

    Reading from the Child Themes Codex, we get this information:

    […] your child theme can override any file in the parent theme: simply include a file of the same name in the child theme directory, and it will override the equivalent file in the parent theme directory when your site loads. For instance, if you want to change the PHP code for the site header, you can include a header.php in your child theme’s directory, and that file will be used instead of the parent theme’s header.php.

    Extra care must be taken when modifying functions.php file. If you create a new functions.php in your Child Theme’s directory, it won’t override the functions.php from the Parent Theme, but loads in addition to it — and that’s a good thing. Child Theme’s functions.php is loaded before Parent Theme’s functions.php so you even can override functions in the Parent Theme’s functions.php. However, functions located in that file must be firstly prepared to be overridden by a function with the same name from Child Theme’s functions.php.

    It is usually done by wrapping the function in an if clause such as:

    // functions.php — Parent Theme
    if ( ! function_exists( 'my_function' ) ) :
    
    function my_function() {
    }
    
    endif; // my_function

    That means that the function my_function() should only be defined if it has not been defined earlier (for example, in Child Theme’s functions.php as they are loaded before)

    How is it not working? When I’m trying to use the searchbar at the top right corner of your site, it finds articles.

    Forum: Hacks
    In reply to: Query return codes

    Assuming you mean using WP_Query class to query posts for example, the best way of getting this information is either reading WP_Query Codex and/or looking into the source code of WordPress (file wp-includes/query.php or query.php on WordPress SVN repo).

    For example, function query_posts() returns array of posts when successful or an empty array if there are no queried posts (as far as I can see from the source code).

    After a bit of googling I stumbled upon an interesting topic about this:

    How to switch language in WordPress “on-the-fly”

    Forum: Fixing WordPress
    In reply to: copyright date

    Oh yes, you are right. I always forget about using Child Themes.

    Glad it helped you ??

    Rasto

    Forum: Fixing WordPress
    In reply to: copyright date

    You can open and edit footer.php located in your theme’s directory. It should be located there.

    That’s what I needed! Have you noticed the class single-tickets in the <body>‘s classes? That’s very helpful. As far as I can see, that class is added to the <body> only when viewing a single ticket’s details. The only thing we need to do is to add this piece of css at the bottom of your style.css file:

    .single-tickets #main-nav {
       display: none;
    }

    Give it a try and let me know the result.

    If it is WordPress, it should be some kind of Page, how else would the resulting HTML be generated? ??

    I understand that it’s not a single page. That was just an example how you can conditionally do stuff. We need to identify from where it is being generated.

    Can you give me the ticket’s page <body> as a code snippet here? Not from the code but from the generated HTML. Just that one line (<body class="bla bla" [...]>)

    It is grabbing that old URL from somewhere. Look at the theme’s options and all the places where this could be set.

    Three instances of that caliber (2000 visits per day) running on 1 GB of RAM is quite a lot IMO (with all the other things). HHVM likes to cache a lot of stuff and it takes some RAM. I don’t have a comparison between PHP 5.6 vs HHVM 3.4 RAM usage at my disposal.

    I’m using a local provider (vpsfree.cz, Czech Republic and Slovakia) which gives me 4 GB of RAM by default so I have plenty of it (= that’s why I’m not much concerned with it).

    The best thing you can do is test it yourself and see if it is worth it.

    All in all, I think that until PHP 7 doesn’t arrive, HHVM is the best option we have.

Viewing 15 replies - 121 through 135 (of 151 total)