Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Membership Approval


dafoc

Recommended Posts

Hi,

 

I need to have this function so that only those that are given an account can access to the price in the catalog. I've modified the scripts to show prices only to logged-in members. But since everyone can just signup for an account, he can still see the prices by logging in. Therefore, I'd like to know if there is any way that I can approve the membership after a potential signs up, before he can get access to the full catalog. Thanks!

 

David

Link to comment
Share on other sites

based on ver 2.1

1. Remove the password fields on the create_account.php form.

2. Disable the requirement (validation) for passwords on the create_account.php form.

 

New user fills out form and submits it without a password - all information except a password is written to the database (you will need to disable the lost password function - or they could have a system generated password e-mailed to them). Make sure login.php will not accept null passwords.

 

Add password editing to the admin side of editing customer information.

 

Now you have all the registration information - but a customer can't login until you e-mail them a password.

 

hth

-nan

Link to comment
Share on other sites

You will also have to alter create_account_success.php to keep the registrar from automatically being logged on when the account is created successfully. Replacing the code in create_account_success.php with the following will accomplish that:

<? include('includes/application_top.php'); ?>

<?

 tep_session_destroy();

 include('includes/counter.php');

 //header('Location: ' . tep_href_link(FILENAME_DEFAULT, '', 'NONSSL'));

 //tep_exit();

?>

/*<? $include_file = DIR_WS_INCLUDES . 'application_bottom.php'; include(DIR_WS_INCLUDES . 'include_once.php'); ?>

*/

<html>

<head>

<meta HTTP-EQUIV="Refresh" CONTENT="0; URL=http://www.yourdomain.com/catalog/revised_success_page.php">

<title>TITLE</title>

</head>

<body>

</body>

</html>

 

This destroys the logged session (logs them off after automatically logging them on) and redirects them to a custom made success page.

 

-nan

Link to comment
Share on other sites

hi Nancy,

 

Thanks for your help. I think the code for V2.2 is a bit different from V2.1, so I'm a bit confused about where to make the changes. Do you know what to do with the V2.2 code?

 

David

 

based on ver 2.1

1. Remove the password fields on the create_account.php form.

2. Disable the requirement (validation) for passwords on the create_account.php form.

 

New user fills out form and submits it without a password - all information except a password is written to the database (you will need to disable the lost password function - or they could have a system generated password e-mailed to them). Make sure login.php will not accept null passwords.

 

Add password editing to the admin side of editing customer information.

 

Now you have all the registration information - but a customer can't login until you e-mail them a password.

 

hth

-nan

Link to comment
Share on other sites

you can set all new customers to see price with discount 100%

when you update customer status to member the discount is 0% or what you want

 

since i still work on customers status maybe will be hard to make all needed change but will be the 100% solution :)

Link to comment
Share on other sites

The thing is we don't want our competitors to see our prices, so right now people can't see them without being logged in. The problem now is ... if there isn't a membership approval system in place, they can just sign up for a membership and still be able to see the prices.

Link to comment
Share on other sites

when you install customer status

you decide status to set for new customer that are just logging in

For this status you set discount to 100% so the price for all NEW logged customers will be 0 (100% discount of price) and they are able to see all the product's

When you decide this customer is ok you set his status to member or what else and you put discount to 0 so he will see the real price (0% discount of price)

This is the opposite of a membership but it will work this way....

Link to comment
Share on other sites

Right now we only allow logged-in customers to see the price, and it works well. We only need a system to take care of membership, such that only those serious customers, after we contact them, will get the membership and log in to see the prices.

Link to comment
Share on other sites

http://www.itgsm.com/dload-osc/customers_s...atus/for_dafoc/

 

define a new customer by default with 100% discount when he log in

http://www.itgsm.com/dload-osc/customers_s...1_for_dafoc.jpg

 

the price then will look like

http://www.itgsm.com/dload-osc/customers_s...t_for_dafoc.jpg

 

In admin you can search for all new customers that have no special status

http://www.itgsm.com/dload-osc/customers_s...1_for_dafoc.jpg

 

when you are ok for customer, change his status

http://www.itgsm.com/dload-osc/customers_s...s%20history.jpg

 

Then when he log again the price will display all price

 

Sorry screenshot are in french and seems to have some problems for displaying...

i can no more set my admin in other language but i think it is easy to undestand the meaning...

Link to comment
Share on other sites

The thing is we don't want our competitors to see our prices, so right now people can't see them without being logged in. The problem now is ... if there isn't a membership approval system in place, they can just sign up for a membership and still be able to see the prices.

 

What version of OSC are you using? I recently updated the guest_price

contrib to more recent CVS versions of ocs. (a customer must be logged in to see prices).

 

I was going to start adding customer membership to this where by default

there memebership is level 0 when they sign up and the admin must

change to 1 or higher to see prices.

 

After that I was going to add the ability for more pricing levels like admin change to membership level 1 to see regular price, level 2 to see specials

and regular price.

 

When I was looking at Ian Wilson's cvs is when I got the Idea to try this.

since we needed different levels of member ship for diffrent customers.

Link to comment
Share on other sites

Yes. I am using 20020920 cvs to write it, it should work with any version since 2002/08/24. yesterday I got the sql to load the information into the db, and most of code to turn on and off prices is in place.

last night I was able to turn on and off viewing prices by customer member ship level. But I had to manually edit the customer db.

It was not very stable but I will address that by adding membership level to stored session data.

 

now it is hard coded to so that approved member see prices, unregisted and un-approved see a text message saying the must be an approved memeber. registerd members can log in but can not see prices.

text messages are in the english.php to they a be translated to other languages.

 

to do list before this version released:

add edit/change to admin>customer

change customer email to reflect that they need to be approved

add email notifying customer that they have been approved

add member level to stored session data

add same liscense OSC uses

package and post as contribution

 

todo next verion:

add admin control of what memeber level sees for price (specials, list, retail, wholesale ect).

try to create price class controlled by membership level.

 

how long will it take to get is do ? I don't know with luck maybe next week.

something goes wrong a couple of weeks.

 

PS guest_login update, I had has a couple of errors on line number at were to add changes. I will try to get these fixed and reposted

Link to comment
Share on other sites

  • 9 months later...
  • 8 months later...

Just curious if anyone has tested these two contributions together:

http://www.oscommerce.com/community/contributions,1339

and

http://www.oscommerce.com/community/contributions,601

 

I am opening a webshop for collector-to-collector trades, sales and purchases...... Due to certain laws, etc.. I need a way to make sure all new members "must agree" to terms before they can be a member...

 

Thanks

Tammy

Link to comment
Share on other sites

  • 6 months later...

Hi,

I have installed member approval 1.1

 

two problems I have,

1 major and

2 minor

 

1 when a new member signs up I get the email with new member has signed up and awaiting approval, But no new member shows up in

Admin>Customers>awaiting approval

only the members already registered before contrib was installed.

 

any clues as to what may be wrong?

there are now no new entries in the database >customers since i installed.

 

How do I turn this feature off quick to regain functionality? I am very slow at this.

 

2 the admin panel for orders and customers all show heading " Member Approval"

 

any help atall appreciated

thanks all

Link to comment
Share on other sites

  • 1 month later...

Hi all,

 

I'm using the member approval mod by David beck, but I'm having a mare of a time trying to get it working.

 

Basically followed the instructions to the letter, but when a new user tries to sign up it doesn't redirect them to the signup page. It just sits at the login screen. The weird thing is if a regular member clicks on the continue button for signing up, but then puts in their login details and clicks continue, they are redirected to the sign up page!?!

 

I've done something wrong here, I just can't figure it out!

 

As well as the approval mod, I also have the login code on all relevant pages, so people can't view any products unless they login. I think this may be conflicting with the approval mod. I'm still learning PHP so I'm a bit of a beginner, but I am a quick learner ....

 

Please help!! :blink:

Link to comment
Share on other sites

  • 1 month later...

 

The above contrib is the Prices for Logged-In Users Only - I just tried putting this contrib in and I am using a pretty fresh install of OSC. The changes to the files are very confusing as some of the coding that is in the file to be replaced is no where in the actual file I am trying to edit. I had it partially installed, the cart was all screwed up and the prices were all screwed up on the product listing.

 

I have experience installing contribs as this is the 2nd store I'm setting up. So, I did what it said and come to a part that says "change ABC" and go to change ABC and there is no ABC there. (Just using ABC as an example).

 

I would appreciate any help with this contrib.

 

Thanks,

 

Julie

Link to comment
Share on other sites

  • 3 weeks later...
Hi,

I have installed member approval 1.1

 

two problems I have,

1 major and

2 minor

 

1 when a new member signs up I get the email with new member has signed up and awaiting approval, But no new member shows up in

Admin>Customers>awaiting approval

only the members already registered before contrib was installed.

 

any clues as to what may be wrong?

there are now no new entries in the database >customers  since i installed.

 

How do I turn this feature off quick to regain functionality? I am very slow at this.

 

2 the admin panel for orders  and customers all show heading " Member Approval"

 

any help atall appreciated

thanks all

 

Hi ireader,

 

I have exactly the same problem. Did you ever find a fix for it?

 

Any help would be very much appreciated.

Link to comment
Share on other sites

Hi ireader,

 

I have exactly the same problem.  Did you ever find a fix for it?

 

Any help would be very much appreciated.

 

Hi banhoff

No I am sorry, I gave up on that one

But I will looking at again shortly,

If I get a solution I will post here,

If you find one before me, please let me/us know on here

 

Ian

Link to comment
Share on other sites

Hi Ian thanks for the speedy resonse.

 

I'll keep working on it an likewise let you know if I find a solution.

 

Regards,

 

Roly

 

Hi banhoff

No I am sorry, I gave up on that one

But I will looking at again shortly,

If I get a solution I will post here,

If you find one before me, please let me/us know on here

 

Ian

Link to comment
Share on other sites

  • 6 months later...

I'm not sure if this will help anyone or not, but here goes.

 

I installed the Member Approval 1.5 contribution and all went pretty well. It worked until I tried to create a new account. It would redirect me to the create_account.php page, but the screen was blank. I went back over the contributions instructions and I think I found two spots that are incorrect.

 

I'm not 100% certain that I hadn't previously modified this page(/catalog/create_account.php) so that is why I'm posting this in the forums instead of under this contribution's page. If someone can confirm this problem on a clean installation of osC, then maybe you can update the documentation at: http://www.oscommerce.com/community/contri.../search,approve

 

Anyway, here's part of the original documentation for changing /catalog/create_account.php, followed by what i had to change to get this working:

 

## Find this [approx line 233]:  ################################

     } else {
       $email_text = sprintf(EMAIL_GREET_NONE, $firstname);
     }

     $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT . EMAIL_WARNING;
     tep_mail($name, $email_address, EMAIL_SUBJECT, $email_text, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

     tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL'));


## Replace with this:  ################################

   } else {
     $email_text = sprintf(EMAIL_GREET_NONE, $firstname);
   }
 }
   // customer email notification 
   $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT . EMAIL_WARNING;
   tep_mail($name, $email_address, EMAIL_SUBJECT, nl2br($email_text), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

   // admin email notification 

   $admin_email_text .= ADMIN_EMAIL_WELCOME . ADMIN_EMAIL_TEXT . EMAIL_WARNING;

   tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, nl2br($admin_email_text), $name, $email_address, '');

   tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL'));
 }

 

 

Here's how I put it in /catalog/create_account.php to get it to work:

 

 

## Find this [approx line 233]:  ################################

     } else {
       $email_text = sprintf(EMAIL_GREET_NONE, $firstname);
     }

     $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT . EMAIL_WARNING;
     tep_mail($name, $email_address, EMAIL_SUBJECT, $email_text, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

     tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL'));


## Replace with this:  ################################

   } else {
     $email_text = sprintf(EMAIL_GREET_NONE, $firstname);
   }

   // customer email notification 
   $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT . EMAIL_WARNING;
   tep_mail($name, $email_address, EMAIL_SUBJECT, nl2br($email_text), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

   // admin email notification 

   $admin_email_text .= ADMIN_EMAIL_WELCOME . ADMIN_EMAIL_TEXT . EMAIL_WARNING;

   tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, nl2br($admin_email_text), $name, $email_address, '');

   tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL'));

 

Basically, it was just closing some if/else staements improperly.

Link to comment
Share on other sites

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...