Announcement

Collapse
No announcement yet.

Code for slugified URI's

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Code for slugified URI's

    Store owner wants to switch from product/category code style links to one that uses the product or category name. To say the least, the slugify code is no longer in the fields. Would someone mind posting what needs to go into those fields, please?

    The request has also been made to include the category name in the URI - I can see where that might get a bit hairy (especially if the product is assigned to more than one category). I need to dig back through my posts because seem to recall I came upon another issue when trying to include the category code for a different URI style. I figure I may run into that issue too trying to use the category name.

    Leslie Kirk
    Miva Certified Developer
    Miva Merchant Specialist since 1997
    Previously of Webs Your Way
    (aka Leslie Nord leslienord)

    Email me: [email protected]
    www.lesliekirk.com

    Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr

    #2
    Leslie,

    I believe the default code can be found on the following page:

    https://docs.miva.com/how-to-guides/...existing-store

    Comment


      #3
      Originally posted by eldon99 View Post
      Leslie,

      I believe the default code can be found on the following page:

      https://docs.miva.com/how-to-guides/...existing-store
      Ahhh, yes. Many thanks!
      Leslie Kirk
      Miva Certified Developer
      Miva Merchant Specialist since 1997
      Previously of Webs Your Way
      (aka Leslie Nord leslienord)

      Email me: [email protected]
      www.lesliekirk.com

      Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr

      Comment


        #4
        Circling back to this. The reference page doesn't include how to use the Category Name as the slugified. They are all pulling from the Page Title (slugified_page_title). I'm sure I'm missing the obvious here but how do I slugify the category:name;?

        Thanks!
        Leslie Kirk
        Miva Certified Developer
        Miva Merchant Specialist since 1997
        Previously of Webs Your Way
        (aka Leslie Nord leslienord)

        Email me: [email protected]
        www.lesliekirk.com

        Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr

        Comment


          #5
          Its probably not best to use the category name in the URL since a product can be part of multiple categories. However if you wanted to do this you could generate all the URLs in excel and import them or you would need to use template code in the product URI template to load the first category the product was assigned to and use that in the URL structure.
          Brennan Heyde
          VP Product
          Miva, Inc.
          [email protected]
          https://www.miva.com

          Comment


            #6
            Is it possible to pull in a value from a product custom field to be part of the slugified product URI? I found some old posts about this quite a while ago but was unable to get it to work.

            I'm looking to produce a URI that is a slugified expression of: [designer-custom-field]-[product-name] OR if the designer-custom-field is null then just slugified [product-name].
            Psydde Delicious
            Delicious Boutique & Corseterie
            Philadelphia, PA
            www.DeliciousBoutique.com
            www.DeliciousCorsets.com

            Comment

            Working...
            X