Results 1 to 8 of 8

Thread: [SOLVED] AJAX Ticker On Login Page

Hybrid View

  1. #1
    Join Date
    Sep 2006
    Location
    Illinois
    Posts
    374
    Rep Power
    9

    Default [SOLVED] AJAX Ticker On Login Page

    Thought I'd post this in case anyone else might have this figured out or knows how to accomplish it. mmorse is already looking at it with me, but the more brains the better.

    Here's the source... Dynamic Drive DHTML Scripts- Advanced RSS Ticker (Ajax invocation)

    Basically the idea would be to create an RSS Ticker on the login page (much like the one at apple.com) to feed news, updates, whatnot to our users.

    The problem seems to be the backend code is PHP and won't run on the Zimbra system so has to be hosted on an external web server. I've got the code added to the login.jsp file to present the ticker to the user, but it's not communicating to the offsite PHP backend. Anyone have thoughts about that?

    Firebug produces these errors...

    Access to restricted URI denied" code:"1012
    XPCSafeJSObjectWrapper.cpp Line 445

    Matt

  2. #2
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    21

    Default

    You're running FF3 and Firebug, aren't you?

    I'm seeing this a lot in dev. Seems to be a firebug/ff3 issue. Restarting the browser should work. Also, try disabling firebug.

  3. #3
    Join Date
    Sep 2006
    Location
    Illinois
    Posts
    374
    Rep Power
    9

    Default

    OK....so the XPCSafeJSObjectWrapper.cpp (line 445) is a red herring?

    I restarted Firefox (yes Firefox 3)...but the code doesn't call the PHP. I'm watching the webserver logs where the PHP is hosted and not getting any hits when I refresh the login page.

    I've added the appropriate RSS Ticker code to login.jsp....
    Code:
    <script src="/zimbra/skins/wiu/rssticker.js" type="text/javascript">
    MORE STUFF HERE
    </script>
    I think that path to the rssticker.js is correct as it's appearing in the Script tab in Firebug.

    Is Zimbra preventing the script from calling out to the external webserver with the error...
    Code:
    Access to restricted URI denied"  code: "1012
    Matt

  4. #4
    Join Date
    Sep 2006
    Location
    Illinois
    Posts
    374
    Rep Power
    9

    Default

    It may be trying to pass the request out through our proxy server back to the local webserver...and doesn't like that.

    Does Zimbra get it's proxy information from the http_proxy/ftp_proxy/no_proxy environment variables?

    Matt

  5. #5
    Join Date
    Sep 2006
    Location
    Illinois
    Posts
    374
    Rep Power
    9

    Default

    Not a proxy problem, so back to the drawing board.

    Matt

  6. #6
    Join Date
    Sep 2006
    Location
    Illinois
    Posts
    374
    Rep Power
    9

    Default A Working Ticker

    Coolio!!

    Test Server

    I had to give up on the RSS Feed idea....AJAX does not work across servers...at least not easily. This code just uses a local XML file(that I placed in our skin folder) for the notices, and can be changed on the fly without restarting Zimbra. I'd just have to write a script to push updates to all servers at once so we only had to change it in one place.

    The data in the XML file is just HTML formatted...so it can look anyway you want practically.

    This is the code I used.... Dynamic Drive DHTML Scripts- Ajax XML Ticker (txt file source)

    If anyone wants the details let me know, but basically I added the required info into the login.jsp file to present the ticker on the login page, and put the ajaxticker.js and tickercontent.txt files in our skin folder.

    Matt

  7. #7
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    Very cool! - makes for a perfect MOTD.

    (Sticking this for a bit- who knows maybe someone will have another RSS idea, or even a good way to parse an rss (stripping other content & adding the div class) > .txt file, then use another script to grab that .txt file from somewhere > skins folder/push to servers.)

    Pics before CSS tweaks:




    Tweaks:
    Last edited by mmorse; 02-20-2009 at 11:56 AM. Reason: pic of tweaks

  8. #8
    Join Date
    Oct 2007
    Location
    North East England
    Posts
    167
    Rep Power
    8

    Default

    Chewie71@: Excellent work! End effect is quite impressive and I admire the design. Thumbs up
    Craig Rodway &#187; Flickr | Last.fm | Del.icio.us | Twitter

Similar Threads

  1. [SOLVED] change "Username:" on login page
    By xtremetoonz in forum Administrators
    Replies: 4
    Last Post: 10-02-2012, 10:44 PM
  2. [SOLVED] Edit Button in Documents Gray After Upgrade
    By weathertation in forum Administrators
    Replies: 10
    Last Post: 05-14-2008, 01:47 PM
  3. [SOLVED] Branding the Login Page
    By kurt.oconnor in forum Administrators
    Replies: 14
    Last Post: 03-17-2008, 03:48 PM
  4. [SOLVED] Login Page Anomaly
    By SpEnTBoY in forum Administrators
    Replies: 6
    Last Post: 12-22-2007, 08:40 PM
  5. Replies: 2
    Last Post: 09-26-2007, 08:48 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •