joi, 11 iunie 2015

Eliminate Duplicate Content in Faceted Navigation with Ajax/JSON/JQuery - Moz Blog

Eliminate Duplicate Content in Faceted Navigation with Ajax/JSON/JQuery

Posted by EricEnge

One of the classic problems in SEO is that while complex navigation schemes may be useful to users, they create problems for search engines. Many publishers rely on tags such as rel=canonical, or the parameters settings in Webmaster Tools to try and solve these types of issues. However, each of the potential solutions has limitations. In today's post, I am going to outline how you can use JavaScript solutions to more completely eliminate the problem altogether.

Note that I am not going to provide code examples in this post, but I am going to outline how it works on a conceptual level. If you are interested in learning more about Ajax/JSON/jQuery here are some resources you can check out:

  1. Ajax Tutorial
  2. Learning Ajax/jQuery

Defining the problem with faceted navigation

Having a page of products and then allowing users to sort those products the way they want (sorted from highest to lowest price), or to use a filter to pick a subset of the products (only those over $60) makes good sense for users. We typically refer to these types of navigation options as "faceted navigation."

faceted navigation

However, faceted navigation can cause problems for search engines because they don't want to crawl and index all of your different sort orders or all your different filtered versions of your pages. They would end up with many different variants of your pages that are not significantly different from a search engine user experience perspective.

Solutions such as rel=canonical tags and parameters settings in Webmaster Tools have some limitations. For example, rel=canonical tags are considered "hints" by the search engines, and they may not choose to accept them, and even if they are accepted, they do not necessarily keep the search engines from continuing to crawl those pages.

A better solution might be to use JSON and jQuery to implement your faceted navigation so that a new page is not created when a user picks a filter or a sort order. Let's take a look at how it works.

Using JSON and jQuery to filter on the client side

The main benefit of the implementation discussed below is that a new URL is not created when a user is on a page of yours and applies a filter or sort order. When you use JSON and jQuery, the entire process happens on the client device without involving your web server at all.

When a user initially requests one of the product pages on your web site, the interaction looks like this:

using json on faceted navigation

This transfers the page to the browser the user used to request the page. Now when a user picks a sort order (or filter) on that page, here is what happens:

jquery and faceted navigation diagram

When the user picks one of those options, a jQuery request is made to the JSON data object. Translation: the entire interaction happens within the client's browser and the sort or filter is applied there. Simply put, the smarts to handle that sort or filter resides entirely within the code on the client device that was transferred with the initial request for the page.

As a result, there is no new page created and no new URL for Google or Bing to crawl. Any concerns about crawl budget or inefficient use of PageRank are completely eliminated. This is great stuff! However, there remain limitations in this implementation.

Specifically, if your list of products spans multiple pages on your site, the sorting and filtering will only be applied to the data set already transferred to the user's browser with the initial request. In short, you may only be sorting the first page of products, and not across the entire set of products. It's possible to have the initial JSON data object contain the full set of pages, but this may not be a good idea if the page size ends up being large. In that event, we will need to do a bit more.

What Ajax does for you

Now we are going to dig in slightly deeper and outline how Ajax will allow us to handle sorting, filtering, AND pagination. Warning: There is some tech talk in this section, but I will try to follow each technical explanation with a layman's explanation about what's happening.

The conceptual Ajax implementation looks like this:

ajax and faceted navigation diagram

In this structure, we are using an Ajax layer to manage the communications with the web server. Imagine that we have a set of 10 pages, the user has gotten the first page of those 10 on their device and then requests a change to the sort order. The Ajax requests a fresh set of data from the web server for your site, similar to a normal HTML transaction, except that it runs asynchronously in a separate thread.

If you don't know what that means, the benefit is that the rest of the page can load completely while the process to capture the data that the Ajax will display is running in parallel. This will be things like your main menu, your footer links to related products, and other page elements. This can improve the perceived performance of the page.

When a user selects a different sort order, the code registers an event handler for a given object (e.g. HTML Element or other DOM objects) and then executes an action. The browser will perform the action in a different thread to trigger the event in the main thread when appropriate. This happens without needing to execute a full page refresh, only the content controlled by the Ajax refreshes.

To translate this for the non-technical reader, it just means that we can update the sort order of the page, without needing to redraw the entire page, or change the URL, even in the case of a paginated sequence of pages. This is a benefit because it can be faster than reloading the entire page, and it should make it clear to search engines that you are not trying to get some new page into their index.

Effectively, it does this within the existing Document Object Model (DOM), which you can think of as the basic structure of the documents and a spec for the way the document is accessed and manipulated.

How will Google handle this type of implementation?

For those of you who read Adam Audette's excellent recent post on the tests his team performed on how Google reads Javascript, you may be wondering if Google will still load all these page variants on the same URL anyway, and if they will not like it.

I had the same question, so I reached out to Google's Gary Illyes to get an answer. Here is the dialog that transpired:

Eric Enge: I'd like to ask you about using JSON and jQuery to render different sort orders and filters within the same URL. I.e. the user selects a sort order or a filter, and the content is reordered and redrawn on the page on the client site. Hence no new URL would be created. It's effectively a way of canonicalizing the content, since each variant is a strict subset.

Then there is a second level consideration with this approach, which involves doing the same thing with pagination. I.e. you have 10 pages of products, and users still have sorting and filtering options. In order to support sorting and filtering across the entire 10 page set, you use an Ajax solution, so all of that still renders on one URL.

So, if you are on page 1, and a user executes a sort, they get that all back in that one page. However, to do this right, going to page 2 would also render on the same URL. Effectively, you are taking the 10 page set and rendering it all within one URL. This allows sorting, filtering, and pagination without needing to use canonical, noindex, prev/next, or robots.txt.

If this was not problematic for Google, the only downside is that it makes the pagination not visible to Google. Does that make sense, or is it a bad idea?

Gary Illyes
: If you have one URL only, and people have to click on stuff to see different sort orders or filters for the exact same content under that URL, then typically we would only see the default content.

If you don't have pagination information, that's not a problem, except we might not see the content on the other pages that are not contained in the HTML within the initial page load. The meaning of rel-prev/next is to funnel the signals from child pages (page 2, 3, 4, etc.) to the group of pages as a collection, or to the view-all page if you have one. If you simply choose to render those paginated versions on a single URL, that will have the same impact from a signals point of view, meaning that all signals will go to a single entity, rather than distributed to several URLs.

Summary

Keep in mind, the reason why Google implemented tags like rel=canonical, NoIndex, rel=prev/next, and others is to reduce their crawling burden and overall page bloat and to help focus signals to incoming pages in the best way possible. The use of Ajax/JSON/jQuery as outlined above does this simply and elegantly.

On most e-commerce sites, there are many different "facets" of how a user might want to sort and filter a list of products. With the Ajax-style implementation, this can be done without creating new pages. The end users get the control they are looking for, the search engines don't have to deal with excess pages they don't want to see, and signals in to the site (such as links) are focused on the main pages where they should be.

The one downside is that Google may not see all the content when it is paginated. A site that has lots of very similar products in a paginated list does not have to worry too much about Google seeing all the additional content, so this isn't much of a concern if your incremental pages contain more of what's on the first page. Sites that have content that is materially different on the additional pages, however, might not want to use this approach.

These solutions do require Javascript coding expertise but are not really that complex. If you have the ability to consider a path like this, you can free yourself from trying to understand the various tags, their limitations, and whether or not they truly accomplish what you are looking for.

Credit: Thanks for Clark Lefavour for providing a review of the above for technical correctness.


Sign up for The Moz Top 10, a semimonthly mailer updating you on the top ten hottest pieces of SEO news, tips, and rad links uncovered by the Moz team. Think of it as your exclusive digest of stuff you don't have time to hunt down but want to read!

You are subscribed to the Moz Blog newsletter sent from 1100 Second Avenue, Seattle, WA 98101 United States
To stop receiving those e-mails, you can unsubscribe now.
Newsletter powered by FeedPress

Seth's Blog : Name calling

Name calling

The best reason to brand someone with a pejorative label is to push them away, to forestall useful conversation, to turn them into the other.

Much more useful: Identify the behavior that's counter-productive. When we talk about the behavior, we have a chance to make change happen.

What would happen if the behavior stopped?

When we call someone misogynist or racist or sexist or a capitalist, a socialist or an abstract expressionist, what are we hoping for? Every one of us is on the 'ist' spectrum, so the label becomes meaningless. Meaningless labels are noise, noise that lasts.

If that person stopped acting like a _____ist, what would change? Because if there's nothing we want to change, the labeling is useless. And if there's a change that needs to be made, let's talk about what it is.

       

More Recent Articles

[You're getting this note because you subscribed to Seth Godin's blog.]

Don't want to get this email anymore? Click the link below to unsubscribe.



Email subscriptions powered by FeedBlitz, LLC, 365 Boston Post Rd, Suite 123, Sudbury, MA 01776, USA.

miercuri, 10 iunie 2015

Mish's Global Economic Trend Analysis

Mish's Global Economic Trend Analysis


Steen Jakobsen: US Credit Cycle Peaked, Zero Growth Coming to Europe, Gold 1425 by Year End

Posted: 10 Jun 2015 02:11 PM PDT

Saxo Bank chief economist sent a number of charts and comments that constitute his outlook for global macro fundamentals for the next 6-7 months.

Via email, the rest of what follows is a guest post from Steen Jakobsen.

Headlines for Next 6-7 Months

  • US, German and EU core government bonds will be 100 basis points higher by and in Q4 before making final new low in H1 2016. The US 10-year bond yield will trade above 3.0% and German Bunds 1.25%
  • WTI crude will hit US $ 70-80/barrel setting up excellent energy returns.
  • US dollar will weaken to EUR 1.18/1.20 then start multi-year weakness.
  • Gold will be the best performer in commodity-led rally. We see 1425-1435 by year-end.

Average Annual Inflation by Decade



We need to stop talking deflation and using 1930s comparison on Fed hike.

US Real Rates



Real rates finally coming off in the US. Positive Gold and negative for US$?

US Germany Breakeven Rates



Inflation expectations rising fast.

European Growth



European "cost advantage" is disappearing fast and furious. Enjoy the summer of growth – behind comes: zero growth, zero reform and higher inflation "expectations".

Central Bank Balance Sheets



Excuse me? Didn't ECB start QE – in world of madness? Hard even to see change in ECB balance sheet. Japan is just not real, for that matter nothing is!

US High Yield vs. S&P 500



Clearly the credit cycle has peaked.

LQD - US Investment Grade Corporate Bond ETF



CRY - Core Commodity Index



Compare commodities to investment grade bonds.

Fed Hike Indicator



When the FED hikes it's a margin call. There is no basis in their mandate to do hike, but their need to normalize will have data support over summer as CESI (Citi Surprise Index will mean revert).

I have been traveling like a mad man: France, UK, Croatia, Slovenia, Slovakia, Kazakhstan, Singapore, Hong Kong, Slovenia, Hungary, Czech and Netherlands. And next few weeks: London (CNBC guest hosting Friday), Switzerland, China and Japan. I have plenty to report.

Upcoming Teasers

  • CEE is the canary in the coal mine for QE
  • Mining is underowned and underpriced
  • Inflation is coming back
  • Silk Road is for real
  • Autocratic government in for hard time across Europe
  • Unfortunately still no reforms anywhere, but great clients, risk takers and media

Safe travels
Steen

Mish Comments

When Steen says there is no basis for a US rate hike, he is talking from the Fed perspective of CPI inflation.

He has commented before that the Fed may hike simply to prick asset bubbles and/or to simply do what they keep saying they will do.

I have no target for the price of gold. Rather, like Steen, I believe it is an unloved asset likely to outperform.

Finally, I have my doubts that interest rates will hit a new low in 2016, but if they do, panic will be in the air over crashing equities or asset prices in general.

Mike "Mish" Shedlock
http://globaleconomicanalysis.blogspot.com

Stocks Jump on Greece Deal Rumors; Capital Control Fears Mount, Car Buying Soars as Greeks Pull Cash

Posted: 10 Jun 2015 11:06 AM PDT

This morning, Bloomberg reported a Deal was in the works, later denied by Germany. Stocks jumped on the news, but cash withdrawals and capital flight continues as Greeks pull cash to buy cars or to put it under the mattress.

Staggered Deal Offer From Germany?

Starting from the top, Bloomberg reports Germany to Consider Offering Tsipras Staggered Deal on Aid.
Chancellor Angela Merkel's government may be satisfied with Greece committing to at least one economic reform sought by creditors to open the door to bailout funds, according to two people familiar with Germany's position.

While the Germans still insist on a package of steps that includes higher taxes, state asset sales and less generous retirement benefits, they may settle for a clear commitment by the Greek government to a measure up front to unlock aid, said the people, who asked not to be identified discussing the government's negotiating stance.

"Where there's a will, there's a way," Merkel told reporters as she arrived in Brussels. "The goal is to keep Greece in the euro area."
Wall Street Jumps on Rumor Deal

It appears Merkel will be the one to bend if anyone does.

Reuters reports Wall St. Jumps on Report Germany May Consider Greece Aid.
Wall Street surged in late morning trading on Wednesday after a Bloomberg report that Germany may be satisfied with Greece committing to at least one economic reform in return for aid.

All three major indexes rose more than 1 percent on the same day for the first time in a month.
Deal Talk "Pure Invention"

Is there a deal offer or just a rumor? Reuters reports Merkel, Hollande to Tell Greek PM to Talk to Creditors.
Germany will only accept a cash-for-reform deal between Greece and its international creditors that has the approval of all three lending instutions, a government spokesman said in response to reports that Berlin was considering easier terms.

Asked about a Bloomberg report that said Chancellor Angela Merkel's government may be satisfied with Greece committing to at least on major economic reform sought by the creditors, the spokesman told Reuters: "Germany will only accept a proposal of the three institutions. All else is a pure invention."

Merkel said earlier that her message would be that Greece must negotiate with the institutions representing the creditors. Tsipras, who has rejected several of the creditors' key conditions for a deal to unlock frozen aid, has been pressing for a "political agreement" among leaders to break an impasse in detailed negotiations.
Capital Control Fears Mount, Car Buying in Greece Soars

The Financial Times reports Anxious Greeks Pull Money from Banks Amid Fears of Capital Controls.
Two weeks after Greece's leftwing Syriza party won power at a general election in January, Panayotis Fotiades pulled his deposits from an Athens bank. To protect his savings he bought a brand new Mercedes-Benz car, then took the advice of a financial consultant and invested the remainder in money market funds based in Luxembourg.

Many other Greeks appear to be taking similar precautions. Even as the economy has been sinking, new car registrations have soared this year as worried Greek depositors seek out alternative havens for their money. They rose 27.9 per cent in April on top of a 47.2 per cent increase in March.

Already weakened banks are seeing their liquidity evaporate and the European Central Bank has warned there are limits to its support.

"The continuation of these outflows significantly increases the risk that the local authorities will impose capital controls to limit deposit outflows, which in our view would be tantamount to a bank deposit default," Moody's, the rating agency, warned in a report this week.

Discussions ground to a standstill on Wednesday amid mounting signs Germany was no longer willing to compromise and was urging a more hardline "take it or leave it" approach towards Greece. "They're really at the end of their tether," one senior eurozone official said of the Germans.

Fokion Karavias, chief executive of Eurobank, one of four big Greek lenders, said about €30bn had left the system since December, leaving banks dependent on the ECB for liquidity.

"The smart money left early on . . . The shipowners pulled out funds and manufacturing companies set up accounts outside Greece with foreign banks so they could be sure they'd continue trading," said an Athens-based banking analyst.

Fears of a default last week drove another increase in withdrawals. More than €500m left the system on Friday, the day Greece missed a €300m payment due to the IMF.

Most large depositors by now have pulled out their funds, the bank analyst said.

"Last month the amounts being moved by individual depositors were noticeably smaller, between €200,000 and €100,000. We're getting to the bottom of the barrel," he said, estimating Greeks had stashed about €5bn under mattresses and floorboards since January.

Areti Simopoulou, a retired store owner, said she heads for the cash machine at her local bank branch at the end of the month and withdraws all her pension money at once.

"I used to take out half and leave the rest for an emergency," Mrs Simopoulou said. "Now I feel relieved it's there and make sure I take out every last lepto [cent]."
If anyone gave in, it now appears it may have been Germany. But I am not sure there was movement by anyone.

And Greeks have seen enough of these rumors not to trust any of them. Even if there is a deal, that deal may involve capital controls.

Mike "Mish" Shedlock
http://globaleconomicanalysis.blogspot.com

Damn Cool Pics

Damn Cool Pics


A Tribute To The World's Best Pet Owners

Posted: 10 Jun 2015 01:45 PM PDT

It's one thing to own a pet but it's a whole other thing to actually take care of them the way these people do.























Rachel Washburn, From NFL Cheerleader to US Military

Posted: 10 Jun 2015 10:39 AM PDT

Rachel Washburn is a former Philadelphia Eagles cheerleader who, after three years with the team, decided to join the US Military.