Jump to content

How to add Dynamic Text Replacement (DTR) to squarespace site?

Recommended Posts

Posted

I want to dynamically replace text on my landing page based on the Google Ad search string. For instance, if the string includes, "Texas," then I'd like the landing page to read, "We love Texas!" I assume it's done with javascript on squarespace. Do you have an example and code block?

 

  • Replies 3
  • Views 933
  • Created
  • Last Reply
Posted

Javascript would be used for this, yes. Can you provide an example URL that would be coming into your landing page? In other words. Is Google going to be sending query string parameters to your landing page that can be used to key off of?

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

  • 1 month later...
Posted

I am wondering if i squarespace can work with custom query paramters? such as, squarespacesiteurl.com/?user_id=23432 assuming this query parameter value would be coming in from a backend service. 

Posted

@Datajoint001

It just depends on what you are trying to accomplish. We don't have access to SS's backend so there is no way server side to interpret any custom query parameters and act on those. Client side Javascript can be used to act upon query parameters in a URL but that action is limited to what can be done client side.

We would need more detail on how you want to act upon the user_id.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.