close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Product name not showing on results page with P3

Thread began 2/25/2010 7:27 pm by jeremykrick399007 | Last modified 3/17/2010 12:27 pm by Eric Mittman | 1180 views | 3 replies |

jeremykrick399007

Product name not showing on results page with P3

--------------------------------------------------------------------------------

I have upgraded to powerstore 3, my category name doesn't show at the top of my results page anymore. Has the ProductName variable changed?

Sign in to reply to this post

Eric Mittman

The results page by default just has a heading of Product List. The way the info on the page loads differs from the previous versions.

If you would like to add in the category name you would need to add in an additional recordset that will select from the category table where the id matches the URL param for category id.

You could then use the bindings from this rs to show the category name, and if there is no category specified you could show the Product List default text. Please post back with any questions that you have about any part of this.

Sign in to reply to this post

jeremykrick399007

Can you provide me with the correct code to do this Eric?

Sign in to reply to this post

Eric Mittman

An example of what the code for the query might look like for you on the page is this:

php:
<?php

$catparam_categories 
"-1";
if (isset(
$row_WADAProducts["CategoryID"])) {
  
$catparam_categories = (get_magic_quotes_gpc()) ? $row_WADAProducts["CategoryID"] : addslashes($row_WADAProducts["CategoryID"]);
}
mysql_select_db($database_PowerStoreConnection$PowerStoreConnection);
$query_categories sprintf("SELECT * FROM ps3_categories WHERE CategoryID = %s"GetSQLValueString($catparam_categories"int"));
$categories mysql_query($query_categories$PowerStoreConnection) or die(mysql_error());
$row_categories mysql_fetch_assoc($categories);
$totalRows_categories mysql_num_rows($categories);
?>



It would need to be just after the products recordset. You can then display the name of the category like this:

php:
<?php echo $row_categories['CategoryName']; ?>
Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...