Jump to content

Recommended Posts

I have to store my Authorize.net Payment Gateway values somewhere safe.  (i.e. Outside of the Web Root)

 

I tried this code but my checkout page that formerly worked with local values in Test Mode is crashing.  :-[

 

// Include Authorize.net Values.

require_once('/var/www/vhosts/MyWebsite.com/private/auth_config.php');

 

I think the issue is that private maybe can't be read or included by other files?

 

Would using another Linux directory solve my problem?

 

 

Debbie

 

 

Link to comment
https://forums.phpfreaks.com/topic/236352-where-should-i-put-my-include/
Share on other sites

You could, or chmod that file so the user running apache (or your webserver) can read it.

 

I don't follow you...

 

I though this was a Directory Permissions issue...

 

 

Debbie

 

 

chmod is a *nix (linux, Unix) command for changing file and directory permissions.  http://en.wikipedia.org/wiki/Chmod

You could, or chmod that file so the user running apache (or your webserver) can read it.

 

I don't follow you...

 

I though this was a Directory Permissions issue...

 

 

Debbie

 

 

chmod is a *nix (linux, Unix) command for changing file and directory permissions.  http://en.wikipedia.org/wiki/Chmod

 

I know that, but that doesn't answer my original question...

 

Why is my include not working?

 

Is this a Directory Permission issue?

 

A File Permission issue?

 

Both a Directory and File Permission issue?

 

Something else?

 

 

 

Debbie

 

 

You could, or chmod that file so the user running apache (or your webserver) can read it.

 

I don't follow you...

 

I though this was a Directory Permissions issue...

 

 

Debbie

 

 

chmod is a *nix (linux, Unix) command for changing file and directory permissions.  http://en.wikipedia.org/wiki/Chmod

 

I know that, but that doesn't answer my original question...

 

Why is my include not working?

 

Is this a Directory Permission issue?

 

A File Permission issue?

 

Both a Directory and File Permission issue?

 

Something else?

 

 

 

Debbie

 

 

 

It could be anything.  Do you have shell access to your environment, or a FTP program which can modify permissions?  Running ls -l in the shell, or taking a look at the permissions in a FTP program should tell you if you have a permissions issue.

It could be anything.  Do you have shell access to your environment, or a FTP program which can modify permissions?  Running ls -l in the shell, or taking a look at the permissions in a FTP program should tell you if you have a permissions issue.

 

I have SSH access but don't know how to do that, so I'm hoping I can just use what I have in Plesk (i.e. choose a directory with the needed permissions).

 

Here is what Plesk tells me...

 

private

rwx --- ---

 

private/auth_config.php

rw- r-- r--

 

httpdocs

rwx r-x ---

 

 

I am thinking that private needs *Group* or *Other* READ access??  :shrug:

 

Or is this an issue with "auth_config.php" File Permissions?  (An Include/Require should only require a file to be READABLE, right??)

 

 

Debbie

 

I just commented out my Require_Once code and my Check Out form runs properly but displays the message:

 

Sorry! An error occurred.

 

If you need further assistance, please contact Customer Service

 

Without the Require_Once, my code had no Authorize.net keys so it couldn't submit the payment, however, my code correctly caught that and displayed an error to the Customer.

 

What that tells me is that the problem is my Require_Once line of code or something related to it like Permissions.

 

This can't be that hard to fix?!

 

 

 

Debbie

 

 

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.