The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to Add the Switch Themes Function

Discussion in 'User Experience' started by bajustin, Oct 24, 2006.

  1. bajustin

    bajustin Registered

    Joined:
    Oct 24, 2006
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    I noticed that when you change to Bluelagoon, or Moonsoon, or many other themes they offer no way to change it back. This being Rather disapointing to me, especially when i tried to Find a solution on these forums. So I post this as an unsupported change.

    First from a shell:
    Code:
    cp /usr/local/cpanel/base/frontend/x/switchtheme.html /usr/local/cpanel/base/frontend/themeyouwanttoedit/. 
    
    And then Edit the index.html in /usr/local/cpanel/base/frontend/themeyouwanttoedit/ to include the following lines where ever you feel is astetically pleasing...

    Code:
    
               <form action="switchtheme.html" method="POST" name="tform">
                <table>
                    <tr>
                        <td><span class="switcher-head">Switch Themes:</span></td>
                        <td>
                            <select name="theme" onChange="document.tform.submit();">
                                                    <cpanel Resellers="themelistopt()">
                            </select>
                        </td>
                        <td><input type="submit" class="input-button" value="Go"></td>
                    </tr>
                </table>
               </form>
    
    save and reload. And you will now have it listed on how to change themes.


    Note: I am not responsible if you mess up your install. So try it at your own risk
     
  2. bajustin

    bajustin Registered

    Joined:
    Oct 24, 2006
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    PS:

    If you only want the Resellers to be able to change this...use this code instead.


    Code:
    <cpanelif $isresellerlogin>
    <form action="switchtheme.html" method="POST" name="tform">
                <table>
                    <tr>
                        <td><span class="switcher-head">Switch Themes:</span></td>
                        <td>
                            <select name="theme" onChange="document.tform.submit();">
                                                    <cpanel Resellers="themelistopt()">
                            </select>
                        </td>
                        <td><input type="submit" class="input-button" value="Go"></td>
                    </tr>
                </table>
                </form>
    </cpanelif>
    
     
Loading...

Share This Page