UberCMS - Site path and name!

Results 1 to 22 of 22
  1. #1
    Account Upgraded | Title Enabled! Akimbo is offline
    MemberRank
    Jul 2011 Join Date
    NorwayLocation
    305Posts

    smile UberCMS - Site path and name!

    Hi guys! Its been a long time now.. But, here is a small release from me ;) However, if you want to change your hotel name from hk, then you shall add this!
    Go in global.php hit ctrl + h
    Search for:
    PHP Code:
    $cron->Execute(); 
    Under that add this:
    PHP Code:
    // ############################################################################
    // Load Settings

    $query dbquery("SELECT value,name FROM settings ORDER BY title ASC");
    while(
    $setting mysql_fetch_array($query))
    {
        
    $setting['value'] = str_replace("\"""\\\""$setting['value']);
        
    $settings[$setting['name']] = $setting['value'];
    }
    mysql_free_result($query);

    $core->setting = &$settings;

    define("SHORTNAME"$settings['hotel_shortname']);
    define("HOTELNAME"$settings['hotel_name']); 
    One step done.
    Okay, now go to /inc/class.tpl.php
    Search for
    PHP Code:
    $this->SetParam('www'WWW); 
    Add under that this:
    PHP Code:
            $this->SetParam('shortname'SHORTNAME);
            
    $this->SetParam('hotelname'HOTELNAME); 
    Now go to /inc/tpl/head-init.tpl. Open it and search for
    PHP Code:
    <title
    Replace the whole line with:
    PHP Code:
    <title>%shortname%: %page_title%</title
    I think that is it, its preatty useless really, but good for noobs! Oh wait, i forgot to add the MySQL!
    PHP Code:
    --
    -- 
    Table structure for table `settings`
    --

    CREATE TABLE IF NOT EXISTS `settings` (
      `
    titleint(255NOT NULL,
      `
    valuevarchar(255NOT NULL,
      `
    namevarchar(2553NOT NULL
    ENGINE=MyISAM DEFAULT CHARSET=latin1;

    --
    -- 
    Dumping data for table `settings`
    --

    INSERT INTO `settings` (`title`, `value`, `name`) VALUES
    (1'Habbo''hotel_shortname'),
    (
    3'Habbo Hotel''hotel_name');
    -- -------------------------------------------------------- 
    Tell me if it not are working!

    Update:
    Open global.php, search for:
    PHP Code:
    $core->setting = &$settings
    Add under it:
    PHP Code:
    define("WWW"$settings['hotel_path']); 
    New sql:
    PHP Code:
    INSERT INTO `settings` (`title`, `value`, `name`) VALUES
    (2'http://localhost''hotel_path'); 
    Remove from inc/inc.config.php
    PHP Code:
    $config['Site']['www'] = "http://localhost"
    Credits: Tweeney 90%
    Me: Fixing it up.
    Last edited by Akimbo; 08-12-11 at 03:13 PM. Reason: Credits


  2. #2
    Account Upgraded | Title Enabled! Muscab is offline
    MemberRank
    Oct 2009 Join Date
    264Posts

    Re: UberCMS - Site name (Small release)

    Are you for real?

    On topic : Reasonable release.

  3. #3
    "(still lacks brains)" NoBrain is offline
    MemberRank
    Sep 2011 Join Date
    United KingdomLocation
    2,658Posts

    Re: UberCMS - Site name (Small release)

    This could be so much better, without using MySQL. Nice release though.

  4. #4
    Garry's Mod is addictive! Law is offline
    MemberRank
    Dec 2009 Join Date
    NorwayLocation
    993Posts

    Re: UberCMS - Site name (Small release)

    Uhm, just go into head-init, and write the name of your hotel before : %page_title% ? What's so hard about that?

  5. #5
    Account Upgraded | Title Enabled! Akimbo is offline
    MemberRank
    Jul 2011 Join Date
    NorwayLocation
    305Posts

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by Law View Post
    Uhm, just go into head-init, and write the name of your hotel before : %page_title% ? What's so hard about that?
    I really dont know ;)

    Quote Originally Posted by Muscab View Post
    Are you for real?

    On topic : Reasonable release.
    What the fuck do you mean about that?

  6. #6
    Account Upgraded | Title Enabled! nickymonsma is offline
    MemberRank
    Sep 2009 Join Date
    The NetherlandsLocation
    232Posts

    Re: UberCMS - Site name (Small release)

    Yeeehhh You rocks dude this is usefull thanks this is realy Nice you the fucking damm shit good codes dude I love it :D and yes im stoned :p

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

    Re: UberCMS - Site name (Small release)

    Lol, haters this is here to make the title be editable via Housekeeping. If you did the configuration document updating through housekeeping that would mean CHMODDING to 777 which could cause security holes...

    @OP - I love it :D

  8. #8
    Garry's Mod is addictive! Law is offline
    MemberRank
    Dec 2009 Join Date
    NorwayLocation
    993Posts

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by Hejula View Post
    Lol, haters this is here to make the title be editable via Housekeeping. If you did the configuration document updating through housekeeping that would mean CHMODDING to 777 which could cause security holes...

    @OP - I love it :D
    Still easy enough to edit it in the head-init.php.

    Plus, they have to configure their hotel within inc.config.php? so why not just create a new variable there, and add that variable to the head-init? no need for that in the housekeeping then.

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

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by Law View Post
    Still easy enough to edit it in the head-init.php.

    Plus, they have to configure their hotel within inc.config.php? so why not just create a new variable there, and add that variable to the head-init? no need for that in the housekeeping then.
    Why make something harder then it needs to be? A simple housekeeping text box makes life easier then having to go onto your server, then go all the way into a file just for 1 thing. Time which can be better spent.

  10. #10
    Demi-God tweeney is offline
    MemberRank
    Aug 2008 Join Date
    888Posts

    Re: UberCMS - Site name (Small release)

    Nice release - Should be helpful :)
    But why do I have 90% of the credits?

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

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by Hejula View Post
    Why make something harder then it needs to be? A simple housekeeping text box makes life easier then having to go onto your server, then go all the way into a file just for 1 thing. Time which can be better spent.
    You choose a name, edit the cms with it, never look back.

    Conclusion: Adding this to your cms is much more work then doing a simple edit

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

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by joopie View Post
    You choose a name, edit the cms with it, never look back.

    Conclusion: Adding this to your cms is much more work then doing a simple edit
    Some people like to put version numbers on there hotels... for example Joopie Hotel V1

  13. #13
    swagggggg Livar is offline
    MemberRank
    Oct 2008 Join Date
    United KingdomLocation
    2,272Posts

    Re: UberCMS - Site name (Small release)

    Nice release.

  14. #14
    Account Upgraded | Title Enabled! Akimbo is offline
    MemberRank
    Jul 2011 Join Date
    NorwayLocation
    305Posts

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by tweeney View Post
    Nice release - Should be helpful :)
    But why do I have 90% of the credits?
    Bcus, i did see the stuff on torpeedo cms :)

  15. #15
    sexiess is a sin. Subway is offline
    MemberRank
    Jun 2010 Join Date
    2,491Posts

    Re: UberCMS - Site path and name!

    Waste of coding like Law said.

  16. #16
    Enthusiast JayNZ is offline
    MemberRank
    May 2011 Join Date
    New ZealandLocation
    34Posts

    Re: UberCMS - Site path and name!

    Poor mysql server..

  17. #17
    Account Upgraded | Title Enabled! Akimbo is offline
    MemberRank
    Jul 2011 Join Date
    NorwayLocation
    305Posts

    Re: UberCMS - Site path and name!

    lol, what about phoenixPHP and CF then? ;)

  18. #18
    Gamma Spamma Liam is online now
    MemberRank
    Dec 2011 Join Date
    Down UnderLocation
    2,945Posts

    Re: UberCMS - Site path and name!

    All this was already coded into UberCMS.

  19. #19
    Proficient Member Squard is offline
    MemberRank
    Dec 2011 Join Date
    155Posts

    Re: UberCMS - Site name (Small release)

    Quote Originally Posted by ησвяαιη View Post
    This could be so much better, without using MySQL. Nice release though.
    Doesn't matter if we cache the data.

    BTW: If you use this with the %shortname% on the CMS. The Emulator have to know that Thoo to replace all the 'Uber' words or whatever.

  20. #20
    Account Upgraded | Title Enabled! Chapo is offline
    MemberRank
    Jul 2010 Join Date
    United StatesLocation
    944Posts

    Re: UberCMS - Site path and name!

    Mmmm dont get it...

  21. #21
    Infraction Banned HallaHotel is offline
    MemberRank
    Mar 2011 Join Date
    AustriaLocation
    60Posts

    Re: UberCMS - Site path and name!

    Nice and Thank you it's awesome

  22. #22
    :joy: Jonteh is offline
    MemberRank
    Apr 2007 Join Date
    New York, USALocation
    3,372Posts

    Re: UberCMS - Site path and name!

    Nice work, but Uber is so dynamic it's simple to change..



Advertisement