Forum Replies Created

Viewing 4 replies - 1 through 4 (of 4 total)
  • Here’s how I solved this issue (assumes shell access):
    1. create a new group:
    $ addgroup wp-theme-editor
    2. change the group of the theme files and make them group writable:
    $ cd <theme-directory>
    $ chgrp wp-theme-editor *
    $ chmod g+w *
    3. add apache user into the new group:
    $ usermod -a -G wp-theme-editor www-data
    4. restart apache (otherwise the apache process doesn’t knows that it’s it in the new group)
    $ /etc/init.d/apache restart

    Using parentheses with require_once is optional.

    Hm, a code sample might better illustrate my question.

    Here’s an abbreviated bit of the template:

    <?php require_once 'fooversion.inc.php'; ?>
    <?php the_content(); ?>
    <?php edit_post_link('Edit this entry.' . get_foo_version(), '<p>', '</p>'); ?>

    and then the page appears (ignoring the sidebar):
    header
    content part
    content part
    Edit this entry 1.2.3

    So I can make the version number appear in the post link. But I want the version number to appear inside the page content like this:
    header
    content part
    Version 1.2.3
    content part
    Edit this entry

    In other words, I want the version number to appear within the page content and this is where I get stuck.

    I am getting the feeling that the only way to get this version number into the page content is with a php plugin or at least something like the Enzymes plugin.

    I’ve got a page where I want a frequently-changing version number to appear. I’ve created a page template and I can get at the version number in the template using require_once, but I’m stumped re: how to get this version number from the page template into the page content.

    If using a php plugin is the right way to do it then fine, just thought I’d ask if there was a better way.

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