Custom fields and post types


book custom fields

[et_pb_section fb_built=”1″ _builder_version=”4.21.0″ _module_preset=”default” background_color=”#edf8ff” background_enable_image=”off” background_size=”initial” background_position=”top_right” background_horizontal_offset=”20%” background_vertical_offset=”11%” height=”520px” bottom_divider_style=”wave” bottom_divider_color=”#FFFFFF” bottom_divider_height=”106px” bottom_divider_flip=”horizontal” background_last_edited=”on|phone” background_enable_image_tablet=”off” background_enable_image_phone=”off” global_colors_info=”{}”][et_pb_row column_structure=”3_5,2_5″ module_class=”custom-row-width-981″ _builder_version=”4.21.0″ _module_preset=”default” max_width=”1320px” custom_padding=”||15px||false|false” global_colors_info=”{}”][et_pb_column type=”3_5″ _builder_version=”4.18.0″ _module_preset=”default” z_index=”9999999999″ overflow-x=”hidden” overflow-y=”hidden” custom_padding=”||25px|25px|false|false” global_colors_info=”{}”][et_pb_text module_class=”line-before-sub-text” _builder_version=”4.21.0″ _module_preset=”default” text_font=”|700|||||||” text_text_color=”#e09900″ text_font_size=”27px” header_text_color=”#f38704″ header_font_size=”27px” header_2_text_color=”gcid-c206024e-1a97-4ece-ab59-f1d0395e0dc2″ header_2_font_size=”27px” custom_margin=”||10px||false|false” custom_padding=”|||65px|false|false” text_font_size_tablet=”20px” text_font_size_phone=”16px” text_font_size_last_edited=”on|phone” header_2_font_size_tablet=”30px” header_2_font_size_phone=”21px” global_colors_info=”{%22gcid-c206024e-1a97-4ece-ab59-f1d0395e0dc2%22:%91%22header_text_color%22,%22header_2_text_color%22%93}”]

Alles over je website

[/et_pb_text][et_pb_text _builder_version=”4.21.0″ _module_preset=”default” custom_margin=”|||20px|false|false” header_font_size_tablet=”39px” header_font_size_phone=”18px” global_colors_info=”{}”]

Custom fields and post types

[/et_pb_text][et_pb_text _builder_version=”4.21.0″ _module_preset=”default” text_font=”|300|||||||” text_text_color=”#a0a0a0″ text_font_size=”22px” text_line_height=”1.6em” custom_margin=”-20px|120px||20px|false|false” animation_delay=”300ms” text_font_size_tablet=”22px” text_font_size_phone=”16px” text_font_size_last_edited=”on|phone” global_colors_info=”{}”]

dynamische WordPress-website met Advanced Custom Fields (ACF)

[/et_pb_text][/et_pb_column][et_pb_column type=”2_5″ _builder_version=”4.21.0″ _module_preset=”default” global_colors_info=”{}”][/et_pb_column][/et_pb_row][et_pb_row _builder_version=”4.21.0″ _module_preset=”default” background_color=”#F38704″ positioning=”absolute” position_origin_a=”center_right” vertical_offset=”126px” horizontal_offset=”85px” z_index=”1″ width=”50px” height=”50px” background_last_edited=”on|phone” global_colors_info=”{}”][et_pb_column type=”4_4″ _builder_version=”4.18.0″ _module_preset=”default” global_colors_info=”{}”][/et_pb_column][/et_pb_row][et_pb_row module_class=”custom-row-width-981″ _builder_version=”4.18.0″ _module_preset=”default” module_alignment=”center” global_colors_info=”{}”][et_pb_column type=”4_4″ _builder_version=”4.18.0″ _module_preset=”default” custom_padding=”0px||0px||true|false” global_colors_info=”{}”][et_pb_image src=”https://staging.aiautomatiseringexpert.be/wp-content/uploads/2023/05/arrow.png” title_text=”arrow” disabled_on=”on|off|off” _builder_version=”4.18.0″ _module_preset=”default” positioning=”absolute” position_origin_a=”bottom_left” vertical_offset=”220px” horizontal_offset=”-128px” width=”75px” animation_style=”fade” animation_delay=”600ms” global_colors_info=”{}”][/et_pb_image][/et_pb_column][/et_pb_row][et_pb_row disabled_on=”on|on|off” _builder_version=”4.21.0″ _module_preset=”default” background_color=”gcid-8ebf9a87-ba2c-4ac0-af4c-d0ba45b603d5″ positioning=”absolute” vertical_offset=”35px” horizontal_offset=”35px” z_index=”1″ width=”50px” height=”50px” animation_style=”bounce” animation_delay=”500ms” background_last_edited=”on|phone” border_radii=”on|50%|50%|50%|50%” global_colors_info=”{%22gcid-51025655-7a8e-4033-a8c9-e112e3d25996%22:%91%22background_color%22,%22background_color%22%93,%22gcid-8ebf9a87-ba2c-4ac0-af4c-d0ba45b603d5%22:%91%22background_color%22,%22background_color%22%93,%22gcid-f3904967-1215-4d02-b82a-f880239cf7db%22:%91%22background_color%22%93}”][et_pb_column type=”4_4″ _builder_version=”4.18.0″ _module_preset=”default” global_colors_info=”{}”][/et_pb_column][/et_pb_row][et_pb_row _builder_version=”4.21.0″ _module_preset=”default” background_color=”#005480″ positioning=”absolute” position_origin_a=”bottom_left” vertical_offset=”55px” vertical_offset_tablet=”123px” vertical_offset_phone=”40px” vertical_offset_last_edited=”on|phone” width=”50px” height=”50px” custom_margin=”|||50px|false|false” animation_style=”bounce” animation_delay=”500ms” global_colors_info=”{}”][et_pb_column type=”4_4″ _builder_version=”4.18.0″ _module_preset=”default” global_colors_info=”{}”][/et_pb_column][/et_pb_row][/et_pb_section][et_pb_section fb_built=”1″ _builder_version=”4.16″ custom_padding=”2px||9px|||” global_colors_info=”{}”][et_pb_row admin_label=”Ga Ga Content – Freddie – Row” _builder_version=”4.16″ width=”90%” max_width=”1170px” custom_padding=”3px||0px||false|false” global_colors_info=”{}”][et_pb_column type=”4_4″ _builder_version=”4.16″ custom_padding=”4px||||false|false” global_colors_info=”{}”][et_pb_cta title=”Wat zijn custom fields?” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.21.0″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||113px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2201%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

Wanneer je een blog bericht of een pagina aanmaakt voegt u in de eerste instantie inhoud toe.  Daarnaast wordt ook de bijkomende informatie zoals titel, auteur, datum, tijd en meer bewaard.  Deze bijkomende informatie van de post of pagina wordt ook wel metadata genoemd.

Met “Custom fields” of “aangepaste velden” in WordPress kun je zelf extra informatie toevoegen met betrekking tot de post, pagina of elk type inhoud. Deze meta-informatie kan worden weergegeven in uw thema. Om dat te doen moet u echter uw WordPress thema-bestanden bewerken.

Om technisch een beetje uit te wijden wordt de PostMeta informatie opgeslagen in een nieuwe tabel, $wpdb->postmeta. Deze tabel heeft vier velden:

  • meta_id: Een uniqe ID for elke entry
  • post_id: De ID van een post voor de metadata
  • meta_key: De naam van de ‘Key’
  • meta_value: De value geassocieërd met de ‘Key’

Deze info in een thema toe te voegen is niet echt eenvoudig.  Gelukkig bestaan er plugins die je thema-bestanden voor jou aanpassen en zo de aangepaste velden te implementeren. Een van de bekendste plugin is de Advanced Custom Fields WordPress plugin.

Custom fields of aangepaste velden zijn overal aanwezig in je WordPress website. De meeste plugins maken immers gebruik van custom fields.  Denk maar aan de volgende toepassingen :

Wooommerce, de meest populaire manier om een eCommerce winkel te bouwen in WordPress maakt ook gebruik van aangepaste velden om extra informatie gestructureerd over een product op te slaan zoals:

  • Prijs
  • Gewicht
  • Kleur
  • Aantal
  • Stockvoorraad
  • BTW voet

Of als je recepten plugin hebt, zal deze gebruikmaken van bijkomende velden om extra informatie op te slaan over een menu zoals:

  • Bereidingstijd
  • Caloriën
  • Moeilijkheidsgraad
  • Prijs
  • Aantal personen
  • Waardering

Of een evenementen plugin waar meestal de volgende extra velden aanwezig zijn:

  • Datum en tijd
  • Plaats
  • Soort event
  • Registratietermijn
  • Aantal personen
  • Toegangsprijs

[/et_pb_cta][et_pb_cta title=”Wat zijn Custom Post Types ” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.19.0″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||113px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2202%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

Post types zijn manieren in WordPress om verschillende soorten content te categoriseren en te bewaren. De 2 bekendste en meest voorkomende post types: berichten (posts) en pagina’s (pages). Daarnaast heeft WordPress 5 mindere bekende post types. Je kan ook zelf een Post Type aanmaken.Het antwoord is: elke keer wanneer je content toevoegt aan je website die niet in één van de standaard post types past.

Enkele veelvoorkomende voorbeelden van custom post types zijn:
Projects (standaard aanwezig in WordPress)
Producten van een webshop -> Woocommerce.
Kaarten voor een kaartenwebsite -> Google maps.
Evenementen voor een boekingswebsite -> Events calendar.
Recepten
Video’s of podcasts
Trainingen
Immobiliën
Reizen
Getuigenissen
Ledendatabase
…

[/et_pb_cta][et_pb_cta title=”Hoe Custom Post Types tonen ?” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.19.0″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||116px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2203%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

Inhoud van Custom Post Types dienen anders weergeven te worden dan berichten of pagina’s.  Hiervoor moet er een ‘loop’ gemaakt worden welke in een template is verwerkt.  En dit is niet eenvoudig …

Gelukkig bestaan er tools of plug-ins voor.

[/et_pb_cta][et_pb_cta title=”DIVI machine plugin” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.27.4″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||116px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2204%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

De Divi Machine Plugin is een externe plugin die uitgebreide functionaliteit toevoegt voor custom post types binnen Divi, inclusief dynamische veldweergave en zoekmogelijkheden, recent bijgewerkt om beter samen te werken met de nieuwste Divi-versies. Deze pluin maakt gebruik van Advanced Custom Fields en voegt veel modules in de DIVI builder toe welke je toelaat om de data van iedere custom post te tonen waar en hoe je het graag wilt hebben.

Voor het gebruik van Divi Machine is het verplicht dat de Advanced Custom Fields (ACF) plugin geïnstalleerd en actief is, wat essentieel blijft in de nieuwste versies om aangepaste velden correct te beheren.

Wil je complexe Divi websites bouwen met dynamische velden en waar eveneens filtering en zoekfunctie vereist is twijfel niet langer en neem een kijkje op hun website diviengine.com

[/et_pb_cta][et_pb_image src=”https://staging.aiautomatiseringexpert.be/wp-content/uploads/2023/11/divi-machine-dynamic-content-1_320.jpg” alt=”divi-machine-dynamic-content-1_320″ title_text=”divi-machine-dynamic-content-1_320″ align=”center” _builder_version=”4.22.2″ _module_preset=”default” max_width=”43%” global_colors_info=”{}”][/et_pb_image][et_pb_cta title=”ACF toepassing : Woocommerce ” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.21.0″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||116px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2205%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

WooCommerce is de populairste e-commerce plugin voor WordPress, die uitgebreide gebruikmaakt van custom fields voor productinformatie zoals prijs, voorraad en BTW-tarieven, zoals ook bevestigd door recente WordPress marktanalyses.

[/et_pb_cta][et_pb_cta title=”Conclusie” button_text=”Click Here” admin_label=”Schoolin Content – Tina – Call To Action” _builder_version=”4.21.0″ header_font=”Vidaloka||||||||” header_text_color=”#1e1e26″ header_font_size=”30px” header_line_height=”114%” body_font=”Roboto||||||||” body_text_color=”#9b9b9b” body_line_height=”163%” use_background_color=”off” text_orientation=”left” custom_padding=”|||116px|false|false” custom_padding_tablet=”|||60px|false|false” custom_padding_phone=”” custom_padding_last_edited=”on|tablet” header_font_size_tablet=”30px” header_font_size_phone=”24px” header_font_size_last_edited=”on|phone” custom_css_before=” content: %2205%22;|| font-family: ‘Roboto’,Helvetica,Arial,Lucida,sans-serif!important;|| font-size: 16px!important;|| color: #1e1e26!important;|| line-height: 120%!important;|| font-weight: 400;|| margin-bottom: 0!important;|| display: block;|| position: absolute;|| left: 0;|| top: 7px;” custom_css_main_element=”position: relative;” custom_css_after=” background: #1e1e26;|| content: ”;|| position: absolute;|| height: 1px;|| display: inline-block;|| top: 15px;|| left: 23px;|| width: 30px;|| visibility: visible;” custom_css_promo_description=”font-weight: 400 !important;” custom_css_promo_title=”font-weight: 400 !important;|| padding-bottom: 23px;” global_colors_info=”{}”]

Divi machine in combinatie met ACF is de tool dat elke web designer nodig heeft om met de DIVI builder complexe posts / pagina’s te maken.

[/et_pb_cta][/et_pb_column][/et_pb_row][et_pb_row _builder_version=”4.18.0″ _module_preset=”default” custom_padding=”4px||6px|||” global_colors_info=”{}”][et_pb_column type=”4_4″ _builder_version=”4.18.0″ _module_preset=”default” global_colors_info=”{}”][et_pb_code _builder_version=”4.22.2″ _module_preset=”default” global_colors_info=”{}”]



[/et_pb_code][/et_pb_column][/et_pb_row][/et_pb_section]

×