Forum Replies Created

Viewing 15 replies - 1 through 15 (of 22 total)
  • Forum: Plugins
    In reply to: Modify insert media links
    Thread Starter chowpay

    (@chowpay)

    aww com’on man.. someone has to of written a plugin that adds a rel= to image links or knows how?

    Thread Starter chowpay

    (@chowpay)

    Got it here is the proper link for anyone who needs it

    <img src=”<?php bloginfo(‘template_url’); ?>/images/myimage.jpg”>

    Thread Starter chowpay

    (@chowpay)

    the page that needs to be touched is archive.php. I’ll upload a better solution that filters by slugs rather than manually entering the category ID

    Thread Starter chowpay

    (@chowpay)

    Found the solution:

    https://guff.szub.net/2007/11/30/kinderlose/#comment-761952

    this plug-in works great!

    and does exactly what was described above

    Forum: Plugins
    In reply to: Side Bar category Filtering
    Thread Starter chowpay

    (@chowpay)

    bump.. com’on someone else had to of had this problem right?

    Forum: Plugins
    In reply to: Side Bar category Filtering
    Thread Starter chowpay

    (@chowpay)

    bump

    Anyone figure this out my slugs aren’t saving / allowing me to edit either ?? wp2.51

    Thread Starter chowpay

    (@chowpay)

    How do you exclude / include by slugs?

    Thread Starter chowpay

    (@chowpay)

    Ah yes nm got it..

    so simple it hurts

    just go

    wp_list_categories(‘orderby=name&show_count=0&include=1,2,3=&title_li=<h2>Apparel</h2>’);

    any only categories 1, 2 and 3 will ever display on that side bar.

    If theres a plug in for this that would be awesome…

    Thread Starter chowpay

    (@chowpay)

    Edit to above

    <?php if (is_category(1||2||3||4)) {include (‘sidebar2.php’); }..

    needs to be <?php if (is_category(array(1,2,3,4)) {include (‘sidebar2.php’); }..

    Thread Starter chowpay

    (@chowpay)

    Eh figured it out

    <?php if (is_category(1||2||3||4)) {include (‘sidebar2.php’); }..

    um I guess a better question would be is there a way to put an includes? so I dont have to type out that messy code.

    IE
    <?php if (is_category($excludeList) {include (‘sidebar2.php’); }..

    Thread Starter chowpay

    (@chowpay)

    Run in to a little php problem How do I do an OR statment to exclude multiple categories?

    Ie <?php if (is_category(n)) {include (‘sidebar2.php’); }
    else if (is_category(2)) {include (‘sidebar2.php’); }
    else {include (‘sidebar.php’); }
    ?>

    Lets say I want to exclude categories 1,2,3,4

    <?php if (is_category(1,2,3,4)) {include (‘sidebar2.php’); }
    else if (is_category(2)) {include (‘sidebar2.php’); }
    else {include (‘sidebar.php’); }

    how do I tell it to do something like IF is_category =1 or 2 or 3 etc etc then use ‘sidebar2.php?

    Thanks

    Thread Starter chowpay

    (@chowpay)

    AH hA!

    Got it so on the posts use custom sidebars:
    In case anyone needs this.. So its easy enough to make a custom sidebar appear depending on the page you are on. But the posts on the side bar of those pages will still link out to the original side bar because the data is being pulled from archive.php , or single that php.. Below is an example on how to exclude the category for archive.php but i’m sure it’s the same for anything else.

    1. this will remove the “Archive” text depending on the category oyu sepecify

    <?php /* If this is a category archive for category n */ if (is_category(n)) { ?>
    <h3><?php single_cat_title(); ?></h3>
    <?php /* If this is a category archive*/ }elseif (is_category()){?><h3>Archive for the ‘<?php single_cat_title(); ?>’ Category</h3>

    2. Most important this will define which side bar to use during your static content on the archives.php page.

    <?php if (is_category(n)) {include (‘sidebar2.php’); }
    else if (is_category(2)) {include (‘sidebar2.php’); }
    else {include (‘sidebar.php’); }
    ?>

    Thanks everyone, if there is a better solution, which im sure there is feel free to let me know or continue this thread!

    Thread Starter chowpay

    (@chowpay)

    actually its looks like its navigating to archive.php

    So I added this :<?php if (is_page(7)) {include (‘sidebar2.php’); }
    else}
    else {include (‘sidebar.php’); }
    ?>

    But I dont think the archive.php knows what page im on so instead it going straight to the sidebar.php instead of sidebar2.php

    Thread Starter chowpay

    (@chowpay)

    Ah that make sense, the problem was I just don’t know which file controls the posts. But yes thats exactly what I need to do.

    Do you have more detail on how this is done? because I can tell single.php to use the sidebar2.php but I dont know where to go to tell posts within single.php to use sidebar2.php.. does that make sense?

    Thanks

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