Moz Q&A is closed.
After more than 13 years, and tens of thousands of questions, Moz Q&A closed on 12th December 2024. Whilst we’re not completely removing the content - many posts will still be possible to view - we have locked both new posts and new replies. More details here.
Should WordPress themes be hard coded for better SEO?
-
In the interests of making my site faster I have recently come across the suggestion of removing unwanted PHP from my WooThemes WordPress theme. The suggestion is to hard code the choices I have made in the WordPress template to reduce on database calls.
Has anyone actually done this to their WordPress theme before and seen any measurable results?
-
Hey Ben,
Thanks. Am using a Wootheme called Simplicity. I have just left the minify box unchecked in W3 Total Cache since this was causing the problem. The site speed seems to be ok though even with this disabled.
-
Hi Sofia,
Not a problem, glad I can offer my assistance.
What slider are you using? I might be able to solve that problem for you, I know I had to fiddle with the code of my theme a little to make total cache behave but they were minor changes.
-
Ben, thanks for the useful follow up. I will certainly check out spitecow. Have found W3 total cache speeds up my site quite a bit, only problem is its breaks the image slider for some reason so have some looking into to do.
-
To help measure results one way or another you could use http://loads.in to test how long it takes your page to load from different geographical locations. I think Chrome's developer tools has a similar thing as well.
If you're trying to speed up your site then I would recommend grouping images (icons etc) into an image sprite and use css background positioning to show the respective image. I found that implementing this into a theme resulted in great speed increases as you make a single HTTP request for a single image, as opposed to loading up several images on page load.
If you're not savvy enough with css image sprites I would recommend using www.spritecow.com to produce the correct background-positions for the images so you can add them into your css file.
-
I have used WooThemes in the past and personally I think some of their code and their modifications are a bit overkill, sure it makes things easier for users but its not really following the way WordPress does things (Creating folders in WP-Content to put file uploads from their admin panel for example).
In general terms I think its better to hard code references to public resources (CSS Links, JavaScript links etc in header.php). For better speed increases I would suggest having links to JQuery or MooTools in header.php and any other JavaScript files should be put in footer.php just above the closing body tag.
The benefit to this is that the core JavaScript framework (JQuery or MooTools) is loaded first, the page can then render on the screen whilst the last few JS files are downloaded and put to use.
It maty be worth using WP SuperCache or similar to cache your pages and allow browser gzip compression for quicker page loading.
I think WordPress in general makes too many database calls anyway, so where possible I think its acceptable to hard code links.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Google Not Indexing Pages (Wordpress)
Hello, recently I started noticing that google is not indexing our new pages or our new blog posts. We are simply getting a "Discovered - Currently Not Indexed" message on all new pages. When I click "Request Indexing" is takes a few days, but eventually it does get indexed and is on Google. This is very strange, as our website has been around since the late 90's and the quality of the new content is neither duplicate nor "low quality". We started noticing this happening around February. We also do not have many pages - maybe 500 maximum? I have looked at all the obvious answers (allowing for indexing, etc.), but just can't seem to pinpoint a reason why. Has anyone had this happen recently? It is getting very annoying having to manually go in and request indexing for every page and makes me think there may be some underlying issues with the website that should be fixed.
Technical SEO | | Hasanovic1 -
Barba Plugin and SEO
Hello, community! My client wants to use the barba.js plugin for their new site. What are the implications for SEO?
Technical SEO | | SimpleSearch0 -
Schema for Banks and SEO
I'm researching Schema opportunities for a bank, but besides the shema markup available today (like bankorcreditunion) and developments with FIBO, I can find no answer as to the effect of tagging interest rates and such in terms of SERP/CTR performance or visibility. Does anyone have a case study to share or some insight on the matter?
Technical SEO | | Netsociety0 -
How to redirect 302 status to 301 status code using wordpress
I just ran the link opportunity option within site explorer and it shows that 31 pages are currently in a 302 status. Should I try to convert the 302's to 301's? And what is the easiest way to do this? I see several wordpress plugins that claim to do 301 redirects but I don't know which to choose. Any help would be greatly appreciated!
Technical SEO | | vmsolu0 -
Do Letters With Accents Affect SEO?
Hi Guys, My company has a franchise of a foreign company that uses an accent/foreign letter in its brand name. We have to refer to this franchise with this symbol on our website to meet their standards. I've done some research on this but its not conclusive, so i was wondering whether anyone here can confirm this for me; Will using the letter with this symbol impair our rankings for this franchise name? Obviously as a UK business people search for this franchise with a regular letter and not the accented one. I would have thought that Google is clever enough to recognise the meaning of the accented letter by now and therefore it wouldn't affect rankings (much). Furthermore, do you think that it would make any difference to use the HTML element to represent the accent rather than copy and pasting the symbol onto our website? I would've thought this would help Google pick it up, but it might not make a difference anyway! Any help is appreciated. Thanks Sam
Technical SEO | | Sandicliffe1 -
Coming soon SEO
Hi, I was wondering what is the best practice to redirect all the links juice by redirecting all the pages of your website to a coming soon page. The coming soon page will point to the domain.com, not to a subfolder. Should I move the entire website to a subfolder and redirect this folder to the coming soon page? Thanks
Technical SEO | | bigrat950 -
Changing DNS -- SEO implications?
Hey Moz, We're migrating an old site on an old server over to a new server/DNS. The plan is to keep the same URL structure and reuse our existing URL's. As long as we make minimal changes to each page's content, we should be able to update our DNS entry and get all the pages recreated and assigned to their correct URLs without any reduction in SEO rankings. Is this correct? This site gets a lot of organic traffic and ranks highly on some challenging keywords, so it's key that we retain our rankings as much as possible. I've read that it's wise to lower the DNS time-to-live to one hour, about a day before the move, to help Google crawl the DNS a little quicker. Are there any other recommendations you guys can offer or past experiences?
Technical SEO | | stephen_reply0 -
Permalink structure for Wordpress Getshopped Plugin
Hi everyone, has anyone had any experience with Getshopped eCommerce plugin for Wordpress and it's permalink structure? Currently the permalink reads something like http://www.sitename.com/products-page/product-category/product-description/ I would like to modify it to be http://www.sitename.com/product-description/ but the SEO Plugin I am using All-in-One SEO only allows me to edit the "product-description" part of the permalink and not the "products-page/product-category/" part of it The permalink structure is set to /%postname%/ under Settings in Wordpress. Any help/comments will be greatly appreciated Thanks
Technical SEO | | webseoservices0