Motto changing site [EACH CMS]

Results 1 to 16 of 16
  1. #1
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Motto changing site [EACH CMS]

    Hello, I have a hibbocms edit with change motto on site.
    I made it by myself with help from the login thing.
    I'm going to give you codes

    1. Put this onto your .php file in motto section:
    PHP Code:
    <form method="post" action="">
    <
    input class="motto" id="motto" type="text" name="motto" value="%motto%"/>
    <
    input type="submit" id="login-submit-button" class="submit" value="Update je motto"/></form
    2. Put this in your <?php and ?> section:
    PHP Code:
    if (isset($_POST['motto']))
    {
    $motto filter($_POST['motto']);
    $query mysql_query("UPDATE users SET motto = '".$_POST['motto']."' WHERE id = '".USER_ID."'");

    Works, you only have to reload.
    I don't care: hate it or love it, but don't flame. It take 20 minutes of my live to code it and make it work.


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

    Re: Motto changing site [EACH CMS]

    I guess its OK, if you want to make your own CMS from scratch. ^ ^
    (Considering every stable CMS has a similar SQL table)

  3. #3
    Banned c0mma is offline
    BannedRank
    Jan 2011 Join Date
    ^RaGEZONE^Location
    696Posts

    Re: Motto changing site [EACH CMS]

    I want to make a CMS from scratch, but idk where to start from :L

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

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by ***** View Post
    I want to make a CMS from scratch, but idk where to start from :L
    Knowing PHP / HTML would help.

  5. #5
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by ***** View Post
    I want to make a CMS from scratch, but idk where to start from :L
    Add my msn webmaster@hotelhebbo.nl and I'd like to help ya out

  6. #6
    Banned c0mma is offline
    BannedRank
    Jan 2011 Join Date
    ^RaGEZONE^Location
    696Posts

    Re: Motto changing site [EACH CMS]

    lol i don't go on MSN much o_o

  7. #7
    Account Upgraded | Title Enabled! TheOleg is offline
    MemberRank
    Apr 2008 Join Date
    EstoniaLocation
    570Posts

    Re: Motto changing site [EACH CMS]

    PHP Code:
    if (isset($_POST['motto'])) 
    $query mysql_query("UPDATE users SET motto = '".filter($_POST['motto'])."' WHERE id = '".USER_ID."'"); 

  8. #8
    Old Habbo Developer AresCJ is offline
    MemberRank
    Jan 2009 Join Date
    USALocation
    1,183Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by Rav4eG View Post
    PHP Code:
    if (isset($_POST['motto'])) 
    $query mysql_query("UPDATE users SET motto = '".filter($_POST['motto'])."' WHERE id = '".USER_ID."'"); 
    That snippet reminds me so much of HoloCMS, honestly..

  9. #9
    Account Upgraded | Title Enabled! TheOleg is offline
    MemberRank
    Apr 2008 Join Date
    EstoniaLocation
    570Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by AresCJ View Post
    That snippet reminds me so much of HoloCMS, honestly..
    lol
    or at least just use filter you did
    PHP Code:
    if (isset($_POST['motto'])) 

    $motto filter($_POST['motto']); 
    $query mysql_query("UPDATE users SET motto = '".$motto."' WHERE id = '".USER_ID."'"); 


  10. #10
    Old Habbo Developer AresCJ is offline
    MemberRank
    Jan 2009 Join Date
    USALocation
    1,183Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by Exacto View Post
    why use SQL Queries, it just makes the CMS more slower, isn't there a way not to use them?
    It's only (1) query, so what kind of BIG difference could it make using ONE query for the Motto, I could understand if it was like 10-15 lines of queries being inputted into the Motto, but it's only one so no harm done.

  11. #11
    Old Habbo Developer AresCJ is offline
    MemberRank
    Jan 2009 Join Date
    USALocation
    1,183Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by Exacto View Post
    it will when the whole CMS is just made up of SQL Queries
    Well, build me a CMS with NO SQL queries, let's see how this functions..

  12. #12
    Banned 2000 is offline
    BannedRank
    Jul 2011 Join Date
    AustraliaLocation
    18Posts

    Re: Motto changing site [EACH CMS]

    thank you for this code i have been looking for this for ages!!!!!!!

  13. #13
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Re: Motto changing site [EACH CMS]

    @2000 Then you must be very old?.. No a joke lolz.
    Random question: should I make a CMS from scratch?

  14. #14
    Thanks for a great time! siem212212 is offline
    MemberRank
    Jun 2009 Join Date
    NetherlandsLocation
    958Posts

    Re: Motto changing site [EACH CMS]

    Quote Originally Posted by George2000 View Post
    @2000 Then you must be very old?.. No a joke lolz.
    Random question: should I make a CMS from scratch?
    w/e you want but you cant quit when started , else people will hate you, xD

  15. #15
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Re: Motto changing site [EACH CMS]

    Okay, I'll make one. It will have the style of HibboCMS but only the CSS file. Rest I'll code at my own.

  16. #16
    BFH Experience Loader Mininova is offline
    MemberRank
    Oct 2007 Join Date
    WonderlandLocation
    724Posts

    Re: Motto changing site [EACH CMS]

    ok i test how long i need:

    <?php
    $motto = htmlspecialchars($_POST['motto']);
    if(isset($motto){
    mysql_query("UPDATE users SET motto = '".$motto."' WHERE id = '".$user['id']."'");
    }
    ?>
    <form action="#" method="POST">
    <input type="text" value="<?php echo $user['motto'] ?>" name="motto">
    <input type="submit" value="Change">

    ok i need without any help (Written from my Brain) 1 Minute ^^ (I must answer an Friend in Steam xD)
    Last edited by Mininova; 14-07-11 at 03:58 PM.



Advertisement