Hello Guys, If my blog posts are helpful to you then give some comment and ratings, if you found any bug also. So that if there are bugs or issues, I can resolve those bugs in next versions.

vBulletin add-on for making Private Message as archived / unarchived

Hello to all,

vBulletin is a forum software that allows users to send Private Messages (PMs) to each other. One of my client used this vBulletin Forum. He wants an addon that will show a list of all the PMs in the DB and if you click one, it should show the contents of the PM. This will run in the administrator control panel, so only the admins can use this add-on.

If admin feels the message is spam, he can select the PM and click an "archive" button and it will copy the message out of the live PM tables to some backup tables, so the message won't get delivered to site member.

Later on, if admin decided that the message is NOT spam, there will be an "un-archive" button to remove it from the backup tables and put it back into the live PM tables.

To achieve this I developed an add-on, which will help admin to make PM's archived or unarchived.


click here to get the code.. unzip and follow the instructions...


Installtion Instructions:

1. Upload the below two files in specified path below.

forum_folder/admincp/all_pms.php
forum_folder/includes/xml/cpnav_allpms.xml

2. Import the forum.sql file from PhpMyAdmin



Creat a full Installation Package of your developed site in Joomla

Hello to all Joomla! fans,

If you have developed a template or custom component for Joomla, you can provide with a custom Joomla installation package that includes your demo setup to your clients by following the below steps.
  • Create a separate copy to your developed site's folders and files.
  • Very Important: Remove the "configuration.php" file.
  • Go to Joomla.org, Download and save the standard Joomla installation package for the version you are using to develop the site.
  • Extract the standard Joomla installation package and/or Save the "installation" folder to your developed Site copy folder.
  • Go to phpMyAdmin and Export a copy of the database with Structure, Data and Drop Table options.
  • Save file the sql file to your developed site copy folder as "\installation\sql\mysql\developed_site_folder_name.sql"
  • Select all folders and files of the developed site copy folder and zip those.
  • Now your installation file is complete.
  • You can gave that zip file to your clients.
  • They can install your site as Standard Joomla Installation
Hope this helps Joomla Fans like me :)

Show Categories & Sub-Categories in a tree format

This post will explain how to show categories and sub-categories in a tree format in a directory.

Example:
We need to create a table called `categories` and the table Fields:
" id ", this should be a int(11), primary, and auto-increment.
" name ", this should be varchar(255) [ Name of the category ]
" parentid ", this should be int(11), [ " id " of the Parent category, if this is a sub-category, If  " parentid " is 0, that means the category is a top-level category ]

Code for display Categories Dropdown:
$connection = mysql_connect('localhost', 'root', '');
if (!$connection) {
   die('Could not connect: ' . mysql_error());
}

$db = mysql_select_db ('test1', $connection);
$sql = "SELECT * from categories order by name ASC";
$cats = mysql_query($sql) or die("Could not select category");

echo "<select name="category">";
recall (0,0,$cats);
echo "</select><br>";

Function recall() is the actual function that is going to generate the tree structure for our categories and sub-categories. We initially pass it values of 0,0,and $cats for its root, depth, and the actual query data. We pass is 0 and 0 for root and depth because initially we want to start from top level directories.

Follow fornandakishore on Twitter