Activity Stream
48,167 MEMBERS
61062 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Results 1 to 2 of 2
  1.     
    #1
    Member
    Website's:
    bottyz.co.uk

    Default help with activation script php

    Hi all,

    I have a members area, where users sign up using register.php, which then emails us to activate them. We will then log into our admin panel to activate any users not yet activated. Each user will only be allowed specific access to certain areas of the site i.e. if they own 2 products out of four they can only access support pages relating to those products. The access levels will be set when we activate the user. (have i lost you yet? )

    I have the majority of scripts working, the only bit i'm stumped with is the activation. Ideally, i'd like to retrieve all users with the field activated=0 (so not activated) into a table, which i can do and have got set up. Then....

    This is where i get lost: i want to make a form for each user retrieved into the table above, with checkboxes for each area i want to allow them to, all within the same table and once submitted will activate each user at a time.

    Any ideas on the script? I can supply what i have now if needed?

    Thanks!!
    BottyZ Reviewed by BottyZ on . help with activation script php Hi all, I have a members area, where users sign up using register.php, which then emails us to activate them. We will then log into our admin panel to activate any users not yet activated. Each user will only be allowed specific access to certain areas of the site i.e. if they own 2 products out of four they can only access support pages relating to those products. The access levels will be set when we activate the user. (have i lost you yet? ;)) I have the majority of scripts working, Rating: 5

  2.   Sponsored Links

  3.     
    #2
    Member
    Website's:
    Pirateview.org Gfxs.org StarkWood.org
    Code: 
    
    <?php
    
    if(isset($_POST['users_approval'])){
    
    //code to process the form posted.
    
    $users_approval = $_POST['users_approval'];
    $num = count($users_approval);
    
    for( $counter=1; $counter<=$num; $counter +=1){
    
    //make user approve..I will code this later.. i gotta go..
    
    }
    
    
    }
    
    else{
    
    //connect to DB
    
    //Display all accounts who are not activated
    
    $query="Mysql command to get users which is not activated";
    
    $result=mysql_query($query);
    
    $row=mysql_fetch_array($result);
    
    echo "<form  method='POST' action='' >";
    
    while($row['activated']==0){
    
    echo "<input type='checkbox' name='users_approval[]' value=' " .$row['userid']. " ' />" .$row['username']. "<br/>";
    
    }
    
    echo "<input type='submit'  value='Activate' /></form>";
    
    
    }
    
    
    ?>

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Alertpay Activation Help
    By makfun in forum Payza
    Replies: 3
    Last Post: 24th May 2011, 09:39 PM
  2. Activation
    By chemicalx25 in forum Feedback and Suggestions
    Replies: 2
    Last Post: 10th May 2011, 02:33 PM
  3. Activation
    By chemicalx25 in forum Feedback and Suggestions
    Replies: 1
    Last Post: 10th May 2011, 11:40 AM
  4. activation
    By ThaGoon in forum Introductions
    Replies: 3
    Last Post: 11th Mar 2011, 06:24 PM
  5. Windows 7 activation Help
    By shavin in forum Webmaster Discussion
    Replies: 1
    Last Post: 27th Oct 2009, 03:57 AM

Tags for this Thread

BE SOCIAL