0
votes

I have installed visual composer on my wordpress and has enabled it to execute on all pages, posts, product, etc.

Later, I created a product whose description is designed in visual composer. So when I visit the product page the visual code is parsed properly.

Now I created a page where I fetch the description data from the DB and echo it on the page. But the visual composer tags are printed as text, they are not parsed or processed.

So, how to process the visual code on that separate page ?

1
Please provide some examples of what you have tried so far.Will
I have create a product in visual with description like... [vc_row][vc_column][vc_column_text] description [/vc_column_text][/vc_column][/vc_row]... It is processed on the product page and the outhput is only description but when I fetched the description from DB and echoed it then it prints the above code as it is.Shrinivas Deshpande

1 Answers

0
votes

After digging up the code I figured it out.

We can just apply the the_content filter.

ex: $processed_content=apply_filters( 'the_content',$contentFromDB);

Where $contentFromDB contains visual composer generated code.

That's it.