• I installed gamerz wp-print i got it working with posts but it does not work with pages of my website.

    is it possible to make it work for all the pages of the website or does it apply only to posts

    thanx

    julius

Viewing 15 replies - 16 through 30 (of 41 total)
  • ” The </IfModule> will check to make sure that you have mod_rewrite activated, you have it activated/installed, it should not pose a problem. “

    Oh ok, I was just curious cause it looked like all the others were above that tag, hehe. =)

    ” Did you replace <BLOG URL> with your url to the wordpress folder. If your wordpress folder is in the root, it will be like this.
    ^archives/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/([^/]+)/print/?$ /wp-print.php?year=$1&monthnum=$2&day=$3&name=$4 [QSA,L] “

    [ slaps self ] Haha, damn…. no I didn’t… Sometimes while adding plugins I tend to overlook the little things like that, but I guess I was thinking that <BLOG URL> tag was a working call function already or something. Hahaha…I dunno..this tends to happen when I’m missing my usually daily dose of alchol. =)

    My blog is right in the root folder called: Blog so I’ll just do as you said above then, I’ll post an update about it if it works or not. Thanks for your replies. =)

    spencerp

    P.S. Also, I already added this in the wp-print.php file as well, don’t need any problems with people coming in from google searches and what not lol.
    <meta name=”robots” content=”noindex,follow” />

    Well, like I said, I was going to post an update either way and the 500 errors went away. But for some reason yet, I’m getting the 404 error page after clicking the “Print this Article” link. Here below is what I tried.

    1) RewriteRule ^archives/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/([^/]+)/print/?$ /wp-print.php?year=$1&monthnum=$2&day=$3&name=$4 [QSA,L]
    2) RewriteRule ^archives/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/([^/]+)/print/?$ /blog/wp-print.php?year=$1&monthnum=$2&day=$3&name=$4 [QSA,L]
    3) a href=”<?php the_permalink(); ?>print/”>Print This Article
    4) a href=”<?php the_permalink(); ?>/print/”>Print This Article

    The only thing I didn’t do exactly was:
    // Open wp-content/themes/<YOUR THEME NAME>/index.php

    Find:
    ——————————————————————
    <?php while (have_posts()) : the_post(); ?>
    ——————————————————————
    Add Below It:
    ——————————————————————
    a href=”<?php the_permalink(); ?>print/”>Print This Article

    I had added the “print link” into the coding for right underneath the post instead of having it show above the post. Like here below:

    <p class=”postmetadata”><img valign=”middle” src=”<?php bloginfo(‘stylesheet_directory’); ?>/images/file.gif”/> Posted in <?php the_category(‘, ‘) ?> | <?php edit_post_link(‘Edit’,”,’|‘); ?> <img valign=”middle” src=”<?php bloginfo(‘stylesheet_directory’); ?>/images/file.gif”/> a href=”<?php the_permalink(); ?>print/”>Print This Article
    <img valign=”middle” src=”<?php bloginfo(‘stylesheet_directory’); ?>/images/comments.gif”/> <?php comments_popup_link(‘No Comments »’, ‘1 Comment »’, ‘% Comments »’); ?>

    If you want, just click my Blog link on the user name in sidebar here and you’ll see it below the post. =) I’m not really sure of the position of the print link would screw it up, but who knows… =)

    spencerp

    P.S. I removed the < a > and < / a > tags so you can see it better. Also, the Blog folder was in the root folder, so I made the /blog/wp-print.php changes to the htaccess file. Yet, I still can’t figure out why it wasn’t working for the print link, it takes me to the 404 page. =( Dang, I wish I had some beer or vodka, this usually helps me in these situations lol!!

    Hi, I check your site, I notice the link is abit wierd
    1) http://vindictivebastard.net/blog/twisteds-memory-lane-up-in-a-blaze.htmprint/

    How come there is a .htm at the back of the link?

    2) I tried: http://vindictivebastard.net/blog/wp-print.php?name=twisteds-memory-lane-up-in-a-blaze

    And it works, your pemlink is slightly different for the default.

    3) Try this
    RewriteRule ^blog/([^/]+)/print/?$ /blog/wp-print.php?name=$1 [QSA,L]

    4) try removing the .htm in the url bar if it doesnt work

    Oh, I’m using this for posts with the nice permalinks. /%postname%.htm I did that so it would be seen by google as an htm or html page rather then the pg=1 or whatever for posts.

    I guess I could try that once….just liked the .htm ending though. =)

    Here’s the part of the htaccess file with the .htm codes included:

    RewriteRule ^([^/]+).htm/trackback/?$ /blog/index.php?name=$1&tb=1 [QSA,L]
    RewriteRule ^([^/]+).htm/feed/(feed|rdf|rss|rss2|atom)/?$ /blog/index.php?name=$1&feed=$2 [QSA,L]
    RewriteRule ^([^/]+).htm/(feed|rdf|rss|rss2|atom)/?$ /blog/index.php?name=$1&feed=$2 [QSA,L]
    RewriteRule ^([^/]+).htm/page/?([0-9]{1,})/?$ /blog/index.php?name=$1&paged=$2 [QSA,L]
    RewriteRule ^([^/]+).htm(/[0-9]+)?/?$ /blog/index.php?name=$1&page=$2 [QSA,L]

    Maybe that could also help for future reference or something, if someone else uses this same setup for posts. Would be kinda cool to get this working with the .htm on the end lol. =)

    spencerp

    P.S. I tried number three there and it didn’t work, also tried removing the .htm for the posts /%postname%.htm <- there and got a 404 within the blog. Also, tried some other stuff with the htaccess file and nothing…so…I’m not really sure now lol. This is kinda of interesting and would be awesome if we could get this working with my setup for .htm endings though….hehe. Weeee!! =)

    I will try my very best to get it working. LOL. It is challenging, I love challenging jobs =)

    Try this:
    RewriteRule ^([^/]+).htm/print/?$ /blog/wp-print.php?name=$1 [QSA,L]

    It should work. Put this after #END WordPress

    For the link try this
    <a href="<?php the_permalink(); ?>print/">Print This Article</a>
    or
    <a href="<?php the_permalink(); ?>/print/">Print This Article</a>

    I cant remember which one. LOL memory failing me.

    Hey GamerZ

    Could I ask you to please valid the following. For some reason the wp-print doesn’t work on my posts anymore.

    I swear I haven’t touched ANYTHING! 🙂 but I keep getting typical browser 404 error when I click the link

    RewriteRule ^([^/]+)/([0-9]+)/print/?$ /wordpress/wp-print.php?name=$1&p=$2 [QSA,L]1</code>

    html
    <code><p id=”filedunder”>Filed under: <?php the_category(‘,’); ?> | print/”>Print This Article`

    Thanks so much for your time and help. Really appreciate it.

    Kate

    hi there, dont mind you put your codes between backicks and not

    Is there a site I can see?

    YES!! It works! It really really works!! Hahaha!! Thanks so much GamerZ!! =) Maybe you could use this in the next release of the plugin or even update the readme.txt about that… hehe. Just figured after all that playing around and experimenting, would be worth the adding, to the readme file lol.. =)

    For getting the WORDPRESS PRINT PLUGIN working on the following Permalink Structure, please read below:

    For those using a Permalink Structure of just this: /%postname%.htm

    // Open root WordPress folder

    Put
    ——————————————————————
    wp-print.php

    // Go to Manage > Files > Common -> .htaccess (for rewrite rules)
    // Note: If you ARE using nice permalink url
    Find:
    ——————————————————————
    # END WordPress
    ——————————————————————
    Add Below It:
    ——————————————————————
    RewriteRule ^([^/]+).htm/print/?$ /your blogs name/wp-print.php?name=$1 [QSA,L]
    ——————————————————————

    // Open wp-content/themes/<YOUR THEME’S NAME>/index.php

    Find:
    ——————————————————————
    <?php while (have_posts()) : the_post(); ?>
    ——————————————————————
    Add Below It:
    ——————————————————————
    < a href=”<?php the_permalink(); ?>/print/”>Print This Article < / a
    ——————————————————————

    P.S. Remember, no spaces between the ( < and A ) and remember to add the ( > ) tag for the end. Please don’t forget to make sure the [a href] tags are right on the front and end.

    Thank God it’s working now, thank you so much again GamerZ! =) Here’s a link to a working print topic page.
    http://vindictivebastard.net/blog/inregards-to-the-print-link-below-posts.htm/print/

    spencerp

    To Kafkaesqui:

    “Or if a theme has single.php and page.php templates, use the different print link versions for each (i.e. ?page_id= for page.php, ?p= for single.php).”

    I am also trying to get wp-print along writing not only posts, but also pages, but think im to new to understand the PHP-thing here.

    Im using permalinks – what should I put in single.php and page.php? If I only put

    <a>print/">Print This Article</a>

    after the usual

    ...ile (have_posts()) : the_post(); ?>

    its not working (Not Found).

    I am really trying to catch up here. ;o)

    spencerp: glad it is working. No Problem!

    lonetrotter: Is there a site I can see? Read the last portion of the readme regarding pages. You can put it in single.php

    Sure GamerZ! Its in swedish though… But < a href=”http://www.cogito.nu/”>here it is.

    I’ve read your Read me – and as I understood it the last part was only for peole not using permalinks (I do).

    “// Note: If you ARE NOT using nice permalink url
    // Open wp-content/themes/<YOUR THEME NAME>/index.php
    Find: […]”

    I dont know if this is important at all, but – I’ve used your wp-print before, and added the old rewriterules in the .htaccess as they where before. Now when I tried to add the latest RewriteRule after # END, something happened and the hole sigth disappeard – so I skipped that latest rewriterule. If that could something to to with anyting you can get my htaccess and unzipit < a href=”http://www.cogito.nu/copy.htaccesscopy.zip”>here

    Sure GamerZ! Its in swedish though… But here it is.

    I’ve read your Read me – and as I understood it the last part was only for peole not using permalinks (I do).

    “// Note: If you ARE NOT using nice permalink url
    // Open wp-content/themes/<YOUR THEME NAME>/index.php
    Find: […]”

    I dont know if this is important at all, but – I’ve used your wp-print before, and added the old rewriterules in the .htaccess as they where before. Now when I tried to add the latest RewriteRule after # END, something happened and the hole sigth disappeard – so I skipped that latest rewriterule. If that could something to to with anyting you can get my htaccess and unzipit here

    Hi there,

    The printer friendly page looks ok to me

    http://www.cogito.nu/2005/11/16/clive-hamilton-forelaser-den-24-november/print/

    Just dl the latest wp-print.php and overwrite it with your old one that is all, you do not need to touch/edit any files

    Yes – for that part its even GREAT – again thanks a lot for that plug GamerZ (and I have already replaced the PHP-file actually).

    The part im after though is to get PAGES to be writable (not posts). If you look at this page for example. At the bottom where it says “utskriftsvänlig version”

Viewing 15 replies - 16 through 30 (of 41 total)
  • The topic ‘wp-print problem’ is closed to new replies.