History: ContactUs Doc (obsolete)
Preview of version: 7
- Turn on the UserMessages feature to allow the users to contact you via the built in message system when using the Contact Us page.
Contact Us (anonymous)
remember to enabled the Contact Us and user Messaging features, set a contact name on Admin->General and let anonymous use the messaging system permission
Annonymous Contact Feature (Tikiwiki 1.8.2)
If you want anonymous users to be able to contact site admin, but NOT contact users from forums etc. as the above would allow them to do, a couple of changes need to be made to some files to make the anonymous contact feature work (Yes it exists, it just is hidden from view and needs some light PHP modding).
Point 1, in 1.8.2 the tiki_preferences table in the usual database stuff does include a preference called "contact_anon" and, by default, its value is set to 'n', First step is to change this to 'y'. You can hop into the database with your favourite admin tool, PHPMyAdmin in my case and just edit the entry, OR we can modify the admin > General page to include a little tick-box for it underneath the "Contact User" text box.
To do this we have to edit the PHP and the template AND the PHP files entitled:
tiki-admin_include_general.tpl
and
tiki-admin_include_general.php
but, because I'm such a nice fellow, I'm going to attach modified versions of the files to this page (great arent I?) The .tpl file, belongs in the tiki/templates folder, and the PHP file belongs in the tiki/ folder.
Next we have to make a change to the PHP file for the contact us feature, because, although it tests to see if abnonymous is allowed to see it, it doesn't actually do anything with the messages anonymous messages once they are submitted.
Again I'll just plug in an attachment with the corrected file, all I did was copy the code from the execution block for the registere users and paste it in for the anonymous users. We could go about modifying everything so we don't have duplicate code and we have a slightly more complex decision structure, but who can be bothered for such a small file anyways?
So with the files modded (Or copied into place) You chould - finally - be able to go into admin > general, enter the contact user (admin is the best bet really), tick the anonymous contact tickbox underneath it, "change preferences" and hooray!
Anonymous Contact fully functional!! And Anonymous can't message other users!!
If you want to know exactly what I edited in the files attached, see the readme file 😉
Chances are now, that someone will point out that this has aalready been fixed (in blah blah blah release) Oh well, it was fun.
RW