Category: Working with PHP Melody

  • Featured Channels

    The “Featured Channel” option allows you to promote and provide a higher visibility to certain accounts form your user base.

    Depending on the project’s requirements, the “featured channel” mark can be used to:

    • Highlight accounts with high quality content form your user base
    • Promote accounts in exchange for payment
    • Organize the content based on the type of user
    • Target specific users based on their interests (in development)

    This feature was introduced in PHP Melody v2.6 and is part of the “Social Module”.

  • Show hidden files on a Mac

    Update: You can download an app (Funter) to do all the work for you.

    PHP Melody includes several files beginning with a dot (e.g. .htaccess). If you’re using a Mac OS to upload the PHP Melody into your server, you’ll have to first make the .htaccess files visible in Finder or your FTP app.

    To show hidden files, first open up the Terminal app. If you’ve never used this, it’s here:

    Appli­cations → Utilities → Terminal

    A quick note before you do anything: using Terminal without knowing what you’re doing can really screw up your computer. It’s not unsafe to do, you just have to be very careful not to type in any commands that you don’t intend to. As such make sure you’ve read the code below carefully and have typed it exactly as written! You have been warned.

    Okay now, right after the dollar sign you can go ahead and type or paste in the code below, and press enter.

    defaults write com.apple.finder AppleShowAllFiles TRUE

    Nothing will happen yet, because you need to restart Finder for the changes to take effect. To do this, you can either press option+command+esc to open the Force Quit Appli­cations window, select Finder from the list and hit “Relaunch”, or simply type in the code below in the Terminal window, and again press enter.

    killall Finder

    If you typed those lines correctly, your desktop icons should disappear for just a second while Finder restarts and the code in your finder window will look like the image screenshot below.

    Now any hidden files on the system should be visible. If you’re not seeing the file you expected, it’s possible that your FTP client is not configured to pull down those hidden files, so you may need to check those settings also. And remember, deleting any system files can break stuff on your computer—if you’re going to go through this process, make sure you’re only editing stuff you know is pertinent to your site, like the .htaccess file.

    [Source]

  • How to rename the ‘admin’ folder in PHP Melody

    Starting with PHP Melody v2.2 you can easily move/rename PHP Melody’s ‘admin‘ folder.

    You may want to do this for several reasons all concerning the security of your website. Let’s see how you can rename the ‘admin‘ folder without breaking PHP Melody.

    Step 1.

    Open /config.php and find this line:

    define('_ADMIN_FOLDER', 'admin');

    Replace the ‘admin‘ value with your new folder name (e.g. admin2015). Edit only the underlined bit. Make sure there are no empty spaces between the single quotes.

    Save and upload /config.php to your installation.

    Step 2.

    Rename your ‘admin‘ folder to match the new folder name (i.e. admin2015).

    That’s it. Job done!

  • How to create ad zones in Mobile Melody v2.x

    As you know, PHP Melody comes with pre-made ad zones for the ‘Classic banners’.

    However, if you want to add ads to your Mobile Melody layout, you need to create new ad zones. This is because, unfortunately most banners do not come with responsive support. Having separate ad zones for Mobile Melody will also enable you to easily track you mobile traffic revenue separately form your regular (desktop) site.

    To add your first ads on Mobile Melody, you need to log into the PHP Melody back-end and go to “Advertisements > Classic Banners” page. Click the “Create new ad zone” and in the “name” field (the first form field) use any of these names:

    • mobile_header
    • mobile_footer
    • mobile_video
    • mobile_article

    Mobile Melody will recognize and display these ads them as follows:

    • mobile_header: appears in the header
    • mobile_footer: appears in the footer
    • mobile_video: appears after the video player
    • mobile_article: appears after the article

    Here is a screenshot to get you started, but if you have any questions please contact the support team.

    How to add Mobile Melody ads