Skip to Main Content

SpringyNews - Springy Cleaning Edition

March 2023

Tips & Tricks - All Things Search & Replace

That overstuffed junk drawer. The cabinet full of boxes, papers, and miscellaneous items. Or even a whole closet where we just keep stuffing more and more stuff with the idea that we'll get to that later. But there comes a day when those areas are tackled. Things are pulled out, sorted, and tossed... and you get to enjoy the glorious afterglow of all that hard work.

This edition of LibGuides Tips & Tricks focuses exclusively on the Search & Replace tool and all the ways you can use it to clean-out your LibGuides system, ensure your asset library is designed for optimal use, and bask in the afterglow of system well-organized.

1. Using the S&R Tool for Just Search

Easy

The first step in organizing is identifying where everything is - and pulling it all together. There's nothing worse than organizing your entire kitchen only to find a box in the garage full of baking sheets. In your LibGuides system, start by making a list identifying all the items you want to update... and where they're located.

Search First, Then Replace

  • Tools > Search & Replace
  • Make your search type selections, match type, and case type
  • Click Search
    • Do Not Click Search & Replace
  • Bonus Tip: Copy & Paste Results into a Spreadsheet for further sorting and analysis.

2. Find Everywhere an Image is Being Used

Intermediate

Have you used an image you've uploaded to LibApps again and again, and don't know everywhere it's being used? What about images added to your shared image library that are being used by your colleagues system-wide?

This LibGuides Tip helps you identify everywhere an image is being used plus a bonus tip for easily updating images with one click!

Step One: Grab the URL of your Image

  • Navigate to LibApps Image Manager
  • Locate Image
  • Click
  • Copy the link in the resulting pop-up window

Step Two: Identify Everywhere an Image is being Used

  • Tools > Search & Replace
  • Search Type = Content Item
  • Check Off Description
  • Search For = Enter Image URL copied from Step One above
  • Replace With = Leave Blank
  • Match Type = Contains
  • Case Type = Insensitive

Bonus Tip! Once you've identified everywhere an image is being used, it's easy to update the image right from the image manager!

Bonus Tip: Updating Images from the Image Manager

  • Upload the updated image with the same file name as the original to your LibApps Image Manager Folder. 
  • The LibApps Image Manager will ask you if you want to overwrite the existing image.
  • Click Overwrite > auto-update everywhere that image is used. (And we do mean everywhere! Simply change the image file once in Image Manager and it'll be updated wherever it's being used across all of your Springy Apps! Easy peasy.)

3. Search & Replace Part of a URL

Advanced

This video is an oldie, but goodie! If you're looking to search and replace just part of a URL, watch this Springy Tech Tip Video.

How Can You Use This Tip?

  • Catalog URL Structure Changes: What if your catalog URL structure changes slightly and you need to update part of all your book asset links?
  • Database URL Upgrade: What if you upgrade to a premier database version and part of the URL changes?
  • Proxy Suffix Changes: If your proxy authentication tool, located in your URL suffix, changes and you need to make large scale changes?

Caveats:

  • This video was created on an older version of LibGuides.
  • Everything still functions exactly the same, but the screens might look a bit different than your LibGuides system in 2023.

4. Did Someone Put Widget Code in a Rich-Text Asset?

Advanced

It happens to the best of us. You're building a LibGuide and instead of putting widget code inside the Widget Asset Type, you put it inside a Rich-Text box. This isn't ideal for several reasons:

  1. Hard to Find: Widgets in Rich-Text Assets don't appear in your Asset Library, making them hard to identify, update, or remove.
  2. Not Reusable: Unless you're reusing an entire box, widgets added to a Rich-Text Asset aren't reusable.

Admin-Level Users, if you're looking to clean up your system and identify every LibGuide where this might have occurred, then this is the tip for you!

Identifying Types of Widgets

  • Create a List: What types of widgets are created at your institution by guide authors? Are they embedding YouTube videos in LibGuides? Videos from Vimeo? A search box for your catalog? Create a list of all the types of widgets that could be in use. 

Searching for Content Specific to Widgets

The key to using the Search & Replace Tool is to be targeted in your searching. The more finely honed your search terms, the better results you'll get. Searching 'www.youtube.com' will return everything that contains that URL, from widget code to regular links. Instead, identify the part of YouTube's embed code that is specific to the widget code but is also ubiquitous so as to cover all YouTube widgets.

  • Identify the URL Structure in the Embed Code: Searching for 'YouTube' will yield too many results, we're trying to identify just the part of the URL that would be used inside of widget code.
  • Don't Get Too Granular: If you get too specific in your search, you'll only retrieve one YouTube widget - instead of ALL YouTube widgets. 

Don't Search For:


  • https://www.youtube.com: This will retrieve everything, including regular links.
  • https://www.vimeo.com: This will retrieve everything that contains this URL, including regular links.
  • Specific Embed code: This is too specific and will only retrieve results for this specific video.
    • <iframe width="560" height="315" src="https://www.youtube.com/embed/FNgsuCwdeBc" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>

Instead Search For:


  • https://www.youtube.com/embed: This is specific to YouTube's embed code.
  • https://player.vimeo.com: This is a specific component of Vimeo's embed code.
  • https://www.youtube.com/embed: This is part of YouTube's embed code that is consistent across all their widgets.

Finding Code Using Search & Replace

  • Tools > Search & Replace
  • Search Type = Content Item
  • Check Off Description
  • Search For = Component of widget code
  • Replace With = Leave Blank
  • Match Type = Contains
  • Case Type = Insensitive

5. Find All Page-Level Redirects

Easy

Need a quick way to see all the page-level redirects you have in place throughout your site? The Search & Replace Tool will do the trick! By using a very generic and inclusive search term that every URL will contain (such as “http” or just simply “.”), you’ll be able to view an alphabetized list of all of your pages and their corresponding redirect URLs.

Just Search, Don't Replace

  • Tools > Search & Replace
  • Search Type = Guide Page
  • Check URL - Redirect URL box
  • Search for a generic and inclusive search term ("http" or "." work well for this purpose)
  • Replace With = Leave Blank
  • Match Type = Contains
  • Case Type Insensitive
  • Click Search
    • Do Not Click Search & Replace