Xen Notices [Deleted]

Can i insert js content inside the notification? I have the idea to use it for a little form (for newsletter registering).
 
Most JS should be ok. I have seen mixed results with this, though.

Do you have an example of the JS you'd need to insert. I'd be happy to try it for you and let you know.
 
I want to create a notification like this (if you try to close the window o change website you will see a notification). In my case, i want a notification that will ask users to register to get a special bonus...

Also, i'm interested to know if it's possible to create a different notification by node (i want to use the Xencentral Multisite), like this:
http://www.hostingtalk.it/forum/

(I think a bigger notification will generate major results...)
 
The notifications allow you to enter any HTML including JS in <script> tags. I added some basic JS:

upload_2014-4-11_20-48-50.webp

So, basically, if you know the JS code you want to use it should be possible to use it in the Notification and produce the results you want.

The criteria used to display Notifications is identical to Notices etc. So you can target specific Notifications to specific nodes with different styling.

The styling is really flexible. Some of the stuff that @Shelley has done is great: http://xenforo.com/community/resources/notifications-gamer-fluid-grey-v2.2033/
 
Great to know...very good work (Shelley is fantastic!). I know with styling you can change appareance...but you can also change the position and the size of the notification? Can i create a notification that opens in the center of window?
 
Yes, that's possible with CSS too.

For example, each notification has a unique ID so you could do something like this:

Code:
#gritter-item-2 .gritter-item
{
    position: fixed;
    top: 50%;
    left: 50%;
    margin-top: -150px;
    margin-left: -250px;
    width: 500px;
    height: 300px;
}

upload_2014-4-11_21-14-3.webp

The beauty of this add-on is, is it's so simple. You can create a notification, display it anywhere, with any colour, and text, and loads more options. But the beauty of the add-on also is how powerful it is.

Obviously the powerful stuff (JS, advanced styling etc) requires work and knowledge to get it to where you want it, but it would be worth the effort.
 
In library/GritterNotifications/DataWriter/Notification.php it is likely defined in there on the test field. Look for maxValue.
 
@Chris D thanks!
I thought that might be the case, so what about adding a "center/user defined" option?
ie:
bottom left
bottom right
center/user defined
top left
top right

is that something that I could do? or something you may concider for a future release?

thanks in advance
Lee
 
I have setup a notice for today's Birthdays but for some reason it is not showing the Birthday for today? It shows in my side block but not as a notice.

Capture15.webp

This is how I have it setup

Capture14.webp

Capture13.webp
 
I see it seemed to come up a bit later after I posted this, is it setup correctly for this type of notification then
 
@Falkor, you've only shown a screenshot of the Notifications Options tab for Notifications. On the Date Criteria tab, have you checked the option Today is user's birthday?
 
That would only show it to the people who have a birthday on that day.

You don't have to set that.
 
Back
Top Bottom