You are here: The ProductCart Encyclopedia » How To's » How to rename the "productcart" folder
How to rename the "productcart" folder
Steps to edit it
All of ProductCart's files are by default included in a folder called productcart. You may rename the productcart folder to personalize the address of your store, but you should NOT remove it, or alter the folder hierarchy. You can rename the productcart folder before or after you install and activate ProductCart, but since there are a few things to change if you do this after the fact, it’s a good idea to make this change before you start using the software.
For example, the URL to the default home page is typically something like
http://www.YourStore.com/productcart/pc/home.asp
… but you might want to change it to something like…
http://www.YourStore.com/shop/pc/home.asp
You must not remove the productcart folder. To rename it, follow these steps:
- Locate the file productcartfolder.asp in the includes directory and download it to your local system using your favorite FTP program.
- Open the file with Notepad or an HTML editor and change the name productcart to any other name that you would like to use (only use alphanumeric characters in the name and no spaces). Save the edited file and re-upload it to your server via FTP.
- Change the name of the productcart folder itself to the new folder name that you have just entered in the productcartfolder.asp file. In the example mentioned above, the file would be edited from…
private const scPcFolder="productcart"
…to:
private const scPcFolder="shop"
E-commerce widget for Blogs
If you have installed the E-commerce widget for Blogs you will also need to re-generate the Widget.
Folder name and database connection string
If you have not yet activated ProductCart, keep this folder name into account when you create the database connection string if you are using a DSN-less database connection to a MS Access database. If this sounds confusing, don't worry. You will find detailed instructions on how to connect ProductCart to a MS Access database in the Installation section of the ProductCart User Guide.
If you already activated ProductCart and you are using a DSN-less connection to a MS Access database, you will need to edit it accordingly or every page in your store will return an error indicating that the system cannot connect to the database. The database connection string is located in the file storeconstants.asp inside the includes folder.
Folder name and Parent Paths Disabled
If you are running ProductCart on a Web server that has Parent Paths Disabled and wish to change the “productcart” folder name, you will have to edit the hard-coded paths to the include files. In simple terms, you will need to perform the following find & replace tasks on the entire “productcart” folder, using a tool such as the Find & Replace utility contained in Adobe Dreamweaver.
For example, to change “productcart” into “store”, you would have to perform the following 3 find & replace tasks.
Replace
virtual="productcart/includes/
… with:
virtual="store/includes/
Replace
virtual="productcart/pc/
… with:
virtual="store/pc/
Replace
arrBaseFolder(0)="/productcart/pc
… with:
arrBaseFolder(0)="/store/pc