#1 (permalink)  
Old 05-13-2008, 09:21 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Multiple Categories MOD for Links

OK, here is my idea for multiple categories. I think this is a workable concept and was fairly easy to implement. While I struggled a little with the SQL statement, the code is actually pretty easy.

The primary purpose of the MOD is to show the INDEXU programmers that it is not all that hard to do. Having said that, they will need to deal with "removing" additional_cat1 and additional_cat1 from the code.

What it does: It allows the link owner to add an unlimited number Multiple Categories for one link. That is to say, the link can appear in many categories. The link owner can change which categories the link can appear in. or the link owner can remove all additional categories so that the link only appears in its main category.

Just a couple of things:
  1. Please do not post to this thread
  2. Currently the MOD is only designed to work with v5.4
  3. Make sure you back up your files before installing
  4. Use at your own risk
  5. Do not consider this a completed MOD.
  6. I do not support this MOD
  7. If you use this MOD, you owe me $0.05 (a nickel)
If you want to post anything to this thread, please post Click here to Discuss the Multiple Categories MOD.

I'm asking bruce to move any posts to this thread. In return, I'll edit this post and keep it current.

I make no guarentees about this MOD. There is lots of code for the INDEXU's official version of multiple categories. I have not looked at all of it to see if there is a conflict with this MOD. The MOD seems to work but you have been warned. I have ignored as much as I could the code for additional_cat1 and additional_cat1. If the MOD bombs after using it for some period of time, the only thing you are entitled to is a refund of what you paid for it.

There are things that probably need to but haven't benn don't yet. Primarily because I don't know what they are. I'll try to add them when I learn them. With "try" being the operative word. For example, there is no way for the admin to edit the idx_mcats file (this file holds the multiple categories for any link); you will need to use a SQL statement to edit the table or delete entries. The MOD does not currently allow for multiple categories during the add process.

Which brings me to support of this MOD. There is none. I'll try to help but don't count on it. I won't install it. If you can't get it to install, then ask someone else to help you.

If you use this MOD, you owe me a nickel which you can pay me the next time we meet.

Now for the general instruction for the MOD
  1. Run the query to create the idx_mcats table
  2. Install the new browse.php file or edit your existing browse.php file
  3. Add the BuildTreeRecMC and DisplayCategoryListBoxMC functions to the end of the category.class.php file.
  4. Add two lines to the Modify function in the link.class.php file
  5. Install the new modify.php file or edit your existing modify.php file
  6. Change the modify_form.html to replace the current multiple categories with the new one


.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.

Last edited by esm; 05-14-2008 at 04:26 AM.
Reply With Quote
  #2 (permalink)  
Old 05-13-2008, 09:23 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 1

1. Run the following SQL statement in the Database, Query section of the Admin Control Panel or from phpmyadmin
Code:
Content visible to License Owner only.

.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #3 (permalink)  
Old 05-13-2008, 09:24 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 2

2. Replace the existing browse.php file with the following code (or make the indicated changes)
Code:
Content visible to License Owner only.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #4 (permalink)  
Old 05-13-2008, 09:28 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 3

3. Open the category.class.php file. Go to the bottom of the file and add the following just before the last } (left curly brace) which is just before ?>.

Remember, put it just before the the LAST }

Code:
Content visible to License Owner only.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #5 (permalink)  
Old 05-13-2008, 09:30 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 4

4. Edit the link.class.php file and find the folling section of code (about line 1784)

Code:
Content visible to License Owner only.

and make the following changes
Code:
Content visible to License Owner only.

.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #6 (permalink)  
Old 05-13-2008, 09:35 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 5

5. In the modify.php file make the indicated changes to the ShowFormModifyUrl function


Code:
Content visible to License Owner only.
In the modify.php file make the indicated changes to the ProcessFormModifyUrl function

Code:
Content visible to License Owner only.
then further down

Code:
Content visible to License Owner only.

.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #7 (permalink)  
Old 05-13-2008, 09:37 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default Step 6

6. Edit the modify_form.html file and find the folling section of code

Code:
Content visible to License Owner only.
and replace the two sections that refer to the Additional Category with the new section for Multiple Categories

Code:
Content visible to License Owner only.

.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
  #8 (permalink)  
Old 05-13-2008, 09:39 PM
esm's Avatar
esm esm is offline
Active Member
 
Join Date: Apr 2003
Location: Atlanta GA
Posts: 3,411
esm is on a distinguished road
Default

Please do not post to this thread. Click here to discuss.

.
__________________
esm
"The older I get, the more I admire competence, just simple competence, in any field from adultery to zoology."

.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple Categories? blacknight v5.x 3 10-10-2006 09:01 PM
Multiple categories ? Frank71 v5.x 7 08-13-2004 10:42 AM
Multiple Categories MOD esm v5.x 9 08-04-2004 12:39 AM
Add multiple categories at once craven v5.x 2 08-29-2003 01:21 PM
multiple categories... rayhne Pre-Sales Questions 13 05-08-2003 12:32 AM

HACKER SAFE certified sites prevent over 99.9% of hacker crime.

All times are GMT -5. The time now is 03:32 PM.


Powered by vBulletin®
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO
SSL Certificate