Splitting description in Debut theme

Solved
Highlighted
Tourist
12 0 1

I've had this work on other themes but not on Debut currently?
I put <!-- split --> in my product description html and nothing happens?

(apologies if this has been asked before)

0 Likes
Shopify Expert
665 170 201
Hi, @weaverc ,
This is Evita from On The Map.
 
Can you add the code where you used split?
 
Best, Evita
 
On The Map Marketing | Developing custom Shopify Sites & Apps is our thing

- Install our latest app Accessibly - Makes your store accessible for everyone, helps to avoid fines
- Inc 5000 | Shopify Parners | 20+ stores launched | 300+ active clients
- Need help with your Shopify store? Reach out to us!
0 Likes
Highlighted
Tourist
12 0 1

splitfunction.jpg

0 Likes
Highlighted
Tourist
12 0 1

Everything stays formatted to the right of my product description.

0 Likes
Highlighted
Shopify Expert
665 170 201

Split isn't working, because <!-- --> Is only for comments.

HTML comments are visible to anyone that views the page source code but is not rendered when the HTML document is rendered by a browser.

On The Map Marketing | Developing custom Shopify Sites & Apps is our thing

- Install our latest app Accessibly - Makes your store accessible for everyone, helps to avoid fines
- Inc 5000 | Shopify Parners | 20+ stores launched | 300+ active clients
- Need help with your Shopify store? Reach out to us!
0 Likes
Highlighted
Shopify Expert
665 170 201

I can see that you haven't closed tags eather, that's why the code will not work as planed.

Try this code:

<table>
   <tbody>
      <tr>
        <td width="319"></td>
        <td width="319"></td>
     </tr>
   </tbody>
</table>

This is a closing tag - </table>, </tbody>, </tr>, </td>

On The Map Marketing | Developing custom Shopify Sites & Apps is our thing

- Install our latest app Accessibly - Makes your store accessible for everyone, helps to avoid fines
- Inc 5000 | Shopify Parners | 20+ stores launched | 300+ active clients
- Need help with your Shopify store? Reach out to us!
0 Likes
Highlighted
Tourist
12 0 1

I have closed the table but I moved all the code downwards so I didn't post my content on here.

Well how come that split function worked on another store of mine with the same tag?
How do I split the right side formatting in debut theme then?

0 Likes
Highlighted
Shopify Partner
315 46 86

Hi @weavercIn some themes adding '<!-- split -->' to the HTML of a product description creates a separate section which can have different styling etc. as you say but this is not a feature supported by the Debut theme by default.

However if you wanted to you can modify the 'product-template.liquid' file to support this as I did this to Debut for one of my sites at some point previously.

Let me know if it helps and I'll see if I can dig out how I did it.

If helpful then please Like and Accept Solution
0 Likes
Highlighted
Tourist
12 0 1

Yes please, this is what I wish to do.

0 Likes
Highlighted

Success.

Shopify Partner
315 46 86

ok, so this is what I have done to mine.

In 'product-template.liquid' file, find 'product-single__description rte' I then amended/added the code as follows. The result should be that now if you add <!-- split --> to the HTML in your product description, everything that comes after is in a separate section.

<div class="product-single__description rte" id="first_product_description">
      {{ product.description | split: '<!-- split -->' | first }}
          </div>
       </div>
        <div class="product-single__description rte" id="last_product_description">
      {{ product.description | split: '<!-- split -->' | last }}
      </div>
If helpful then please Like and Accept Solution
3 Likes