51
kahumbu
Contact Us From Name Hack
  • 2004/5/12 20:10

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


This small hack will let you reply to emails from the Contact Us module using the username as the "From Name" instead of the site name. This means that you will get "User Name<useremail@domain.com>" instead of "Site Name<useremail@domain.com>".

Open and edit ../modules/contact/index.php

Line 75:

from:
$xoopsMailer->setFromName($xoopsConfig['sitename']);

change it to:
$xoopsMailer->setFromName($usersName);

Ain't that simple?



52
kahumbu
Re: Default Who's Online never shows guests
  • 2004/5/12 16:54

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


Quote:

poehoes wrote:
Is it possible to let an anonymous user see how many people (users and guests) are online, but not the link with userinfo?


Here are threads that might help:

Link 1
Link 2
Link 3



53
kahumbu
Re: Xoops looks great is IE and Opera but in firefox it looks like it is Unstyled or without any CSS
  • 2004/5/11 18:47

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


Is this consistently happening? When I use Firebird, this happens sometimes but after a reload/refresh, everything goes back to normal.

If nothing works, you might want to reinstall as you seem to have installed XOOPS improperly by putting the whole package in there, instead of just what's inside the html/ folder. I could even browse the docs/ folder in your site.



54
kahumbu
Re: News Sub-menu
  • 2004/5/11 18:09

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


They should only show up if you are in the News module. XOOPS.org has the News as Start Page that's why it shows up when it first loads.

If your site is not configured to start with the News Mod, it will not show up. Go to your News mod and check if it comes up.



55
kahumbu
Re: Logged in notification
  • 2004/5/11 18:06

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


This is what I used within my theme.html when I implemented something similar before.

<{php}>
global 
$xoopsUser;
if (!
$xoopsUser
{
$username "Guest";
}
else
{
$username $xoopsUser->getVar('uname');
}
echo 
"<b>$username</b>";
<{/
php}>


Try experimenting with that. You can place the echo part inside the conditionals if you want.



56
kahumbu
Re: Changing copyright info
  • 2004/4/20 19:54

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


This link should help you out.



57
kahumbu
Re: Hack
  • 2004/4/18 6:17

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


Thanks, Dave_L! I had the gut feeling that the $myts-> was not needed.

Thanks for the heads up on the $_SERVER. When I did the hack, I checked the script and I saw $HTTP_POST_VARS so I thought I'd just stick with standard syntax used.

In the next versions, will $_POST, $_GET, etc be used instead of the long way?




58
kahumbu
Hack
  • 2004/4/17 16:37

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


I had the same idea, so after not finding any solution, I decided to dig in the code.

This hack will let you receive username, email and IP of the new user (if you wanted to receive notifications on new registration).

First, make a new file regnotify.tpl in language/english/mail_template/ containing this text:
new user has registered:

Username: {USERNAME}
Email: {USEREMAIL}
User IP: {USERIP}


You could change that, of course, but keep those {variables}.

Second, open up register.php and add the hack around Line 266-267:
$xoopsMailer->useMail();
[
b]// Start of Hack[/b]
$xoopsMailer->setTemplate('regnotify.tpl');
$xoopsMailer->assign('USERNAME'$myts->oopsStripSlashesGPC($uname));
$xoopsMailer->assign('USEREMAIL'$myts->oopsStripSlashesGPC($email));
$xoopsMailer->assign('USERIP'$myts->oopsStripSlashesGPC($HTTP_SERVER_VARS['REMOTE_ADDR'] ));
[
b]// End of Hack[/b]
$member_handler =& xoops_gethandler('member');


Finally, comment out this line:
//$xoopsMailer->setBody(sprintf(_US_HASJUSTREG,$myts->oopsStripSlashesGPC($uname)));


I would like to get comments from the devs about using the $myts->... syntax with the REMOTE_ADDR var. I was just going along with the syntax of the other vars. I'm not exactly sure if I needed to do that.

For now, it works on my site. Hope this helps others. Feedback appreciated.



59
kahumbu
Re: combine news from different sites
  • 2004/4/17 16:12

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


That is possible through the Headlines module. Just use www.yoursite.com/backend.php as the source feed.



60
kahumbu
Re: Newbie Theming
  • 2004/4/17 16:07

  • kahumbu

  • Documentation Writer

  • Posts: 277

  • Since: 2003/8/23


Maybe this link can help.




TopTop
« 1 ... 3 4 5 (6) 7 8 9 ... 27 »



Login

Who's Online

197 user(s) are online (116 user(s) are browsing Support Forums)


Members: 0


Guests: 197


more...

Donat-O-Meter

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

Latest GitHub Commits