WordPress: Too many taxonomies slow down the site - php

I have a WordPress site with 30,000+ terms for Australian cities/states. Wordpress loads fine with fewer terms but 30,000 terms make it load forever.
I've disabled all the plugins and using the WP-2015 template. Is there a way to add such a huge number of custom terms and make the site work normally?

I have the exact same issue. It turns out the problem is the WordPress is very slow if you have many terms and the taxonomy is set to be hierarchical. Without this option the admin and frontend pages load fine.
It's an old issue from way back which I don't think WordPress can fix with their current database structure.
As a partial fix I improvise by making the taxonomy non hierarchical and set the parent/child relations as taxonomy meta. It only works in the front end where you have full control over the queries.

Is site slow at all places or just a set of pages? If so, which pages?
We have way more terms than you do and we have no problems. I assume that at certain places select queries take too long.
You can install plugin called Query Monitor which can show you what takes long, what triggers it and lots of other useful information which can help you locate and fix the problem

It's old question. The issue is (as #razvan said) for hierarchical because (mainly for administration pages), WordPress create a <select> tag for the selection of the taxonomy. But using non hierarchic taxonomies (like tags) works perfectly.

Related

Jooma 3.1 Templating - Tutorials/Documentation?

I am to develop a Joomla 3.1 Template. The template should consist of a static header and footer, as well as multiple pages, all of which need their own styling. Further, the client would like to be able to add 'events' to a specific listings page. Customers should be able to book said events via a simple form.
Thanks to some really basic guides, I have the header and footer down, as well as some simple template options. However, I am now running into some problems;
How would I approach the content section? Ideally, a page would consist of multiple, editable sections. The client would be able to edit said sections in the backend without having to deal with or accidentally changing the layout or styling of the page itself. Since there are multiple pages, I obviously need different views/containers for each of them. Is this possible and if so, how?
Another problem is the documentation, which I found to be very lacking. Even google only got me so far (basic structure, index.php, templateDetails.xml and so forth). Are there any other resources I may have missed or do I really need to refer to other templates (most of which, obviously, aren't free) and use var_dump all the time?
Writing this, I just realized that I could theoretically build a template for every single page but ... that surely can't be right, right?
If someone could provide a basic outline or at least tell me how you personally would tackle a project like this, it'd be very much appreciated.
All the best
Edit;
I just found some video tutorials but since my bandwidth is limited, I cannot watch them. Please take this into account when writing an answer. Thanks.
I have only one word for you :
GANTRY :D
gantry-framework.org
Joomla revolves around menu items that point to components. For each menu item, you can assign modules to different positions within the template to create a unique page. You only need one template if you really understand how Joomla templating works.
Joomla has very good documentation here - http://docs.joomla.org/
Few things to remember -
Component - this is a type of content or app of sorts. A component will define what content is and how it is displayed. This can be anything from blog articles and categories to an event registration system to a message board or social network. Menu items generally will point to a view in a component.
Modules - these are used to display additional content around the component output. This can be a menu, or a login box, or a weather widget or anything else you can come up with. Modules can be assigned to or excluded from the various menu items on your site.
Plugin - plugins are used to change the final output on a site. They can be used to insert Youtube videos, or forms within content, or even to alter the meta tags on a page.
Understanding how extensions work is an important first step. Once you get how those work, learning how templates and template overrides work will give you most of what you need to know to build a basic Joomla site.

Integrating simple PHP blogging system into existing website

I want to, create blog page in my website.
There are bunch of huge blogging platforms such as: Wordpress, Blogger ... But the problem is, they are offering a loads of unneeded functions. Of course, I can create simple blog. But it will cost a lots of time and I don't want to reinvent the wheel.
So what I need is, "core" functions of blogging system such as:
Adding, removing, editing posts, inserting attachments, images o posts
Pagination
I don't want to integrate wordpress because of reasons that I explained above.
Any suggestions?
I used cutewnews for a while when I was new to coding (http://cutephp.com) it's pretty much the same as a blogging system. Create posts, edit posts, archive posts, categories, template is very customizable, allow/block comments, require users to register in order to add comments, block IPs, WYSIWYG editor, etc. It's all done in the back end and then you add a few lines of code in your page and the posts will appear. You can also designate how many you want to display per page. It's simple but effective and free. I believe there is a link at the bottom of the script going back to http://cutephp.com/ but you should be able to find it and delete it. It takes about 2 minutes to install and get set up. You don't even need mysql. Will work with any php frame work or coding style as long as you have the ability to create your own blank page where you can plop the code.

Multiple hostnames for a single Wordpress blog to control displayed post categories

Wordpress related
Multiple hostnames for a single Wordpress blog to control displayed post categories
Can it be done?
If not, why not
Else, how may I? :3
I'm trying to maintain a single blog but only show posts from a particular category for a certain host name :/
I found http://codex.wordpress.org/The_Loop#Exclude_Posts_From_Some_Category but it's not going to change the domain in links, etc :/
Thomas - there are a few ways you could achieve this. If you want a solution that doesn't involve setting up a separate WP network for each hostname (assuming you're using WP 3.1), a neat way might be to rewrite the URL at the web server. WP already requires you to cofigure rewrite rules for pretty URL support, so there's no reason why you could internally map category.example.com into www.example.com/category. If you made all your site's links relative, this could work reasonably well.
Otherwise, I'd create a network for each hostname, and write a multi-site plugin that adjusts the WP_Query for any request received on a 'category' network, to retrieve posts from the main blog with a category filter. But you'd probably end up fighting WP every step of the way :-)
There may be a neater solution.

Beginner question on Drupal

I am new to PHP and am doing some research on Drupal system to set up a website for my church.
Just want to know how to development a module on a page that display a list of articles? eg. display the article by category or tag etc.
Is there any template I can use or I will need to develop the template myself?
Thanks in advance!
Chris
Check out the views module. It lets you define your own rules for viewing articles (or other content types), by tag, category, or any arbitrary conditions you can think of.
in complement to #DanSingerman good answer For category and tags you should have a look at Taxonomy and also SimpleView to get some less advanced user interface when building your views.
If you're only displaying articles, you should go with Wordpress. Most Drupalistas would probably recommend Wordpress over Drupal for this usage.

WordPress Mobile Pack Custom Page Template

Hoping someone can help.
I've inherited a WP based website which has WPMP already installed & activated & working on it (I can see it work on many pages).
I've had to create a custom template & a few pages that use this template. Unfortunately, when I switch to mobile mode (or check out the new pages on my iPhone), no posts show.
The custom template has to query for posts multiple times to display different groupings of posts in different places. I have a feeling these dynamic queries are removing the ability for WPMP to see any posts at all.
So the only thing I can think of doing is somehow "providing" WPMP the list of posts to see.
How do I do this?
Please help...
O8
I think that in your situation you best way will be to:
1. Upgrade wordpress to the lastest version.
2. Install http://wordpress.org/extend/plugins/wptouch/ - that will do all the work for you on mobile.
if you are having trouble fetch posts in mobile pack, then in custom temple, please run wp_query or SQL command to select all posts and declared a
Global $posts
and once $posts is populated then the regular commands which are used in the loop can be executed to show posts.
Are you using wp_reset_query after each loop?
http://codex.wordpress.org/Function_Reference/wp_reset_query
Use Firebug with Firefox, or Chrome's or Safari's or IE8's developer tools to see what's loading on your site and check for javascript errors and css conflicts.

Categories