Template talk:Main Page Quote of the day

From Wikiquote
Latest comment: 11 years ago by Ningauble in topic Centering
Jump to navigation Jump to search

Centering[edit]

The code currently used here is no longer displaying the QOTD in properly centered fashion. I have noticed this for the last two days now, but an admin will need to make any necessary revisions. ~ Kalki·· 13:44, 19 September 2012 (UTC)Reply

Sample 1[edit]

Quote of the day
 
As we are convinced that the real attainment of liberty, of justice, and of peace in the world will be impossible so long as the immense majority of the populations are dispossessed of property, deprived of education and condemned to political and social nonbeing and a de facto if not a de jure slavery, through their state of misery as well as their need to labor without rest or leisure, in producing all the wealth in which the world is glorying today, and receiving in return but a small portion hardly sufficient for their daily bread;
As we are convinced that for all these populations, hitherto so terribly maltreated through the centuries, the question of bread is the question of intellectual emancipation, of liberty, and of humanity;
As we are convinced that liberty without socialism is privilege, injustice; and that socialism without liberty is slavery and brutality;
Now therefore, the League highly proclaims the need for a radical social and economic reform, whose aim shall be the deliverance of the people's labor from the yoke of capital and property, upon a foundation of the strictest justice — not juridical, not theological, not metaphysical, but simply human justice, of positive science and the most absolute liberty.
~ Mikhail Bakunin ~
 
There is a page for each month where previous "Quotes of the Day" for each date are listed, and where registered users can make suggestions or rank suggestions for upcoming dates. The Quotes of the Year page and other archives contain more extensive listings of quotes that have already been used. See also the QOTD by month and email options.

I am not seeing the problem. Heading, quote, and author all appear centered as usual. Is there a specific code tweak that works better for you? ~ Ningauble (talk) 18:52, 19 September 2012 (UTC)Reply
I do see the problem when I look at the Main Page - although I have no idea how to fix it. :-) ~ UDScott (talk) 20:06, 19 September 2012 (UTC)Reply
I'm seeing the same problem; what are everyone's browsers? (Safari 6/Mac 10.8) I took a look at the code and couldn't immediately find where the problem was. Odd. EVula // talk // // 20:10, 19 September 2012 (UTC)Reply
I am using Firefox on a PC. ~ UDScott (talk) 20:12, 19 September 2012 (UTC)Reply
I have a theory about what is happening. The MediaWiki programmers have been experimenting with upgrading from HTML 4.01 to HTML 5. The Align and Valign attributes of the <td> element were supported but deprecated in HTML 4.01, and may not be supported any more. (I am using IE7 which tends to center table cell contents even without the attribute, by default – which has always been wrong.) Therefore, I tried moving the Center attribute from the <td> element to a <div>. Does the following "Sample 2" look any better in your browsers? ~ Ningauble (talk) 21:30, 19 September 2012 (UTC)Reply
I think you're on to something, as I just noticed that {{quotation limit}} was no longer centering (as the template's author, I know for a fact that I wouldn't have had it left-aligned). Sure enough, the centering code was for the table itself; deleting that didn't make a difference, and adding a bit of CSS to achieve the centering [if an element has a defined width, you can just set the left and right margins to auto] got it to work again. EVula // talk // // 22:59, 19 September 2012 (UTC)Reply
Independently of Ningauble's edits, I added a bit of code to {{Quote of the day}} to force the width; I noticed that long quotes worked just fine, but the shorter quotes didn't. That seems to have done the trick. (though I think Ningauble's would have as well) EVula // talk // // 22:50, 19 September 2012 (UTC)Reply
Works for me. ~ Ningauble (talk) 15:19, 20 September 2012 (UTC)Reply

Sample 2[edit]

Quote of the day
 
As we are convinced that the real attainment of liberty, of justice, and of peace in the world will be impossible so long as the immense majority of the populations are dispossessed of property, deprived of education and condemned to political and social nonbeing and a de facto if not a de jure slavery, through their state of misery as well as their need to labor without rest or leisure, in producing all the wealth in which the world is glorying today, and receiving in return but a small portion hardly sufficient for their daily bread;
As we are convinced that for all these populations, hitherto so terribly maltreated through the centuries, the question of bread is the question of intellectual emancipation, of liberty, and of humanity;
As we are convinced that liberty without socialism is privilege, injustice; and that socialism without liberty is slavery and brutality;
Now therefore, the League highly proclaims the need for a radical social and economic reform, whose aim shall be the deliverance of the people's labor from the yoke of capital and property, upon a foundation of the strictest justice — not juridical, not theological, not metaphysical, but simply human justice, of positive science and the most absolute liberty.
~ Mikhail Bakunin ~
 
There is a page for each month where previous "Quotes of the Day" for each date are listed, and where registered users can make suggestions or rank suggestions for upcoming dates. The Quotes of the Year page and other archives contain more extensive listings of quotes that have already been used. See also the QOTD by month and email options.