Bulk Uploading Redirects In Drupal 7

Had a client today with a list of 135ish redirects that needed entered, and a decent enough budget for me to do more than shove them in. I put together an admin page that allows you to upload a csv to be processed containing an internal source, destination, and redirect type (status code).


Bulk Redirect Magento Urls

A client needed to enter a bunch of urls to redirect today on a site. This can be easily done one at a time through the Magento admin at Admin > Catalog > Url Rewrites. That's a bit of a slow process. So to that end, we've got a DB direct method to compliment:

Adding Canonical Tags To a View

The Metatags module is great. The things it does automatically across the system is really fantastic, but there's one major problem. It can't add tags to views. That's not so bad, except that paged data might really benefit from canonical links. There are multiple modules in development right now that could be used to solve this issue, but nothing I've found that is really solid. So, here is a simple hook fix you could implement from a custom module to handle the gap for now.


Ajax Drupal Submenus

Our Seo department asked us to prevent the submenu items for the site's primary navigation from loading initially again, it had to be iframed or ajaxed in post load. I wanted a more standard solution to the issue, something I could safely reuse on multiple Drupal sites.

I used our custom module for the site to output a new block 'Custom Main Menu' that I used to replace the default main menu. It added a small dependency to menu_block, but that's an awesome module anyway, and I'm happy to rely on it. The new main menu loads as normal for users that are logged in. For anonymous users, it loads the first level of the main menu, then request ajax requests the rest after page load, replacing the entire menu block with the full menu again to avoid flashing or complex replacements.


Subscribe to RSS - SEO