[pre-release] dev cms

Page 3 of 3 FirstFirst 123
Results 51 to 63 of 63
  1. #51
    Apprentice TruCluez is offline
    MemberRank
    Nov 2013 Join Date
    10Posts

    Re: [pre-release] dev cms

    ok, um isn't this wabbo/wubbo cms if not then nice edit I guess?

  2. #52
    .io developer JPride is offline
    MemberRank
    Sep 2013 Join Date
    The Next LegendLocation
    481Posts

    Re: [pre-release] dev cms

    TrueCluez, It's devCMS

    [Pre-release]


    Many thanks

    - ValorAngel

  3. #53
    Banned rafa95123 is offline
    BannedRank
    May 2009 Join Date
    /home/RaphaLocation
    564Posts

    Re: [pre-release] dev cms

    Well, i'm not expert in this area... But i did a little code to verify if email is already registered... Isn't a GREAT fix, but... :)

    1° Go to private/application/library and open the class.user.php, then search for this public function user_name($username), then add this after void founded:
    PHP Code:
    public function user_mail($username)
        {
            GLOBAL 
    $db;
            
    $query = ('SELECT mail FROM users WHERE mail = ? LIMIT 1');
            if (
    $statement $db->prepare($query))
            {
                
    $statement->bind_param('s'$username);
                
    $statement->execute();
                
    $statement->bind_result($username);
                
    $statement->fetch();
                
    $statement->close();
                return (
    $username);
            }
        } 
    2° Go to private/application/theme/public and open the login.php, then search for this:
    PHP Code:
    else if ($usr->user_name($_POST['reg_username']))
            {
                
    $errors[] = 'Please enter an username that does not already exist.';
            } 
    After of found, add this:
    PHP Code:
    else if ($usr->user_mail($_POST['reg_email']))
            {
                
    $errors[] = 'Please enter an email that does not already exist.';
            } 
    Now you will have a verification of email!
    If have something wrong with code, tell me, i'm new in PHP :p

  4. #54
    Account Upgraded | Title Enabled! Predict is offline
    MemberRank
    Aug 2008 Join Date
    760Posts

    Re: [pre-release] dev cms

    Quote Originally Posted by rafa95123 View Post
    Well, i'm not expert in this area... But i did a little code to verify if email is already registered... Isn't a GREAT fix, but... :)

    ...
    Great work (:

    Sorry I haven't been active with the project, recently.
    What I've done since the last update, I've changed, renamed, removed and updated the directories, I somewhat like the new folder structure and when you get chance, please give feedback.

    I've modified some of the code inside the library.html.php (previously class.html.php) that I saw a few flaws inside. The users_search function doesn't want to play ball, so I'm going to leave the function as it is and move onto something else. Moreover to Housekeeping, infact. I really need to recode the .CSS for the layout because it doesn't work properly in some browsers, I'm hoping to keep the code the same.

  5. #55
    Banned rafa95123 is offline
    BannedRank
    May 2009 Join Date
    /home/RaphaLocation
    564Posts

    Re: [pre-release] dev cms

    Well man, tell me one thing... to do the client, is hard? xD

  6. #56
    Im Back! PythoneX12 is offline
    MemberRank
    Sep 2010 Join Date
    634Posts

    Re: [pre-release] dev cms

    Not 100% sure of this as i just skimmed through ur code. I believe this line:

    $statement->bind_param('s', '%'.$user.'%');

    need to be

    $statement->bind_param($query, '%'.$user.'%');

    Due to the fact that its calling ur query to select users then selecting the user as follows.

  7. #57
    Live Ocottish Sverlord Joopie is offline
    LegendRank
    Jun 2010 Join Date
    The NetherlandsLocation
    2,773Posts

    Re: [pre-release] dev cms

    Quote Originally Posted by PythoneX12 View Post
    Not 100% sure of this as i just skimmed through ur code. I believe this line:

    $statement->bind_param('s', '%'.$user.'%');

    need to be

    $statement->bind_param($query, '%'.$user.'%');

    Due to the fact that its calling ur query to select users then selecting the user as follows.
    PHP: mysqli_stmt::bind_param - Manual



    Fuck, where's the dislike button when you need it.

  8. #58
    Im Back! PythoneX12 is offline
    MemberRank
    Sep 2010 Join Date
    634Posts

    Re: [pre-release] dev cms

    Oh hes using it differently. If u use it the way im using its the way i posted lol

  9. #59
    Live Ocottish Sverlord Joopie is offline
    LegendRank
    Jun 2010 Join Date
    The NetherlandsLocation
    2,773Posts

    Re: [pre-release] dev cms

    He uses the MySQLi library without a wrapper arround it. I assume you do. Look better before you post things like that. It looks like you're a idiot.

  10. #60
    Im Back! PythoneX12 is offline
    MemberRank
    Sep 2010 Join Date
    634Posts

    Re: [pre-release] dev cms

    Oh ya sorry didnt notice that now that i looked at his code lol

  11. #61
    Account Upgraded | Title Enabled! Predict is offline
    MemberRank
    Aug 2008 Join Date
    760Posts

    Re: [pre-release] dev cms

    I've been pretty busy for the past week, but here's the new template class that'll I'll be using from now on. Basically I didn't like the fact that the template class (original) was using two classes and that there were functions inside the class that weren't needed etc.

    PHP Code:
    <?php
    if (!defined('INDEX'))
    {
        exit (
    '<h1>Access denied</h1><p>You do not have the privileges to access this webpage.</p>');
    }

    class 
    template
    {
        private 
    $template NULL;
        private 
    $input = array ();
        private 
    $output;

        public function 
    template ($string)
        {
            
    $this->template $string;
        }
        
        public function 
    template_page ()
        {
            
    extract ($this->input);
            
            
    $input = ('resources/resources_private/private_template/template_private/'.$this->template.'.tpl');
            
            if (
    file_exists($input))
            {
                
    ob_start ();
                include (
    $input);
                
    $output ob_get_contents ();
                
    ob_end_clean ();
                
                return 
    $this->template_filter_input ($output);
            }
            else
            {
                exit (
    '<h1>Access denied</h1><p>Template ('.$this->template.') does not have the privileges to access this webpage.</p>');
            }
        }
        
        private function 
    template_filter_input ($string)
        {
            foreach (
    $this->input as $input => $output)
            {
                if (
    is_object($output))
                {
                    continue;
                }
                
                
    $string str_ireplace ('%'.$input.'%'$output$string);
            }
            
            return 
    $string;
        }
        
        public function 
    template_input ($input$output)
        {
            
    $this->input[$input] = is_object ($output) ? $output->fetch () : $output;
        }
        
        public function 
    template_output ()
        {
            
    $this->output .= $this->template_page ();
            echo 
    $this->template_filter_input ($this->output);
        }
    }
    ?>

  12. #62
    Enthusiast xSeebaa is offline
    MemberRank
    Mar 2013 Join Date
    30Posts

    Re: [pre-release] dev cms

    Database for this cms?

  13. #63
    Valued Member Xversion is offline
    MemberRank
    Mar 2012 Join Date
    LocalhostLocation
    144Posts

    Re: [pre-release] dev cms

    Notice: Undefined index: p in C:\xampp2\htdocs\xabbo2\index.php on line 12

    Notice: Undefined variable: result in C:\xampp2\htdocs\xabbo2\private\application\library\class.html.php on line 44

    Notice: Undefined variable: result in C:\xampp2\htdocs\xabbo2\private\application\library\class.html.php on line 392

    Notice: Undefined variable: errors in C:\xampp2\htdocs\xabbo2\private\application\theme\public\login.php on line 89
    I get those errors, and can we please have the database file? prefer if its compatible with Butterstorm



Page 3 of 3 FirstFirst 123

Advertisement