• Forum
  • Doc
  • Screenshots
  • Download
  • Donate
  • Contributors
  • Contact
  • Follow @phpfreechat
  • DEMO
  • Board index ‹ Version 1.x branch ‹ General Support (v1.x)
  • Change font size
  • FAQ
  • Register
  • Login

Changed command class name, changed back, now command is unk

Moderators: OldWolf, re*s.t.a.r.s.*2

Post a reply
3 posts • Page 1 of 1

Postby FredWelden » Sun Feb 06, 2011 1:36 am

Experimenting with customizing phpfreechat v 1.3 on a WordPress 3.0.4 blog, I changed the name of phpfreechat/src/commands/dice.class.php to rice.class.php to see if that was all that was necessary to change both the name of the command as invoked in the chat and the command as listed in the /help output. Changed it just fine in the /help output, but even after a /rehash, the /rice command was unknown.

That would be only slightly bothersome, but after changing it BACK to dice.class.php, the /dice command still doesn't work, although it shows up fine in the /help output--when I enter /dice 2d20 in the chat, phpfreechat tells me it's an unknown command. /rehash didn't help. Restarting Apache didn't help. Changing the servername so I got a whole new cache (as far as I can tell) didn't help.

I've checked ownership and permissions on the files, and dice.class.php matches all the other commands that are working fine.

What do I need to do to get phpfreechat to find this again as a known command?

Thanks!

--Fred
FredWelden
New member
 
Posts: 2
Joined: Sun Feb 06, 2011 1:24 am
Top

Postby re*s.t.a.r.s.*2 » Sun Feb 06, 2011 3:10 am

just changing the php file wouldn't make the name that was renamed to work as the command name,
you need also to change the extended class itself

read inside and you will see :
Code: Select all
var $usage = "/dice ";

I don't have the dice class in my testbed but I am sure that must be changed also..

and the part that don't work again, must be cache , try deleting the cache folder content and reload a new one.. or try /rehash...
Last edited by re*s.t.a.r.s.*2 on Sun Feb 06, 2011 3:11 am, edited 1 time in total.
Free Singles Chat Rooms No Registration Required
Text and Chat Singles no need to register or app required
Sala De Bate Papo Online Grátis E Sem Cadastro
re*s.t.a.r.s.*2
Support Team
 
Posts: 612
Joined: Wed Sep 24, 2008 4:04 pm
Location: los angeles CA
  • Website
Top

Postby FredWelden » Mon Feb 07, 2011 3:32 pm

Thanks for the fast response!

I understand now why only renaming the file didn't make /rice work as a command. But I'm still no closer to understanding why renaming it BACK didn't re-enable the /dice command, since all I did was rename the file twice. I mentioned in the original post that both a /rehash and changing the servername so I got a whole new hash file didn't help. Neither did restarting Apache. I'm stumped.
FredWelden
New member
 
Posts: 2
Joined: Sun Feb 06, 2011 1:24 am
Top


Post a reply
3 posts • Page 1 of 1

Return to General Support (v1.x)

Who is online

Users browsing this forum: No registered users and 40 guests

  • Board index
  • The team • Delete all board cookies • All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
Sign in
Wrong credentials
Sign up I forgot my password
.
jeu-gratuit.net | more partners
Fork me on GitHub