[PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

Page 1 of 2 12 LastLast
Results 1 to 25 of 30
  1. #1
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    It's been a while since I coded something usefull for the Habbo section. Some people might've already downloaded my beta releases in the releases section, but you couldn't really do much with it.

    What is QuickTPL?

    It's a CMS/Framework with a multi-tpl system etc in it made for Habbo Retros. It's sorta like Frost 3.0, but I'm coding it from scratch and I think it may have a new name.

    Why QuickTPL?

    It's fast (5ms per page with mysql pconnect), has cron jobs, easy to code pages for with the use of my handler scripts:

    articles.php
    PHP Code:
    <body id="news">
    <?php $this->inc('head'); ?>



    <div id="column1" class="column">

    <div class="habblet-container ">


    <div class="cbb clearfix default ">



    <h2 class="title">Articles</h2>


    <div id="article-archive">
    <h2>Latest articles</h2>

    <ul>
    {newsList}
    </ul>

    </div>
    </div>

    </div>



    </div>





    <div id="column2" class="column">

    <div class="habblet-container ">
    <div class="cbb clearfix notitle ">
    <div id="article-wrapper">
            
    <h2>{newsTitle}</h2>


    <div class="article-meta">Posted by {newsAuthor}</div>

    <p class="summary">{newsShortstory}</p>

    <div class="article-body">
        {newsLongstory}<br/><br/>
    </div>

    </div>

    </div>
    </div>



    </div>

    </div><div id="footer"><?php $this->inc('footer'); ?></div></div></div>
    It has auto CSS & JS scripts just like RevCMS so you don't need to put your CSS links on top of every page.

    Screenshots?
    I'll make them today, look at my site:
    Hablow.nl

    Login with name: 'Admin', pass: 'admin' to see the housekeeping.

    I've almost completed QuickTPL, I just need to finish the housekeeping functions and CSS.

    QuickTPL/Configuration.php
    PHP Code:
    <?php
    if(!defined('Start')) exit('403');

    class 
    Config {
        
    ## Your QuickTPL basic settings
        
    static $name        'Hablow';
        static 
    $style        'habbo';

        
    ## Your default 'Page Not Found' file
        
    static $errorfile        'error';

        
    ## These are your MySQL Connect Settings
        
    static $DB = Array(
            
    'hostname'    => 'p:127.0.0.1',
            
    'loginname'    => 'root',
            
    'password'    => 'admin',
            
    'database'    => 'quicktpl',
        );

        static 
    $hk_rank = Array(
            
    'basics'        => 3,
            
    'news'        => 4,
            
    'bans'        => 5,
            
    'users'        => 6,
            
    'ranks'        => 6,
            
    'site'        => 7
        
    );

        
    ## The time your login-cookies will stay valid
        
    static $cookie_time        216000;

        
    ## Your password hash
        
    static $hash_function    'md5(sha1($input))';

        
    ## This is for hard-blocking any ip (For DoSers)
        
    static $blocked_ips        = Array(
            
    'someip',
            
    'anotherip',
            
    'thirdip',
            
    'moreips',
            
    'etc'
        
    );

        
    ## Your twitter account
        
    static $twitter         '_AmirZ_';
    }
    ?>


  2. #2
    nyan. Doctorate is offline
    MemberRank
    Sep 2012 Join Date
    NarniaLocation
    332Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Nice. Good luck.

    Edit: Your Demo/Test site is offline atm :S

  3. #3
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    It's up now, try it

  4. #4

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Very nice development, AmirZ. I loved the other versions of QuickTPL, but this one will be even better!

    Good luck!

  5. #5
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Finished some new pages in the housekeeping, I'm open for suggestions (small widgets etc)

    Edit: Started on safety. I need someone to make some good texts for me, otherwise I'm going to rip them from Habbo.
    Last edited by azaidi; 27-12-12 at 11:46 PM.

  6. #6
    Member CookieMonst is offline
    MemberRank
    Jul 2012 Join Date
    62Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    So, this is a framework? Meaning, we can build our projects on this? Anyhow, holy santa shit. This loads fast.

  7. #7
    Owner of Habbo.ac iRaged is offline
    MemberRank
    Nov 2011 Join Date
    229Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Your test website is down again. Looking forward to this release and can't wait to check out those speeds :)

  8. #8
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    It's up again.

    - Made a simple /home/name script
    - Made a simple change password
    - Made a 'password forgot' script for staff in HK
    {
    It will make the password of that user empty. The user can login without password, then change it in profile. He can't enter the client without changing his password.
    }

    - Made a /feedback & /help (FAQ) page
    - Made a /safety page

    Speed of /safety:
    <!--QuickTPL Loaded in 0.0059947967529297 seconds-->

    Speed measure works like this:
    First thing on QuickTPL.php is define('Start', microtime(true));

    Last thing is $TPL->Output('<!--QuickTPL Loaded in '.(microtime(true) - Start).' seconds-->');

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

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Fuck your password forgot system.

    What if I enter his/her details and say i forgot it?!

  10. #10
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    No it's not that. I mean only staff with the rank you choose can go in the housekeeping and reset the password to empty (I mean nothing). You have to contact the staff by sending a mail or using the feedback function on another account in the CMS.
    Then the user can login without a password. But he/she has to change it before entering the client.

    - Added look in /manage/users
    - Added staff list in /manage/users

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

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by azaidi View Post
    No it's not that. I mean only staff with the rank you choose can go in the housekeeping and reset the password to empty (I mean nothing). You have to contact the staff by sending a mail or using the feedback function on another account in the CMS.
    Then the user can login without a password. But he/she has to change it before entering the client.

    - Added look in /manage/users
    - Added staff list in /manage/users
    I know you mean it good. but that means every idiot can email the staff to reset "their" password.

    Wouldn't be better to send a mail with a url to reset their password instead?

  12. #12
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by joopie View Post
    I know you mean it good. but that means every idiot can email the staff to reset "their" password.

    Wouldn't be better to send a mail with a url to reset their password instead?
    Most people don't know how to set up a mail server..

    - Added Register IP + Last IP in /manage/users

  13. #13
    The one and only! Hejula is offline
    MemberRank
    Nov 2008 Join Date
    4,128Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by azaidi View Post
    Most people don't know how to set up a mail server..

    - Added Register IP + Last IP in /manage/users
    They don't have to. You can use the Windows Live servers, and I would recommend checking out BrickPHP (by joopie) to see how it's done :)

  14. #14
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by Hejula View Post
    They don't have to. You can use the Windows Live servers, and I would recommend checking out BrickPHP (by joopie) to see how it's done :)
    I might code it as a plugin later.

    By the way I've put back the account 'Admin' (pass 'admin') so people can see the Housekeeping again :)

    - Made some minor changes in the user class

    - Made some minor changes to the cache class

    New demo link from someone testing my CMS: www.minesam.de
    (He doesn't want you to register so I made a hotel password script)

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

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by azaidi View Post
    Most people don't know how to set up a mail server
    Most people dont know, you dont need your own mail server..

    I think that is what you mean :)

  16. #16
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Made a lot of changes to System.php and class_site.php
    - Made some minor changes to class_template.php and class_includes.php

  17. #17
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Small speed decrease due to improvements in stability (Don't worry, just 4ms added)
    - Added extra things in Configuration.php
    - Edited layout of System.php

    - Made some small changes to the housekeeping & client

    Housekeeping is now ca 6ms

  18. #18
    nyan. Doctorate is offline
    MemberRank
    Sep 2012 Join Date
    NarniaLocation
    332Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Checked out the Demo site.
    Great work. Keep it up.

  19. #19
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Made a lot of changes to class_user.php (Session, cookie and get data)
    - Added a min staff rank to not get banned with a ban
    - Added $DB->Select(SELECT $fields FROM $table WHERE $key = '$value')

  20. #20
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Edited /home/X a lot (Made it more habboish)
    - Fixed the motto bug where it could be more than 32 chars
    - Fixed the capital/non capital username bug
    - Fixed the register bug on new databases

    It is release-able now.
    Btw extra demo: Subba.hablow.nl (From my friend)

    Newest updates on: Hablow.nl

    System.php snippet:

  21. #21
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Fixed a bug with the client
    - Quickly made a /credits and /credits/pixels (Didn't add them to the header because I don't like them)
    - Fixed a bug in /manage/client about the motd with \r\n

    Shall I release it tomorrow or 1 januari?

  22. #22
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    - Only shortstory in the big news widget
    - /manage/users now shows the latest 10 registered accounts

    I can't get the wordfilter to work, but everything in the database is correct..
    Last edited by azaidi; 30-12-12 at 10:45 PM.

  23. #23
    Alpha Member Emily is offline
    MemberRank
    Oct 2012 Join Date
    The NetherlandsLocation
    2,408Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by azaidi View Post
    - Only shortstory in the big news widget
    - /manage/users now shows the latest 10 registered accounts

    I can't get the wordfilter to work, but everything in the database is correct..
    How do you use wordfilter?

    If you use string replace (str_ireplace) make sure you define the new text.

    Like this:

    PHP Code:
    $lol 'boobs';
    $body 'hello I like boobs';

    $body str_ireplace($lol'******'$body); 

  24. #24
    Planning Stuff Since 2013 Vrop93 is offline
    MemberRank
    Jan 2012 Join Date
    Grocery StoreLocation
    320Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Nice job AmirZ, Can't wait until it's released ;) Good luck on your project and getting the word filter to work.

  25. #25
    I don't even know azaidi is offline
    MemberRank
    Apr 2010 Join Date
    the NetherlandsLocation
    2,065Posts

    Re: [PHP, MySQLi, OOP] QuickTPL 1.0 - New Year Release

    Quote Originally Posted by Tha View Post
    How do you use wordfilter?

    If you use string replace (str_ireplace) make sure you define the new text.

    Like this:

    PHP Code:
    $lol 'boobs';
    $body 'hello I like boobs';

    $body str_ireplace($lol'******'$body); 
    Nah I just mean it the noob way, I'm using Phoenix with it by the way (Might release a butterfly compatible user class)

    When I insert the values into the database phoenix doesn't filter them (Probably because of my crack)



Page 1 of 2 12 LastLast

Advertisement