One easy, one not-so-easy question

Skinning and designing Serendipity (CSS, HTML, Smarty)
Post Reply
RedBaron
Regular
Posts: 32
Joined: Wed Mar 18, 2009 2:09 pm

One easy, one not-so-easy question

Post by RedBaron »

I am forever indebted to Don Chambers for all his help on getting to grips with S9Y and helping me code some areas of my website. Taking me under his wing and talking me down from "jumping off"
I have a couple of supplementary questions, which I really ought to post in forums instead of Skyping him into submission!

Easy one first (I think)

1. There's a bit of real estate in the Bulletproof header I could lose. How do I modify my user.css file to reduce the header depth by about half?

More difficult:

2. Embedded in my bulletproof template is an area (top, centre) which displays some PHP code. Now, correct me if I'm wrong, but if this area was an iframe, I would be able to "refresh" it without a full page refresh? The PHP script outputs the "now playing" information and displays it here - but when the song changes, the information doesnt update without a full page reload.
My winamp plugin sends an http POST header right after it updates the .xml file with the new information, which would be the flag to redraw the iframe.

Any coding help on the above would be gratefully appreciated.

oh, my website is [url]http://fuzzyfm.com]HERE[/url]

Thanks in advance
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: One easy, one not-so-easy question

Post by yellowled »

RedBaron wrote:1. There's a bit of real estate in the Bulletproof header I could lose. How do I modify my user.css file to reduce the header depth by about half?

Code: Select all

#serendipity_banner { height: 70px; }
No idea about 2., sorry :)

YL
RedBaron
Regular
Posts: 32
Joined: Wed Mar 18, 2009 2:09 pm

Re: One easy, one not-so-easy question

Post by RedBaron »

Thanks YL - guess that can go anywhere in the user.css

Good job
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: One easy, one not-so-easy question

Post by yellowled »

RedBaron wrote:Thanks YL - guess that can go anywhere in the user.css
You're welcome.

Basically yes. You might wanna sort CSS statements in your user.css in order to still be able to find them as the user.css grows, though.

YL
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: One easy, one not-so-easy question

Post by garvinhicking »

Hi!

About #2: You can't detect a server file time change in an iframe. That means, the iframe would need to continuusly redraw itself (no matter if your song changed or not).

That puts an awful lot of performance power on the server, it hugely inreases your page click rates, server traffic, and client traffic. And the client will see the iframe flicker every now and then.

In short: It's not worth the effort. I also doubt your users need to see when your song changes in real-time; if they do, you should think about a Flash widget or Java Applet instead. Those are able to perform continuous updates in a more lightweight way. But those still eat up performance.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply