Hazie WordPress Jetpack Shortcode Obosara

wordpress jetpack

Mgbe WordPress wepụtara Jetpack ngwa mgbakwunye, ha mepere nkezi WordPress nwụnye ruo ụfọdụ nnukwu atụmatụ ha gụnyere na ngwọta ha kwadoro. Ozugbo ị gbanyere ngwa mgbakwunye, ị gbanyere ụda atụmatụ, gụnyere shortcodes. Na ndabara, WordPress anaghị ekwe ka onye edemede gị gbakwunye agbakwunye mgbasa ozi n'ime ọdịnaya nke post ma ọ bụ ibe. Nke a bụ atụmatụ nchekwa ma belata iwepụ ohere nke ịmebi saịtị gị.

Agbanyeghị, iji koodu mkpirisi, onye ọrụ gị nwere ike itinye mgbasa ozi dị mfe. Dịka ọmụmaatụ, iji tinye vidiyo Youtube, ọ dịghị mkpa ka ịgbakwunye ederede embed - ị tinye URL ahụ na vidiyo na vidiyo na nchịkọta ederede. Mwekota nke mkpirisi na-achọpụta ụzọ ma dochie URL ahụ na koodu vidiyo dị adị. Enweghị nsogbu, enweghị nsogbu!

Ewezuga otu. Iji shortcodes, obosara nke gị agbakwunyere media dị defaults. Ya mere Youtube nwere ike ịgbasa karịa obosara nke ọdịnaya gị ma wụfee n'akụkụ gị - ma ọ bụ Slideshare nwere ike were ọkara ohere ọ nwere ike iwe. Ejiri m awa ole na ole gwụsịrị ike iji chọpụta otu esi ede ụfọdụ nzacha ka ndabere nke ụzọ ụzọ ọ bụla. Enyochare m ọtụtụ plugins iji hụ ma ọ dị nke dị ugbu a.

Mgbe ahụ achọtara m… obere mgbanwe na-enwu gbaa na WordPress gbakwunyere na API ha. Ntọala ebe ị nwere ike ndabere obosara nke ọdịnaya na ibe gị na posts:

ma ọ bụrụ na (! amalite ($ content_width)) $ content_width = 600;

Ozugbo m debere obosara a na faịlụ function.php nke isiokwu m, a gbanwere usoro mgbasa ozi mkpirisi niile. Ọ bụ ezie na enwere m obi ụtọ na ọ bụ naanị akara nke koodu, enwere m nnukwu nsogbu na ọ were ogologo oge ịchọta nke a. Ọbụna ihe na-adọrọ mmasị bụ enweghị nhazi dị na ya Jetpack. Shortcodes, dịka ọmụmaatụ, enweghị ike nkwarụ - ọ na-arụ ọrụ ma ọ bụrụhaala na enyere ihe mgbakwunye aka.

Ọ ga-abụrịrị ihe na-egbukepụ egbukepụ, dịka ọmụmaatụ, ịgbakwunye ihe kachasị obosara na ịdị elu ntọala ozugbo na Jetpack Ntọala shortcode. WordPress bụ ihe dị egwu dị egwu, mana mgbe ụfọdụ ịchọta ihe ngwọta nwere ike ịbụ ntakịrị iwe.

Kedu ihe ị chere?

Ebe a na-eji Akismet iji belata spam. Mụta otu esi etinye usoro data gị.