lol.. Ignore the table aspect of this... we had no choice. I wish we
had an unlimited time / budget / no legacy code base / requirements...
ZF code conventions? Are you referring to the echo short tag? That was
a design decision... It's the only short tag dependent way we use them,
but we also don't have to worry about our code going outside our
company. I've checked and the running opinion is that these will be
continued when short tags go away. We stick to most of them -
sometimes it makes sense to go your own way for a bit. Makes for more
readable code IMO.
We debated a redo, but this was the obvious quick hit... We have
limited time and money, so... Those constants are the only superglobals
we use and we are good with that. We also had to reduce the load on our
pipe, the app serves a lot of static stuff so getting that out was easy.
Change it to a plugin if you want, all you are going to do is spend
cycles sticking in a variable... I think there is a time and place for
tableless design, but I wouldn't tackle it as a first fix without
knowing where the bottleneck is.
On 12/30/09 8:51 AM, Andreas Möller wrote:
>> All my references to anything are like
>>
>> <td background="<?=CDN1?>/styles/images/bg_t0_rightfade.jpg" width="375"
>> valign="top">
>
> Sorry, but this is no good. You are using tables for layout purposes,
> you are using constants ("superglobals"), you are not sticking to ZF
> code conventions (portability of your code?), you are not even using
> inline CSS - where do you want to go with this?
>
>> So during development and testing they can go to one place, then in
>> production the CDN1, etc get set to our Amazon content delivery domains.
>> I do CDN1, CDN2, CDN3 so the browser will do more at once, and in theory
>> render the page faster.Some browsers will only start 10 connections to
>> a single domain I've read, so this allows us to get 30 going quickly.
>> The constant also allows us to be flexible. I suppose you could do them
>> based on what resource they were... Heavy stuff moved off site
>> perhaps... It also works if your traffic goes way up... you can route
>> images from a server that does not do cookies or php, something light
>> and fast.
>
> Start with table-less designs, CSS, and then you can think about
> tweaking other stuff.
>
>> So we sort of round-robin them when assigning them. If the CDN is blank,
>> then it just goes to the root of the site its currently running from.
>>
>> Like I said, I am somewhat new to this, but a constant in there seems a
>> bit less complicated than messing with the controller...
>
> Nope. What about injecting stuff using plugins?
>
>
> Best regards,
>
> Andreas
没有评论:
发表评论