Jump to content

Query SQL


vister

Recommended Posts

Hello
I have a problem with PrestaShop 1.7.
I created additional columns in the database in the database and I would like them to be displayed.
I do not know how to do it. Please help.
I wrote this piece of code:

classes / Feature.php
private function getProducts ($ id_product) {
         $ sql = 'SELECT * FROM'. _DB_PREFIX_. 'Example';
         return Db :: getInstance (_PS_USE_SQL_SLAVE _) -> executeS ($ sql);
     }


poroduct-detailis.php
<dt class = "name"> Example </ dt>
          <dd class = "value"> {$ feature.getProducts} </ dd>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...