CE Phoenix v1.0.8.12 and using S02e06 -> 1.0.8.5 - Product Terms
Adding a term doesn't allow html to be used. Shows as one long document.
Not sure why it doesn't work same as privacy, conditions or other info pages.
Any way to get product terms to use html.
Thanks
s02e06 - Product Terms SUPPORT/QUESTIONS
-
ecartz
- Core Team
- Posts: 3084
- Joined: Tue Nov 05, 2019 6:02 pm
- Phoenix Version:
- Has thanked: 4 times
- Been thanked: 208 times
Re: s02e06 - Product Terms
If you want HTML in the product terms, you will have to change in admin/includes/actions/ insert.php and save.php the Text::input to Text::prepare for any column you want to have HTML. E.g. the name and description.
Re: s02e06 - Product Terms
Thanks again.
Worked perfectly.
Worked perfectly.
-
heatherbell
- Senior Contributor
- Posts: 2540
- Joined: Mon Oct 07, 2019 4:39 am
- Phoenix Version:
- Has thanked: 35 times
- Been thanked: 243 times
Re: s02e06 - Product Terms
Found a couple of issues.
1. On admin/terms.php, Action icon does not change when clicked as expected.
Possibly issue is on Line 43 which is:
2. On admin/terms.php, click Delete and then Delete confirm on first item in list gives notice and associated error:
Undefined index: tID - /includes/actions/terms/delete_confirm.php on line 12
However, possibly issue is in admin/includes/actions/terms/infoboxes/default.php Line 13 which is:
1. On admin/terms.php, Action icon does not change when clicked as expected.
Possibly issue is on Line 43 which is:
Code: Select all
return (isset($row['info']->id) && ($row['info']->id === $row['terms_id']))Undefined index: tID - /includes/actions/terms/delete_confirm.php on line 12
However, possibly issue is in admin/includes/actions/terms/infoboxes/default.php Line 13 which is:
Code: Select all
$link = $GLOBALS['Admin']->link()->retain_query_except();-
ecartz
- Core Team
- Posts: 3084
- Joined: Tue Nov 05, 2019 6:02 pm
- Phoenix Version:
- Has thanked: 4 times
- Been thanked: 208 times
-
Denzel
- Member
- Posts: 87
- Joined: Sat Oct 31, 2020 7:22 pm
- Phoenix Version:
- Has thanked: 9 times
- Been thanked: 15 times
Re: s02e06 - Product Terms
Found an other issue in admin/includes/actions/terms/infoboxes/delete.php causing error 500 on confirm delete.
Line 13 should be :
and Line 15 should be:
to work.
Line 13 should be :
Code: Select all
$link = $link = $GLOBALS['Admin']->link()->retain_query_except(['action'])->set_parameter('tID', (int)$table_definition['info']->terms_id);Code: Select all
$contents = ['form' => new Form('terms', (clone $link)->set_parameter('action', 'delete_confirm'))];- Pierre_P
- Contributor
- Posts: 144
- Joined: Fri Mar 12, 2021 5:06 am
- Phoenix Version: v1.1.0.6
- Has thanked: 21 times
- Been thanked: 11 times
Re: s02e06 - Product Terms
In admin if you assigned terms to products it will only count the number of products using that term.
If you have many products assigned to that term and you have long forgot what products it was i added a simple output to show you what products are assigned to that term.
Added change in admin/includes/actions/terms/infoboxes/default.php
below add:
Hth.
If you have many products assigned to that term and you have long forgot what products it was i added a simple output to show you what products are assigned to that term.
Added change in admin/includes/actions/terms/infoboxes/default.php
below
Code: Select all
$contents[] = ['text' => '<b>' . $table_definition['info']->products_count . '</b> Products is using this Term'];Code: Select all
$terms_query = $GLOBALS['db']->query("SELECT pb.terms_id, pb.products_id, p.products_id, pd.products_name, pd.language_id FROM products p LEFT JOIN products_to_terms pb ON (pb.products_id=p.products_id) LEFT JOIN products_description pd ON (pd.products_id=pb.products_id) WHERE pd.language_id = '1' AND terms_id = " . (int)$table_definition['info']->terms_id);
if (mysqli_num_rows($terms_query) < 1) {
$contents[] = ['text' => '<b>Congratulations!</b> There are no products assigned to this Term'];
} else {
while ($terms = $terms_query->fetch_assoc());
foreach ($terms_query as $option => $value) {
$contents[] = ['text' => 'Products Name: ' . $value['products_name'] . ' pID: ' . $value['products_id']];
}
}