i3
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Multiple WordPress blogsThere isn’t a built it way to do this, however, you can accomplish this with a little change to a blog template.
Here is what to do:
- Create two pages for each individual blogs.
- Create two categories with the same name as the pages
- Copy the blog template and name it ‘multi-blog.php’
- Open the template PHP file and change the title at the top to the new template. should look like
/*
Template Name: multi-blog
*/(this will make it show in the page templates)
-
Lastly we need to change the way it searches for posts. This is done further down in your new multi-blog.php file. Add the following two lines
$query_string = “&category_name=”.$post->post_title;
query_posts($query_string);before this line
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
It should look like this:
$query_string = “&category_name=”.$post->post_title;
query_posts($query_string);<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
- Lastly, assign this new template to the your blog pages by editing the page.
- Create posts under each category and they should show up blog.
What this does is display any post where the category of the post and page name are identical. In theory, if you had two blogger who wanted to share a post you could select both categories and the post is shared in-between them. I find this nice simple solution to cross referencing products by manufacture, usage, etc… pages.
Let me know if it worked for you! [email protected]
Forum: Plugins
In reply to: rewrite rule for custom query stringtry setting the permalinks in the settings.
Forum: Fixing WordPress
In reply to: Widget drag and drop issues v.2.8.4?No. Reinstalled fixed issue but generated anther.
Re-installed using godaddy’s application installer and I cannot create new or update post bodies. Text in these fields do not get saved… only the title gets updated. Weird. probably a godaddy issue.
Forum: Fixing WordPress
In reply to: Widget drag and drop issues v.2.8.4?I previously disabled all the plug-ins. I am using the default theme. It’s just weird.
I might go for a complete reinstall to see if it still exists. I’ll let you know.
Forum: Plugins
In reply to: Contact Form 7 – radio button questionsAdd this to your stylesheet.
“span.wpcf7-list-item { display: block; }”
Forum: Themes and Templates
In reply to: Posting a specific URL from a link or blogrollAgain, very little documentation.
Have do you used it before because I cant figure it out.
Forum: Fixing WordPress
In reply to: Link Category SortForum: Fixing WordPress
In reply to: Getting a category name from a post…?Forum: Fixing WordPress
In reply to: Getting a category name from a post…?Okay… I figured it out for those of you interested…
$cat_array = wp_get_post_categories($post->ID); foreach ($cat_array as $category) { if (cat_is_ancestor_of(18, $category)) //Check to see if its an ancestor { // If ancestor do something echo get_cat_name($category); } }
Forum: Fixing WordPress
In reply to: Getting a category name from a post…?I’ve looked at this function before but it doesn’t allow you to query categories based on a specific post. It allows you to use the ‘type’ parameter to return categories associated with post or links but not a specific post.
Any other ideas out there. This can’t be that hard….???
Forum: Themes and Templates
In reply to: Singlepost with menu on it???Okay, here is what I did and how the relationship works.
I setup the site up so pages are just pages. 4 of those pages list the products in different ways (manufacture, software, by type, by application). The products themselves are really posts. The page template was setup so it only displays posts where the page name and category match. (there is a category for every sorting method).
What this does is allows me to create one product post which can be sorted based on how the viewer wants to look at it. Site users can approach what their looking for from different angles. (i.e “let me see all TVs” or “Let me see all products from a manufacture”. I thought this was quiet ingenious because it allows my customer to maintain their products as posts. My customer is not e-commerce site due to the complexity and cost of the products the sell so I didn’t really consider an advanced commerce type of system.
So all said and done the sorting method works wonderful and the only kink in my plan is that loose page context when I viewer want to view the details of the product. I can’t build the context from the post because I don’t know which page “view” they came in through.
– Is there a carry state (such as what page did I just come from) which I can build logic to rebuild the menu?
– Is there an add-in would be better?Sorry for the book, but I hope it explains the “use case” for what I did, even if it wasn’t the best way of doing something.
Forum: Themes and Templates
In reply to: Singlepost with menu on it???test
Forum: Themes and Templates
In reply to: Singlepost with menu on it???esmi… here is the copy of the sidebar (Paste bin)
—- DESCRIPTION —-
to: esmi
from: I3
Re: Singlepost with menu on it???
—
Using wordpress, how do you get a menu function to display the last menu when a single post is invoked. My problem is that when you click on the post in a defined page, WP executes the single post and WP looses “page” context. How does someone get around this? Is there a way to maintain state without having a user login?Forum: Fixing WordPress
In reply to: Menu issue….Yes. I created a new page and assigned this template to it. That’s how I found out it isn’t working.
No, its not a top level page. But if I change the template for the page to default, the menu appears fine.