Trying To Create Custom Template For Products Listing Without Success :(

Hello,

Really appreciate your help in this.

I want to create custom template to show my products using the products showcase block. The issue is that the image of the product doesn't show. I did the following:

I copied the file of the existing template that I want to customize from this path:

/var/www/html/[site]/design/themes/responsive/templates/blocks/products/products_scroller.tpl

Then put it in this directory:

/var/www/html/[site]/design/themes/[my_custom_theme]/templates/blocks/products/custom_products_scroller.tpl

I extended the schemes for the new template.

My problem is the image doesn't show and no-image icon appears.

Tried the following:

- I copied the original template without any modifications except the template name and file name - no luck.

- Tried the above using my changes addon - no luck.

- Deleted cache/uploaded new images - no luck.

Anyone can help me please. Did I miss any thing?

Thank you!

Hello,

Really appreciate your help in this.

I want to create custom template to show my products using the products showcase block. The issue is that the image of the product doesn't show. I did the following:

I copied the file of the existing template that I want to customize from this path:

/var/www/html/[site]/design/themes/responsive/templates/blocks/products/products_scroller.tpl

Then put it in this directory:

/var/www/html/[site]/design/themes/[my_custom_theme]/templates/blocks/products/custom_products_scroller.tpl

I extended the schemes for the new template.

My problem is the image doesn't show and no-image icon appears.

Tried the following:

- I copied the original template without any modifications except the template name and file name - no luck.

- Tried the above using my changes addon - no luck.

- Deleted cache/uploaded new images - no luck.

Anyone can help me please. Did I miss any thing?

Thank you!

You will have to create a new block using the blocks schema. You can find more about this in the user docs.

Kind regards,

You will have to create a new block using the blocks schema. You can find more about this in the user docs.

Kind regards,

Thank you for your reply!

Do you mean this:

 array(
		'show_price' => array (
			'type' => 'checkbox',
			'default_value' => 'Y'
		),
		'enable_quick_view' => array (
			'type' => 'checkbox',
			'default_value' => 'N'
		),
		'not_scroll_automatically' => array (
			'type' => 'checkbox',
			'default_value' => 'N'
		),
		'scroll_per_page' =>  array (
			'type' => 'checkbox',
			'default_value' => 'N'
		),
		'speed' =>  array (
			'type' => 'input',
			'default_value' => 400
		),
		'pause_delay' =>  array (
			'type' => 'input',
			'default_value' => 3
		),
		'item_quantity' =>  array (
			'type' => 'input',
			'default_value' => 5
		),
		'thumbnail_width' =>  array (
			'type' => 'input',
			'default_value' => 80
		),
		'thumbnail_height' =>  array (
			'type' => 'input',
			'default_value' => 80
		),
		'outside_navigation' => array (
			'type' => 'checkbox',
			'default_value' => 'Y'
		)
	),
	'bulk_modifier' => array (
		'fn_gather_additional_products_data' => array (
			'products' => '#this',
			'params' => array (
				'get_icon' => true,
				'get_detailed' => true,
				'get_options' => true,
			),
		),
	),
);
return $schema;

I already created this and options of my new template appears in the layout manager. But still no image of the product shows. It shows the no-image icon. Name of the product, link and all other information are fine except no image!

No. On the layouts page, go to Blocks/Add Block. Then you should see your new block listed. Select that block and give it a name. You would then use that block in your layout.

To get images form database, you should add bulk_modifier for your template with schema. Use example from post #3

	'bulk_modifier' => array (
		'fn_gather_additional_products_data' => array (
			'products' => '#this',
			'params' => array (
				'get_icon' => true,
				'get_detailed' => true,
				'get_options' => true,
			),
		),
	),

I managed to get it working. I don't know what was the problem but maybe I had a syntax error in the schema extension.

Anyway, thank you all for your replies!

In fact, I had no syntax error. I just have to disable and re-enable my changes addon for all changes to take effect.

So you will have to deactivate/activate my changes addon for schemas to take effect.

In fact, I had no syntax error. I just have to disable and re-enable my changes addon for all changes to take effect.

So you will have to deactivate/activate my changes addon for schemas to take effect.

Hello,

This is because all the schemas (with their .post and .pre extensions) are merged into one file and then saved in the cache. Next time just add ?cc&ctpl to your admin url, that should do the job as well.

Kind regards,