Default Wordpress 301 Redirects of JS and CSS files. Bad for SEO & How to Fix?
-
Hi there:
We are developers with some digital marketing expertise, but a current issue has us perplexed. An outside SEO firm has asked us to clean up a large number of 301 redirects. Most of these are 'default' Wordpress behavior that relate to calling the latest version of a JS or CSS file. For instance, a JS file is called with this: https://websitexyz.com/wp-includes/js/wp-embed.min.js?ver=4.9.1 but ultimately redirects to this: https://websitexyz.com/wp-includes/js/wp-embed.min.js. We are being asked to prevent the redirect from happening by, presumably, calling the ultimate file to begin with.
The issue is that, as far as we know, there's no easy way to alter WP behavior to call the ultimate file to begin with. Does anyone have any thoughts on this?
Thanks.
-
Thanks Martijn, we'll look into the blog post and implement.
dave
-
Hey David,
Depending on if you're using a custom template or not, you might want to look into this blog posts which is talking about that you can basically register files & styles to be inserted but they don't always have to have the version number: http://wpcrux.com/blog/wordpress-enqueue-functions-version/ . I've dealt with this once before, although it's a super tiny issue that is usually something that I would put on my roadmaps ;).
Martijn.
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
-
Kind of duplicate categories and custom taxonomy. Necessary, but bad for SEO?
Hello Everyone! I'm new here! My husband and I are working on creating a website: https://sacwellness.com .The site is an online therapist directory for the the Sacramento California area. Our problem is this: In wordpress our category system is being used for blog posts. Our theme is using a custom taxonomy system to categorize different therapist specialties, therapeutic approaches, etc. We've found ourselves in a position where our custom taxonomy and categories are near duplicates. for example we have the blog categories: ADHD counseling, Anxiety therapy, and Career counseling our corresponding custom taxonomy/therapist categories are: ADHD, Anxiety, and....(oops) career counseling. My understanding is that google doesn't see a difference between identically named categories and custom taxonomies and will so choose one to rank and disregard the other, effectively leaving you competing against yourself. is this true in a case like this? Can google maybe understand the difference because of the custom taxonomy and/or URL paths? if this is a problem is it ok to have near duplicates....like ADHD vs. ADHD counseling. This has been our solution so far....but now we're questioning it....derp x_x. I thought about tagging the categories with no index, but I think the archive pages would be useful for people. Essentially we have 2 sets of archives for each keyword. One is for blog posts, and one is for therapists who work with that particular issue along with the 6 most recent blog posts in that category.....because we are putting the 6 most recent blog posts at the bottom of the therapist pages I feel like it wouldn't be as terrible of a loss if we had to noindex the category pages. ....what do you think? Thank you!
Intermediate & Advanced SEO | | angelamaemae0 -
Suggested approach (support) for 301 redirects in event of an acquisition
If an agency has recently been acquired by a new organisation, it will need to be redirected to the new organisation's website as soon as possible. We are aware of the need to 301 redirect all pages (domain authority) across to the current domain of the new organisation's website. The new organisation has less pages than our Agency site however, so we cannot point 301 redirects at page level. Would you therefore advise, A, B or C?: A) Redirecting all pages including all blog posts/services pages etc across from the agency site to the new organisation's domain? * new organisation does not have /blog or /services pages. -Will we lose authority if redirecting from pages of our agency site to the new organisation's top level domain? B) Ensure that the new organisation secures hosting of the agency website, and place a holding page on the Agency website directing visitors through to the new organisation for the interim, until we have a /blog, /services page on the new organisation's site? C) Place 301 redirects from agency across to new organisation, and look moving forward (when pages have been put in place on new organisation website) to retrospectively repoint 301 redirects from top level domain of new organisation's site to the new pages which have just been created on the new organisation's site? Any pointers here would be appreciated. Thanks!
Intermediate & Advanced SEO | | Tangent0 -
72KB CSS code directly in the page header (not in external CSS file). Done for faster "above the fold" loading. Any problem with this?
To optimize for googles page speed, our developer has moved the 72KB CSS code directly in the page header (not in external CCS file). This way the above the fold loading time was reduced. But may this affect indexing of the page or have any other negative side effects on rankings? I made a quick test and google cache seems to have our full pages cached, but may it affect somehow negatively our rankings or that google indexes fewer of our pages (here we have some problems with google ignoring about 30% of our pages in our sitemap".)
Intermediate & Advanced SEO | | lcourse0 -
Huge httaccess with old 301 redirects. Is it safe to delete all redirects with no traffic in last 2 months?
We have a huge httaccess file over several MB which seems to be the cause for slow server response time. There are lots of 301 redirects related to site migration from 9 months ago where all old URLs were redirected to new URL and also lots of 301 redirects from URL changes accumulated over the last 15 years. Is it safe to delete all 301 redirects which did not receive any traffic in last 2 months ? Or would you apply another criteria for identifying those 301 that can be safely deleted? Any way to get in google analytics or webmaster tools all 301 that received traffic in the last 2 months or any other easy way to identify those, apart from checking the apache log files ?
Intermediate & Advanced SEO | | lcourse0 -
Setting up 301 Redirects after acquisition?
Hello! The company that I work for has recently acquired two other companies. I was wondering what the best strategy would be as it relates to redirects / authority. Please help! Thanks
Intermediate & Advanced SEO | | Colin.Accela0 -
301 v/s 302 Redirection on Homepage (Multilingual)
Hello, Our website: http://www.luxresorts.com currently has a default 302 redirection to http://www.luxresorts.com/en. We would like to do a 301 redirection instead of a 302 to http://www.luxresorts.com. Our concern is that the site is multilingual and we wonder what effect would the 301 redirection have on search engine crawlers and how would this appear on SERP. When a search is done on Google.com, the English version of our website appears and when on Google.FR, the French version appears. Would the 301 redirection change the way our website appear on Google? Grateful if you could help us out in understanding the pros and cons/best practices for our concern. Thanks in advance. Tej Luchmun.
Intermediate & Advanced SEO | | luxresorts0 -
Quoestion about 301 redirect
Hey, I have interesting questions regardin 301 redirect (At least I think it's Interesting:) ) So i have this websites that compares different lenders, url below 🙂 If you go to the homepage then the first thing you see is different loan amounts in 50-99 euro range. Also you can check out different loan amounts like 100-149€, 150-199€, 200-249€ and so on. For now i have used 301 redirect and Noindex and Nofollow for all the different "loan amounts" urls. Examples below etc Is it a good idea to use 301 on all such pages to point to the homepage?
Intermediate & Advanced SEO | | TauriU0 -
Canonical Fix Value & Pointer To Good Instructions?
Could you tell me whether the "canonical fix" is still a relevant and valuable SEO method? I'm talking about the .htaccess (or ISAPI for Microsoft) level fix to make all of the non-www page URLs on a website redirect to the www. version - so that SEO "value" isn't split between the two. I'm NOT talking about the newer <rel= canonical="" http:="" ...="">tag that goes in the HEAD section on an HTML page - as a fix for some duplicate content issues (I guess). </rel=> I still hear about the latter, but less about the former. But the former is different than the latter right - it doesn't replace it? And I'm not sure if the canonical fix is relevant to a WordPress-based website - are you? Also I can never find any page or article on the Web, etc. that explains clearly how to implement the canonical fix for Apache and Microsoft servers. Could you please point me to one? Thanks in advance!
Intermediate & Advanced SEO | | DenisL0