PDA

View Full Version : PayPal module installed in wrong place?


gburton
11-9-05, 06:20 PM
How do I get Paypal started now that I've installed osCommerce2.2 via site tools?

I have been looking for the PayPal module since I installed osCommerce2.2. I finally found it but not where the osCommerce admin path indicates.

osCommerce admin (from admin window, thru powweb site tools) states following path:

Module Directory: /www/g/gmbwebsitesc/cardsbyjudy/htdocs/catalog/includes/modules/payment/ (but all that I see inside catalog is an image folder - no includes, no modules, no payment files)

However, I found Paypal.php, ipayment.php, cc.php, etc in at the following:
/www/g/gmbwebsitesc/cardsbyjudy/htdocs/includes/modules/payment

So what do I do to get this Paypal module installed/functioning/working?

gburton

stevel
11-9-05, 08:21 PM
It looks as if you have DIR_WS_CATALOG in your admin's configure.php set to '/catalog/' when it should be '/'.

gburton
11-10-05, 05:49 PM
The problem is that I did not do anything. I don't know enough about php and osCommerce to make these kinds of changes. So how do I get it to the way its supposed to be?

Thank you,

gburton

stevel
11-10-05, 10:11 PM
Please don't take offense, but.. you need to learn PHP and osCommerce. If you don't, you will be hopelessly lost. osCommerce is not an "instant setup and walk away" solution. This is a good time to learn. Pick up a book on PHP (I used "Programming PHP" from O'Reilly Press) and start studying the code. As you make simple changes (and this is a simple change), you'll gain the experience you need to start building a really nice store.

I recommend that people do NOT use the SiteTools to install osCommerce - or any other script package. Download the package from the script source and read the instructions. PowWeb's installers make too many assumptions (and some of them wrong, it would appear.)

gburton
11-13-05, 07:06 PM
Thank you. I appreciate your advice. This might be a slow process but I will definitely do it.

Should uninstall the previously installed osCommerce (from site tools) and reinstall from the source? or continue from where I am now?

gburton

stevel
11-13-05, 07:30 PM
Up to you, really. If the install is where you want it to be, then continue as-is. It's not hard to move it later if you change your mind. You should download all the files to your local computer in any case and use those to make modifications. Also save a copy as a backup.

gburton
11-14-05, 05:33 PM
stevel, I will stick with the copy I have now. I am getting familiarized with PHP and will get the PHP book you recommended. In the meantime I am confident, with your help, I can fix this existing problem: Sooo, my next question is do I make the following change?

'DIR_WS_CATALOG', 'catalog/' change to 'DIR_WS_CATALOG', '/'

What else should I change - if anything? Please see my configure.php code below from htdocs/admin/includes/configure.php.

NOTE: I am doing these changes on my harddrive - as you suggested - and have saved an original copy as well on my backup harddrive. I noticed my password is not encrypted so I xxxxx'd it out. How can I encrypt it? Can I just copy/paste an ecrypted version of my password in its place?
Thank you for your help!

CODE FROM htdocs/admin/includes/configure.php

// define our webserver variables
// FS = Filesystem (physical)
// WS = Webserver (virtual)
define('HTTP_SERVER', 'http://cardsbyjudy.gmbwebsites.com/'); // eg, http://localhost or - https://localhost should not be NULL for productive servers
define('HTTP_CATALOG_SERVER', 'http://cardsbyjudy.gmbwebsites.com/');
define('HTTPS_CATALOG_SERVER', 'http://cardsbyjudy.gmbwebsites.com/');
define('ENABLE_SSL_CATALOG', false); // secure webserver for catalog module
define('DIR_FS_DOCUMENT_ROOT', '/www/g/gmbwebsitesc/cardsbyjudy/htdocs/'); // where your pages are located on the server. if $DOCUMENT_ROOT doesnt suit you, replace with your local path. (eg, /usr/local/apache/htdocs)
define('DIR_WS_ADMIN', 'admin/');
define('DIR_FS_ADMIN', DIR_FS_DOCUMENT_ROOT . DIR_WS_ADMIN);
define('DIR_WS_CATALOG', 'catalog/');
define('DIR_FS_CATALOG', DIR_FS_DOCUMENT_ROOT . DIR_WS_CATALOG);
define('DIR_WS_IMAGES', 'images/');
define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
define('DIR_WS_INCLUDES', 'includes/');
define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

// define our database connection
define('DB_SERVER', 'mysql15.powweb.com');
define('DB_SERVER_USERNAME', 'gmbwebsitesc1');
define('DB_SERVER_PASSWORD', 'xxxxxxxxx');
define('DB_DATABASE', 'gmbwebsitesc_oscommerce2');
define('USE_PCONNECT', false);
define('STORE_SESSIONS', 'mysql');
?>

stevel
11-14-05, 07:18 PM
You're not being careful with your edits. It's going to get you in trouble.

First, the HTTP_SERVER and HTTPS_SERVER lines should not have a / at the end of the value. Second, you took out a slash at the beginning of DIR_WS_ADMIN and DIR_WS_CATALOG. You want DIR_WS_ADMIN to be '/admin/' (unless you moved it somewhere else, which I like to do), and DIR_WS_CATALOG should be '/'.

The SQL password cannot be encrypted.

gburton
11-14-05, 07:43 PM
I appreciate your feedback but I have not make any changes to the code I sent to you. This is just a copy/paste of what it looks like after install - not changes made. So are you saying that I should make changes to the following?

1. take the last / off of define('HTTP_SERVER', 'http://cardsbyjudy.gmbwebsites.com/'
2. and define('HTTP_CATALOG_SERVER', 'http://cardsbyjudy.gmbwebsites.com/');
3. and define('HTTPS_CATALOG_SERVER', 'http://cardsbyjudy.gmbwebsites.com/');

What about the 'DIR_WS_CATALOG', 'catalog/' ? Should I take out the work catalog?

Thank you,

Gina

stevel
11-14-05, 07:53 PM
Yes to all. If PowWeb's installer set you up that way, it is broken. I will have to try this myself and report problems found.

BTW, don't you want to use secure pages for the checkout part of your store?

gburton
11-15-05, 01:09 PM
Thank you. Please let me know if there is anything else broken or that I need to change.

RE: Secure Pages
Yes, I think. What are the pros/cons of using secure pages?

gburton

gburton
11-15-05, 01:46 PM
stevel,

Changing 'catalog/' to '/' did work! I have now installed paypal and set my defaults. I will be testing it out next.

However taking out the slashes at the end of the ...gmbwebsites.com/' did not work. It actually gave me "page not found" after changes. I could see where the address was messed up (missing the slash between .com and admin in the address window. So I put the slashes back in and is working again.

Questions:
1. I just looked up SSL and "secure pages" so now I know that this is a MUST! Can I ask you here how to do it or do I start another thread. I will be checking out kb.powweb while awaiting your reply. Okay, I checked out SSL at kb.powweb and it tells me it is automatically set up. Sooo, I need your help, thank you.
2. Were you able to test the slash issue out for yourself yet?

Thank you,

gburton

stevel
11-16-05, 12:12 AM
You have to correctly make the corresponding changes in the xxx_SERVER lines and the DIR_WS_xxx lines. The SERVER define must not have a slash at the end, and DIR_WS_CATALOG must start with a slash.

I am on a business trip this week so am not able to do testing of PowWeb's install.

You cannot use SSL with the store installed outside the main site's htdocs.