[wp-hackers] wp-hackers Digest, Vol 67, Issue 58

Ryan Hellyer ryan at pixopoint.com
Tue Aug 17 03:53:46 UTC 2010


> From: Chip Bennett <chip at chipbennett.net
> Subject: Re: [wp-hackers] Twenty Ten theme issue?
>
> If actual resized images exist, why on earth would WordPress then be
> performing additional, rendered resizing via IMG attributes? (Perhaps when
> the advanced-option resizing is performed for an inserted image?)

Yes. That is (I assume) where the confusion comes from in that
WordPress does not physically resize the images when using the
advanced-option resizer. I thought you also used to be able to resize
them via dragging the edge in the wysiwyg editor, but I noticed on
testing that it doesn't work like that anymore (which is a good thing
IMO as users could make a real mess of things by uploading a super
huge image and dragging the corners of it to force it to fit).

Users editing the width and height tags via the code editor will still
run into problems even if the images are physically resized, but I'm
not sure there is a solution to that problem, or at least not one
which won't create even more bugs by fixing it.

This is a squirrely problem and one I'd never even thought of before.
There's probably a whole can of worms to be opened with fluid width
sites and this sort of behaviour too.


cheers,
Ryan






On Tue, Aug 17, 2010 at 2:50 PM,
<wp-hackers-request at lists.automattic.com> wrote:
> Send wp-hackers mailing list submissions to
>        wp-hackers at lists.automattic.com
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://lists.automattic.com/mailman/listinfo/wp-hackers
> or, via email, send a message with subject or body 'help' to
>        wp-hackers-request at lists.automattic.com
>
> You can reach the person managing the list at
>        wp-hackers-owner at lists.automattic.com
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of wp-hackers digest..."
>
>
> Today's Topics:
>
>   1. Re: Twenty Ten theme issue? (Nathaniel Taintor)
>   2. Re: Amount of estimated developer-hours in Wordpress?
>      (Christopher Ross)
>   3. Re: wp-atom2.php (Brian Layman)
>   4. Re: Amount of estimated developer-hours in Wordpress?
>      (Jacob Santos)
>   5. Re: wp-atom2.php (David Morris)
>   6. Re: TwentyTen Theme issue (Ryan Hellyer)
>   7. Re: Twenty Ten theme issue? (Chip Bennett)
>   8. Re: wp-atom2.php (Otto)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 16 Aug 2010 16:02:11 -0400
> From: Nathaniel Taintor <goldenapplesdesign at gmail.com>
> Subject: Re: [wp-hackers] Twenty Ten theme issue?
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTinf_7LU1s8j08SLsPfm2tNuago55AHE+nyYkrPX at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> WP does perform actual resizing of images... check your uploads folder, for
> most images uploaded, there are three or four resized images saved...
> 'thumbnail', "small", "medium", "large", and "original" by default, although
> you can add more image sizes through theme or plugin functions.
>
> I've often added custom image sizes through my functions.php like this:
>
> add_image_size('new-custom-size', 400,9999); // resize to 400px wide, for
> example...
>
> and then specified the size in my style:
>
> img.size-new-custom-size { width: 400px; }
>
> thinking it would give me slightly quicker page rendering.
>
> Are you saying that's not correct? The only issue I can see is if the
> original uploaded image was smaller than that size, but in that case - from
> what I understand, the custom size isn't created in the first place and that
> class won't be used.
>
> Best,
> Than
>
>
> From: Chip Bennett <chip at chipbennett.net>
>> Subject: Re: [wp-hackers] Twenty Ten theme issue?
>>
>> Wouldn't the correct long-term solution be to have WP perform *actual*
>> resizing of images, such that each image had Original, Thumbnail, Small,
>> Medium, and Large instances (a la Flickr)?
>>
>> Chip
>>
>> On Mon, Aug 16, 2010 at 10:23 AM, Otto <otto at ottodestruct.com> wrote:
>>
>> > On Mon, Aug 16, 2010 at 5:33 AM, Rich Pedley <elfin at elfden.co.uk> wrote:
>> > > But there is also a case for the width and height attributes on the img
>> > > (isn't it still recommended?).
>> >
>> > It's recommended to have them in order to give browsers a hint as to
>> > their size for layout, but it's still wrong to use them for resizing.
>> >
>> > Yes, yes, lots of people use it that way. Still wrong because CSS
>> > takes precedence over those attributes. We should fix WP to do the
>> > right thing here, I'd say. Should be simple enough to do, really.
>> >
>> > -Otto
>> >
>>
>
>
> ------------------------------
>
> Message: 2
> Date: Mon, 16 Aug 2010 17:02:48 -0300
> From: Christopher Ross <cross at thisismyurl.com>
> Subject: Re: [wp-hackers] Amount of estimated developer-hours in
>        Wordpress?
> To: wp-hackers at lists.automattic.com
> Message-ID: <7DC9EA2F-2A9D-4D77-9A19-6A3D1C9037E2 at thisismyurl.com>
> Content-Type: text/plain; charset=windows-1252
>
> Yes, the $2.4 million represents the total value of WordPress across all versions. I think we read the original request differently as I thought he meant the total value of the final release, excluding plugins etc.
>
>
> On 2010-08-16, at 4:41 PM, Charles Frees-Melvin wrote:
>
>> Your sum negates the lines of code that used to be in wp. Also the number of lines of code that were in revisions of patches that formed the final patch. I
>> --
>> Charles E. Frees-Melvin
>>
>> Sent from my Rogers iPhone 3G
>>
>> On 2010-08-16, at 16:03, Christopher Ross <cross at thisismyurl.com> wrote:
>>
>>> Here's the number ?
>>>
>>> Average lines of code per day (per developer) - 10 *
>>>
>>> Average cost of developer (Can) - $45,250 **
>>> Average cost of dev/day (Can) - $181
>>> Average cost per line of code (Can) - $18.10
>>>
>>> Lines of Code in WordPress - 136,347 ***
>>>
>>> Development days for WordPress = 13,635
>>> Development cost for WordPress = $2,467,935
>>>
>>> * http://stackoverflow.com/questions/2894099/10-lines-of-code-per-day-is-the-global-average-true
>>> ** http://www.payscale.com/research/CA/Job=PHP_Developer/Salary
>>> *** http://www.ohloh.net/p/wordpress/analyses/latest
>>>
>>>
>>>
>>>
>>> On 2010-08-16, at 12:42 PM, Adriaan Pelzer wrote:
>>>
>>>> Hi,
>>>>
>>>> Does anyone know the estimated amount of developer hours in Wordpress
>>>> (latest release, no themes or plugins).
>>>> I want to use this in an argument of platform-based vs bespoke.
>>>>
>>>> Adriaan Pelzer
>>>> RAAK Ltd
>>>> http://www.wewillraakyou.com
>>>> +4478 7978 1743
>>>> _______________________________________________
>>>> wp-hackers mailing list
>>>> wp-hackers at lists.automattic.com
>>>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>>
>>>
>>> __
>>>
>>> Christopher Ross
>>>
>>> Toronto      1 (416) 840-5828
>>> Fredericton 1 (506) 474-2708
>>> New Orleans 1 (504) 322 3485
>>>
>>> http://christopherross.ca
>>> http://www.thisismyurl.com
>>>
>>> _______________________________________________
>>> wp-hackers mailing list
>>> wp-hackers at lists.automattic.com
>>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
>
> __
>
> Christopher Ross
>
> Toronto      1 (416) 840-5828
> Fredericton 1 (506) 474-2708
> New Orleans 1 (504) 322 3485
>
> http://christopherross.ca
> http://www.thisismyurl.com
>
>
>
> ------------------------------
>
> Message: 3
> Date: Mon, 16 Aug 2010 19:34:39 -0400
> From: "Brian Layman" <bulk at thecodecave.com>
> Subject: Re: [wp-hackers] wp-atom2.php
> To: <wp-hackers at lists.automattic.com>
> Message-ID: <006201cb3d9b$98b82020$ca286060$@com>
> Content-Type: text/plain;       charset="us-ascii"
>
> The other question is, what is in your wp-atom.php file...
>
> ______________________________________________
> Brian Layman
> eHermits, Inc.
>
> -----Original Message-----
> From: wp-hackers-bounces at lists.automattic.com
> [mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of David Morris
> Sent: Monday, August 16, 2010 2:56 PM
> To: wp-hackers at lists.automattic.com
> Subject: Re: [wp-hackers] wp-atom2.php
>
> What might have caused it to be renamed?
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
>
>
> ------------------------------
>
> Message: 4
> Date: Mon, 16 Aug 2010 18:45:06 -0500
> From: Jacob Santos <wordpress at santosj.name>
> Subject: Re: [wp-hackers] Amount of estimated developer-hours in
>        Wordpress?
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTimLEOg4Bja5VHgMXfXrGxWV_u4Gqr3-9_FZ+ALF at mail.gmail.com>
> Content-Type: text/plain; charset=windows-1252
>
> Actually, given the feature set, any sane developer would instead build off
> an existing framework decreasing the amount of time it would take to a
> fraction. Many of the lines of code are helper functions, which aren't
> required and thus lowers the required amount of code needed to recreate
> WordPress.
>
> However, if one was going to simply recreate WordPress, they'd be better off
> writting a CMS with blogging capabilities.
>
> Jacob Santos
>
>
>
> On Mon, Aug 16, 2010 at 2:46 PM, Arlen Beiler <arlenbee at gmail.com> wrote:
>
>> 34 Person years means it would take 34 people one year or one person
>> 34 years to do that. Correct?
>>
>> On Mon, Aug 16, 2010 at 3:41 PM, Charles Frees-Melvin <wordpress at cefm.ca>
>> wrote:
>> > Your sum negates the lines of code that used to be in wp. Also the number
>> of lines of code that were in revisions of patches that formed the final
>> patch. I
>> > --
>> > Charles E. Frees-Melvin
>> >
>> > Sent from my Rogers iPhone 3G
>> >
>> > On 2010-08-16, at 16:03, Christopher Ross <cross at thisismyurl.com> wrote:
>> >
>> >> Here's the number ?
>> >>
>> >> Average lines of code per day (per developer) - 10 *
>> >>
>> >> Average cost of developer (Can) - $45,250 **
>> >> Average cost of dev/day (Can) - $181
>> >> Average cost per line of code (Can) - $18.10
>> >>
>> >> Lines of Code in WordPress - 136,347 ***
>> >>
>> >> Development days for WordPress = 13,635
>> >> Development cost for WordPress = $2,467,935
>> >>
>> >> *
>> http://stackoverflow.com/questions/2894099/10-lines-of-code-per-day-is-the-global-average-true
>> >> ** http://www.payscale.com/research/CA/Job=PHP_Developer/Salary
>> >> *** http://www.ohloh.net/p/wordpress/analyses/latest
>> >>
>> >>
>> >>
>> >>
>> >> On 2010-08-16, at 12:42 PM, Adriaan Pelzer wrote:
>> >>
>> >>> Hi,
>> >>>
>> >>> Does anyone know the estimated amount of developer hours in Wordpress
>> >>> (latest release, no themes or plugins).
>> >>> I want to use this in an argument of platform-based vs bespoke.
>> >>>
>> >>> Adriaan Pelzer
>> >>> RAAK Ltd
>> >>> http://www.wewillraakyou.com
>> >>> +4478 7978 1743
>> >>> _______________________________________________
>> >>> wp-hackers mailing list
>> >>> wp-hackers at lists.automattic.com
>> >>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>> >>
>> >>
>> >> __
>> >>
>> >> Christopher Ross
>> >>
>> >> Toronto      1 (416) 840-5828
>> >> Fredericton 1 (506) 474-2708
>> >> New Orleans 1 (504) 322 3485
>> >>
>> >> http://christopherross.ca
>> >> http://www.thisismyurl.com
>> >>
>> >> _______________________________________________
>> >> wp-hackers mailing list
>> >> wp-hackers at lists.automattic.com
>> >> http://lists.automattic.com/mailman/listinfo/wp-hackers
>> > _______________________________________________
>> > wp-hackers mailing list
>> > wp-hackers at lists.automattic.com
>> > http://lists.automattic.com/mailman/listinfo/wp-hackers
>> >
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
>
>
> ------------------------------
>
> Message: 5
> Date: Mon, 16 Aug 2010 19:44:22 -0500
> From: David Morris <dvmorris at gmail.com>
> Subject: Re: [wp-hackers] wp-atom2.php
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTiktuoYvxa2gBHiqaxzQd6qb-KwmYyT82moWx13j at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> I did a diff on them and they are identical.
>
>
> ------------------------------
>
> Message: 6
> Date: Tue, 17 Aug 2010 14:09:58 +1200
> From: Ryan Hellyer <ryan at pixopoint.com>
> Subject: Re: [wp-hackers] TwentyTen Theme issue
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTi=uHjkVMK1en9zVpUQ3mO=+8UiK27vu_YVASs0w at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
>> Yes, yes, lots of people use it that way. Still wrong because CSS
>> takes precedence over those attributes. We should fix WP to do the
>> right thing here, I'd say. Should be simple enough to do, really.
>>
>> -Otto
>
> Thanks Otto.
>
> I should have thought this through more before posting. What you wrote
> was correct, I just misunderstood and hadn't realised the benefits of
> adding height:auto (hat tip to Ian Stewart for pointing me in the
> right direction).
>
> Adding height:auto in the CSS should allow the images to resize
> proportionately when a max-width is used. This breaks when the image
> is a different size to that specified in the HTML unfortunately. So if
> you have a giant over-sized image displayed via Twenty Ten, it will
> resize correctly rather than becoming distorted. The width:auto is a
> hack for IE apparently.
>
> There are disadvantages to this obviously, as it means that the IMG
> tag widths and heights are effectively ignored, however if the admin
> panel was setup to resize the image files rather than just the IMG tag
> widths and heights then the problem would be solved for those who are
> most likely to be confused by the situation and not able to solve it
> themselves (ie: non-coders who aren't editing their own HTML via the
> code editor).
>
> Ian Stewart said he is looking into this and there will be a diff.
> submitted for 3.1 to help alleviate these problems.
>
> cheers,
> Ryan
>
>
> ------------------------------
>
> Message: 7
> Date: Mon, 16 Aug 2010 21:15:45 -0500
> From: Chip Bennett <chip at chipbennett.net>
> Subject: Re: [wp-hackers] Twenty Ten theme issue?
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTinks2L2L8V_rDCKZ9t6-zoQWZVJn2cNUZyC0JqT at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> Well, that's what I always *assumed* that WordPress did (actual resizing) -
> but then this thread made me doubt that assumption.
>
> If actual resized images exist, why on earth would WordPress then be
> performing additional, rendered resizing via IMG attributes? (Perhaps when
> the advanced-option resizing is performed for an inserted image?)
>
> Chip
>
> On Mon, Aug 16, 2010 at 3:02 PM, Nathaniel Taintor <
> goldenapplesdesign at gmail.com> wrote:
>
>> WP does perform actual resizing of images... check your uploads folder, for
>> most images uploaded, there are three or four resized images saved...
>> 'thumbnail', "small", "medium", "large", and "original" by default,
>> although
>> you can add more image sizes through theme or plugin functions.
>>
>> I've often added custom image sizes through my functions.php like this:
>>
>> add_image_size('new-custom-size', 400,9999); // resize to 400px wide, for
>> example...
>>
>> and then specified the size in my style:
>>
>> img.size-new-custom-size { width: 400px; }
>>
>> thinking it would give me slightly quicker page rendering.
>>
>> Are you saying that's not correct? The only issue I can see is if the
>> original uploaded image was smaller than that size, but in that case - from
>> what I understand, the custom size isn't created in the first place and
>> that
>> class won't be used.
>>
>> Best,
>> Than
>>
>>
>> From: Chip Bennett <chip at chipbennett.net>
>> > Subject: Re: [wp-hackers] Twenty Ten theme issue?
>> >
>> > Wouldn't the correct long-term solution be to have WP perform *actual*
>> > resizing of images, such that each image had Original, Thumbnail, Small,
>> > Medium, and Large instances (a la Flickr)?
>> >
>> > Chip
>> >
>> > On Mon, Aug 16, 2010 at 10:23 AM, Otto <otto at ottodestruct.com> wrote:
>> >
>> > > On Mon, Aug 16, 2010 at 5:33 AM, Rich Pedley <elfin at elfden.co.uk>
>> wrote:
>> > > > But there is also a case for the width and height attributes on the
>> img
>> > > > (isn't it still recommended?).
>> > >
>> > > It's recommended to have them in order to give browsers a hint as to
>> > > their size for layout, but it's still wrong to use them for resizing.
>> > >
>> > > Yes, yes, lots of people use it that way. Still wrong because CSS
>> > > takes precedence over those attributes. We should fix WP to do the
>> > > right thing here, I'd say. Should be simple enough to do, really.
>> > >
>> > > -Otto
>> > >
>> >
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
>
>
> ------------------------------
>
> Message: 8
> Date: Mon, 16 Aug 2010 21:49:37 -0500
> From: Otto <otto at ottodestruct.com>
> Subject: Re: [wp-hackers] wp-atom2.php
> To: wp-hackers at lists.automattic.com
> Message-ID:
>        <AANLkTim4y-BAcFpvOSvkiMMqWpFBGGtW-esmWBOtB-bX at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> Maybe you accidentally made a copy once. Happens to me every once in a while.
>
> Just delete it and move on with your life. Beer is nice. Women are better. ;-)
>
> -Otto
>
>
>
> On Mon, Aug 16, 2010 at 7:44 PM, David Morris <dvmorris at gmail.com> wrote:
>> I did a diff on them and they are identical.
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
>
>
> ------------------------------
>
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
>
> End of wp-hackers Digest, Vol 67, Issue 58
> ******************************************
>



-- 
Ryan Hellyer
Email: ryan at pixopoint.com
Website: http://pixopoint.com/
Skype: ryanhellyer
Phone: +64 21 297-2698
Address:
Center for Innovation
87 St David St
Dunedin
New Zealand


More information about the wp-hackers mailing list