How to Change the CSS Style, Font, Spacing, Alignment and Color of WordPress Image Captions Ako zmeniť štýl CSS, písma, medzery, Zarovnanie a farieb obrazu titulky WordPress
Since WordPress Vzhľadom k tomu, WordPress version 2.6 verzia 2.6 , WordPress has added a built-in shortcode, “Caption”, which will be automatically rendered and translated into standard HTML CSS code to display the caption for the photo or image, which saved via media uploader, beneath it. , WordPress pridala stavaný z-do krátky, "Popis", ktorý bude automaticky vydaný a preložený na štandardný HTML kód CSS pre zobrazenie titulku na fotografiu alebo obrázok, ktorý zachránil cez médiá uploader, pod ním.
However, when WordPress appends the DIV styles to print the caption title under the picture or image, WordPress makes use of default alignment, color, font, spacing, and other styling attributes to display the image captions. Avšak, keď WordPress pripojí DIV štýly pre tlač stránok popisok pod obrázkom alebo obrázok, WordPress používa predvolené zarovnanie, farbu písma, riadkovanie, štýl a ďalšie atribúty pre zobrazenie obrázku titulky.
The default CSS styles for image with the caption may potentially breaks the blog or web page layout, does not validate against W3C xHTML standard, appears too closely with the text with no spacing in the post or page, or does not align as author's wish. Predvolená CSS štýlov pre obraz s titulkom môže potenciálne prestávky blogu alebo webovej stránke rozvrhnutie, neoveruje proti W3C XHTML Standard, zdá príliš úzko spolupracuje s textom bez medzier v úrade alebo stránku, alebo sa nezhoduje ako autor priania.
For blogger who wants to modify the CSS styles of the caption that shows the image captions on screen after parsing the shortcode, add the following CSS code into the active theme's style.css file: Pre blogger, ktorý chce zmeniť CSS štýly titulok, ktorý ukazuje obraz menovkami na obrazovke po analýze krátky, pridajte nasledujúci CSS kód do aktívnej téma je style.css súboru:
/* Captions */
.aligncenter,
div.aligncenter {
display: block;
margin-left: auto;
margin-right: auto;
}
.wp-caption {
border: 1px solid #ddd;
text-align: center;
background-color: #f3f3f3;
padding-top: 4px;
margin: 10px;
-moz-border-radius: 3px;
-khtml-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
}
.wp-caption img {
margin: 0;
padding: 0;
border: 0 none;
}
.wp-caption p.wp-caption-text {
font-size: 11px;
line-height: 17px;
padding: 0 4px 5px;
margin: 0;
}
/* End captions */
Above HTML CSS declaration is taken from WordPress 2.6 default theme. Nad HTML CSS vyhlásenie je prevzatý z WordPress 2.6 default theme. These newly added CSS styles are used to control and assign the appearance of the caption for the image posted on blog. Tieto novo pridané CSS štýly sa používajú na ovládanie a priradiť vzhľad titulok na obrázok zverejnené na blogu. Modify the code above in “style.css” file according to your own preference to have your own design and look. Zmeniť vyššie uvedený kód v "style.css" súbor, podľa vašich vlastných preferencií mať svoj vlastný dizajn a vzhľad.
IMPORTANT : The page is machine translated and provided "as is" without warranty. Upozornenie: stránka je stroje preložené a za predpokladu, "ako je" bez záruky. Machine translation may be difficult to understand. Strojový preklad môže byť ťažké pochopiť. Please refer to Nájdete na original English article originál Anglicky artikl whenever possible. ak je to možné.
Related Articles Súvisiace články
- How to Disable Image and Video Captions Feature and Auto Adding of Shortcode in WordPress 2.6 Až k Oslabit Obraz a Video Hlavička Byť nápadným rysem čoho a Automobil Pridanie Nedostatok do WordPress 2.6
- Caption Disabler WordPress Plugin to Disable and Remove Captions Functionality Titulok Oslabit WordPress Čep až k Oslabit a Chod Hlavička Funkčnosť
- Switch and Change Back to Office 2003 Default Font and Style Set in Office Word 2007 Switch a prepnúť späť do východzieho písma Office 2003 a sadu štýlov v aplikácii Office Word 2007
- Download ING Change Font to Personalize your Windows Mobile Device Stiahnite si ING Zmeniť písmo na Upravte si Windows Mobile zariadenia
- How to Change the Frequency or Interval WordPress Auto Saves An Editing Post or Page Ako meniť frekvenciu alebo Interval WordPress Auto Šetrí Úprava pošty alebo Page
- How to Customize, Modify or Change WordPress Database Connection Error Page Ako prispôsobiť, upraviť alebo zmeniť WordPress Database Connection Error Page
- WordPress 2.6 with Change Revision Tracking Feature Available for Free Download WordPress 2.6 s Zmeniť Revízia funkcie sledovania dispozícii na stiahnutie zadarmo
- Paginating or Split WordPress Post or Page with NextPage in WordPress Not Working Paginating alebo Split WordPress Post alebo stránky s NextPage do WordPress Nie Činnosť
- 3 Column Relaxation WordPress Theme comments-paged.php for Paged-Comments WordPress Plugin 3 Kolóna WordPress Relaxačný Téma komentáre-paged.php pre stránkovaný-Komentáre WordPress Plugin
- AdSense New Ads Style with Horizontal Image and Ad Links AdSense Reklamy New Style s Horizontálny Obraz a reklamné odkazy










































October 27th, 2008 18:05 27.říjen 2008 18:05
Wow, klasse für den CSS-Tipp. Wow, klasse für den CSS-Tipp. Habe den gleiche mal eingebaut und finde die Formatierung einfach klasse. Habe den gleiche mal eingebaut und finde die Formatierung einfach klasse. Sieht optisch sehr ansprechend aus. Optisch sieht aus sehr ansprechend.
Danke und gruss Danke und gruss
September 16th, 2008 01:05 16.září 2008 01:05
Thank you so much for sharing this code! Děkuji moc za zdieľanie tohto kódu! I was going nuts trying to figure out how to fix my captions! Chcel som orechy snaží prísť na to, ako sa z mojej titulky!
July 20th, 2008 10:05 20.července 2008 10:05
For the life of me, I cannot get captions to work. Pre život ma, nemůžu dostat titulky do práce. It looks great in preview, but live, all the code spills out around the photo and there's no caption at all. To vyzerá skvele v náhľadu, ale žiť, celý kód sa vysypal okolo fotografie a neexistuje žiadny popisok vôbec. I added the caption code to my theme's style.css but there was no change. Pridal som titulok kód je moja téma style.css, ale nedošlo k žiadnej zmene. Seems like I'm just one minor step away from making this work. Zdá sa, ako by som bola len jedna menšia odstup od vykonávania tejto práce. If anyone has any ideas, I'd love to hear them. Ak má niekto nejaké nápady, tak by som rada počula. I'll add a caption to my first post to demonstrate. Přidám titulok na môj prvý príspevok na demonštráciu.