SimplePortal

Customization => Blocks and Modifications => Block Requests => Topic started by: S@ffz on July 25, 2011, 12:32:55 AM

Title: Greeting Block
Post by: S@ffz on July 25, 2011, 12:32:55 AM
Would it be possible to have a greeting Block,  that would greet users on the site

Example:

'You are up early' {username}

'Good morning' {username}

Afternoon {username}

Your up late{username}

I have seen this as a Tiny Portal Block do you think it would be possible with Simple Portal?



Title: Re: Greeting Block
Post by: Old Fossil on July 25, 2011, 09:24:25 AM
If you use the Custom Greeting mod then there isn't really much point.

Title: Re: Greeting Block
Post by: S@ffz on July 25, 2011, 11:33:50 AM
If you use the Custom Greeting mod then there isn't really much point.

I didn't know there was one.  Do you know where i can download it?
Title: Re: Greeting Block
Post by: Old Fossil on July 25, 2011, 11:58:45 AM
On sm.org go to the Search box.

Ya can see it working on my forum.
Title: Re: Greeting Block
Post by: S@ffz on August 08, 2011, 05:20:25 PM
the mod is for 2.0 RC3  :(   

I found this code can it be converted to use with sp2.3.3 and smf 2.0?

Code: [Select]
  global $user_info;

 $hour = date('G') + $user_info['time_offset'];

 echo '<span style="text-align:center;">';

if ($hour >= 0 && $hour <= 5) {
        echo 'You are up early ' . $user_info['username'] . '!';
} elseif ($hour >= 6 && $hour <= 8) {
        echo 'Grab your coffee yet ' . $user_info['username'] . '!';
} elseif ($hour >= 9 && $hour <= 12) {
        echo 'Good morning ' . $user_info['username'] . '!';
} elseif ($hour >= 13 && $hour <= 16) {
        echo 'Good afternoon ' . $user_info['username'] . '!';
} else {
        echo 'Good evening ' .  $user_info['username'] . '!';
}
        echo '</span>';
Title: Re: Greeting Block
Post by: Old Fossil on August 08, 2011, 05:54:27 PM
I'm using the mod on 2.0

At the minute it says 'Late Night Tonight

I'm in the UK with the time at 10:54pm
Title: Re: Greeting Block
Post by: S@ffz on August 08, 2011, 07:08:48 PM
Did it install with out any errors?
Title: Re: Greeting Block
Post by: Old Fossil on August 08, 2011, 08:00:28 PM
Can't remember now.

 :-[

http://custom.simplemachines.org/mods/index.php?mod=1388

There's the link for ya.
Title: Re: Greeting Block
Post by: S@ffz on August 09, 2011, 07:29:16 PM
Thanks Brack will test it on test forum first
Title: Re: Greeting Block
Post by: S@ffz on August 09, 2011, 07:39:28 PM
I got this message Brack

Sorry, but this modification does not appear to be compatible with the selected version. :(
Title: Re: Greeting Block
Post by: Old Fossil on August 09, 2011, 07:49:20 PM
I got this message Brack

Sorry, but this modification does not appear to be compatible with the selected version. :(

It works on my 2.0 forum.

Have you tried to emulate?
Title: Re: Greeting Block
Post by: S@ffz on August 11, 2011, 09:06:12 PM
You know what Brack the code does work i just c/p into custom php then preview
and there it was LOL so not need for me to dowload mod  :D
SimplePortal 2.3.8 © 2008-2024, SimplePortal