21
Jan304
Re: image manager category gone ?
  • 2003/10/9 18:56

  • Jan304

  • Official Support Member

  • Posts: 520

  • Since: 2002/3/31


First, you should always make a list of files you change, everyone knows there is something like updates...

Second, what if someone discovers a serious security problem in XOOPS and you can't upgrade because you have some files changed, then your site is hacked! What are you going say then, XOOPS team fault?

Just me thinking

22
gstarrett
Re: Upgrading hacked XOOPS (was: image manager category gone ?)
  • 2003/10/9 19:52

  • gstarrett

  • Friend of XOOPS

  • Posts: 174

  • Since: 2002/3/12


Quote:

kjs222 wrote:
I'M AFRAID TO UPGRADE!
I appreciate the advice, and I know the IDEAL is to update; however, the site in question is HIGHLY modified (almost every template, language files, and some php files)... Soo..... I'm hesitant to perform the upgrade.


Hacks! Oh no! (kidding). XOOPS was built OSS, so you can of course. Just don't block yourself from an upgrade path. In general you should keep a pristine copy of the source before you modify it and keep good notes on what you modified and for what purpose.

...but then who is that organized, right?...

1) Get a copy of the original source from CVS of the XOOPS version your site is based on. I posted a quick how-to get it from CVS some time back in the forums.

2) Compare the pristine version to yours. Make notes on what you've changed. There are a number of excellent (and free!) file comparison tools. I use WinMerge, not sure if it compares entire directories at a time though.

3) Use the Template Manager to download your current templates. This will be redundant if you have been modifying the template files in the file system.

4) Get the latest XOOPS. Apply the changes you noted in step 2 to the latest XOOPS, if necessary.

5) Have a beer, you've earned it. Keep your notes and use them next time you need to upgrade.

As an advanced tip, if you do a lot of hacks (or are too lazy to keep good notes), then you should look into using CVS* as the source code management utility. It can store the pristine XOOPS code along with your modifications, all versioned nicely. Import XOOPS on a vendor branch, update it with your changes and re-import onto that vendor branch again when there is an update from XOOPS core.

* I highly recommend CVSNT, it runs on Windows and Linux. Add on TortoiseCVS as the front end, and you're off and running. These packages are extremely useful if you are doing any sort of development, especially when modifying someone else's code to your needs.

23
kjs222
Re: Upgrading hacked XOOPS (was: image manager category gone ?)
  • 2003/10/10 9:57

  • kjs222

  • Friend of XOOPS

  • Posts: 116

  • Since: 2003/3/1 1


I think the next upgrade of XOOPS should come with a "shaking knees" smily . I respect you both, and I appreciate your time in encouraging me to upgrade. I will try it; I hope I don't mess things up!


24
gstarrett
Re: Upgrading hacked XOOPS (was: image manager category gone ?)
  • 2003/10/10 15:21

  • gstarrett

  • Friend of XOOPS

  • Posts: 174

  • Since: 2002/3/12


Don't worry, be happy! Remember these 3 things:

Backup

Backup

When you think you have a good backup, verify it.

Backup => Less fear of change. Verified backup (after practicing restoring it to another location => mere discomfort to the change.


25
Rou4cn
Re: image manager category gone ?
  • 2003/12/1 13:50

  • Rou4cn

  • Just popping in

  • Posts: 16

  • Since: 2003/5/3 1


Quote:

onokazu wrote:
Sorry that I hadn't post anything here, but as knight said, this bug has been fixed on the CVS..


I have the same problem, while I restore the backup from xoops2.0.2 into a new Xoops2.0.5 by phpadmin, the table have all the data, but the image manager shows nothing, only which one is added from xoops2.0.5, even if I add a new one by phpadmin. (I know the strature of the table is not changed).
For example, I have 8 category before, but nothing shows in xoops2.0.5, then I add one, it shows 1 category only , then I add one by phpadmin(total is 10), still only the No.9 showed out.
It seem that some fuction can not automatic update according to the table of xoops_imagescategory.

any one overcome it?

I check the kernel/images*.php between xoops2.0.2 and xoops2.0.5 they are all same.
the /modules/system/admin/images/main.php is not much keywords changed.

Thanks.

26
kjs222
Re: image manager category gone ?
  • 2003/12/1 20:38

  • kjs222

  • Friend of XOOPS

  • Posts: 116

  • Since: 2003/3/1 1


I found a quick fix. The problem is caused by an odd deletion of rows in the group_permissions table.

If you go into that table, you'll it probably has no rows that look like this:

gperm_id = 2509 (primary table ID)
gperm_groupid = 1 (the group # with this permission - 1 is required to see in admin)
gperm_itemid = 7 (this is the image category ID, see img category table)
gperm_modid = 1 (this should be 1 for you too - aka System Module)
gperm_name = imgcat_read

You just need to insert one such row for each itemid (aka image category). Everything else should be in-tact. Not sure what causes the problem, but hopefully this should solve it for you.

If you are unsure of the syntax, you can also go to your image manager, create a new category, and then look at it in the gperm table... then you can just duplicate the entry for each itemid.

Best wishes,
Keith

27
Jan304
Re: image manager category gone ?
  • 2003/12/1 20:44

  • Jan304

  • Official Support Member

  • Posts: 520

  • Since: 2002/3/31


Wasn't this fixed in XOOPS 2.0.5?

I believe when you change permissions it will delete the rows, painfully enough, BUT, it has been fixed.

28
kjs222
Re: image manager category gone ?
  • 2003/12/1 20:56

  • kjs222

  • Friend of XOOPS

  • Posts: 116

  • Since: 2003/3/1 1


FYI, I think the issue on hand is that the fix causes the rows NOT to be deleted, however it doesn't restore the deleted rows... Not positive, but I suspect others might find that info useful.

So, for anyone who upgraded to fix the problem, they still need to re-insert rows (see my comment on how-to do that)

29
Rou4cn
Re: image manager category gone ?
  • 2003/12/3 4:48

  • Rou4cn

  • Just popping in

  • Posts: 16

  • Since: 2003/5/3 1


Quote:

kjs222 wrote:
I found a quick fix. The problem is caused by an odd deletion of rows in the group_permissions table.

If you go into that table, you'll it probably has no rows that look like this:

gperm_id = 2509 (primary table ID)
gperm_groupid = 1 (the group # with this permission - 1 is required to see in admin)
gperm_itemid = 7 (this is the image category ID, see img category table)
gperm_modid = 1 (this should be 1 for you too - aka System Module)
gperm_name = imgcat_read

You just need to insert one such row for each itemid (aka image category). Everything else should be in-tact. Not sure what causes the problem, but hopefully this should solve it for you.

If you are unsure of the syntax, you can also go to your image manager, create a new category, and then look at it in the gperm table... then you can just duplicate the entry for each itemid.

Best wishes,
Keith


done. Thanks.

first make it can be read. then edit it to be writen by the certain grounps. then the row will be added.

Login

Who's Online

383 user(s) are online (255 user(s) are browsing Support Forums)


Members: 0


Guests: 383


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits