From bbd0a220e48c43f026ecb2e394fde6f67413c75f Mon Sep 17 00:00:00 2001 From: FredericoAndrade Date: Fri, 15 Nov 2024 17:55:49 +0200 Subject: [PATCH] spin up fundraising landing page --- .../plugins/wt-gallery/includes/queries.php | 2 +- .../includes/templates/gallery-fellows.php | 33 ++- .../acf-json/group_624f529b40c49.json | 24 +- .../acf-json/group_6735ff7970d17.json | 244 ++++++++++++++++++ .../includes/template-helpers.php | 2 +- .../themes/blankslate-child/stylus/main.css | 163 ++++++++++++ .../themes/blankslate-child/stylus/main.styl | 1 + .../stylus/require/2024-fundraiser.styl | 137 ++++++++++ .../template-giving-campaign-24.php | 86 ++++++ 9 files changed, 677 insertions(+), 15 deletions(-) create mode 100644 wp-content/themes/blankslate-child/acf-json/group_6735ff7970d17.json create mode 100644 wp-content/themes/blankslate-child/stylus/require/2024-fundraiser.styl create mode 100644 wp-content/themes/blankslate-child/template-giving-campaign-24.php diff --git a/wp-content/plugins/wt-gallery/includes/queries.php b/wp-content/plugins/wt-gallery/includes/queries.php index 854214f..55bb43f 100644 --- a/wp-content/plugins/wt-gallery/includes/queries.php +++ b/wp-content/plugins/wt-gallery/includes/queries.php @@ -38,7 +38,7 @@ function get_custom_gallery_query($atts = array()) { } elseif ($atts['meta_key'] === 'nations_of_origin') { $compare_operator = '='; } elseif ($atts['meta_key'] === 'language_iso_codes') { - $compare_operator = '='; + $compare_operator = 'LIKE'; } if (count($val_array) > 1) { diff --git a/wp-content/plugins/wt-gallery/includes/templates/gallery-fellows.php b/wp-content/plugins/wt-gallery/includes/templates/gallery-fellows.php index b913cad..f667843 100644 --- a/wp-content/plugins/wt-gallery/includes/templates/gallery-fellows.php +++ b/wp-content/plugins/wt-gallery/includes/templates/gallery-fellows.php @@ -1,12 +1,12 @@

Thumbnail unavailable

 '; } - -echo ''; +if ($class === "custom fundraiser") { + echo '
  • '; + echo '
    '; + echo '
    '; + echo '

    '.$title.'
    '.$location.'

    '; + echo '

    '.$marketing_text.'

    '; + echo '
    '; + echo '
  • '; +} else { + echo ''; +} diff --git a/wp-content/themes/blankslate-child/acf-json/group_624f529b40c49.json b/wp-content/themes/blankslate-child/acf-json/group_624f529b40c49.json index d9225e4..ca396c7 100644 --- a/wp-content/themes/blankslate-child/acf-json/group_624f529b40c49.json +++ b/wp-content/themes/blankslate-child/acf-json/group_624f529b40c49.json @@ -167,6 +167,7 @@ "max_height": "", "max_size": "", "mime_types": "", + "allow_in_bindings": 1, "preview_size": "medium" }, { @@ -270,6 +271,7 @@ "max_height": "", "max_size": "", "mime_types": "", + "allow_in_bindings": 1, "preview_size": "medium" }, { @@ -555,6 +557,26 @@ "parent_repeater": "field_65026258fda44" } ] + }, + { + "key": "field_673603d7a1bd1", + "label": "Marketing Text", + "name": "marketing_text", + "aria-label": "", + "type": "textarea", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "default_value": "", + "maxlength": "", + "rows": "", + "placeholder": "", + "new_lines": "" } ], "location": [ @@ -575,5 +597,5 @@ "active": true, "description": "", "show_in_rest": 0, - "modified": 1728232228 + "modified": 1731593396 } diff --git a/wp-content/themes/blankslate-child/acf-json/group_6735ff7970d17.json b/wp-content/themes/blankslate-child/acf-json/group_6735ff7970d17.json new file mode 100644 index 0000000..9e24763 --- /dev/null +++ b/wp-content/themes/blankslate-child/acf-json/group_6735ff7970d17.json @@ -0,0 +1,244 @@ +{ + "key": "group_6735ff7970d17", + "title": "Template: 2024 Fundraiser Landing Page", + "fields": [ + { + "key": "field_6735ff7908d64", + "label": "Banner", + "name": "banner", + "aria-label": "", + "type": "group", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "layout": "block", + "sub_fields": [ + { + "key": "field_6735ffa308d65", + "label": "Banner Image", + "name": "banner_image", + "aria-label": "", + "type": "image", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "return_format": "array", + "library": "all", + "min_width": "", + "min_height": "", + "min_size": "", + "max_width": "", + "max_height": "", + "max_size": "", + "mime_types": "", + "preview_size": "medium" + }, + { + "key": "field_6735ffa308d66", + "label": "Banner Header", + "name": "banner_header", + "aria-label": "", + "type": "textarea", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "default_value": "", + "maxlength": "", + "rows": "", + "placeholder": "", + "new_lines": "" + }, + { + "key": "field_6735ffa708d67", + "label": "Banner Copy", + "name": "banner_copy", + "aria-label": "", + "type": "textarea", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "default_value": "", + "maxlength": "", + "rows": "", + "placeholder": "", + "new_lines": "" + } + ] + }, + { + "key": "field_673617392c71c", + "label": "Impact Photo", + "name": "impact_photo", + "aria-label": "", + "type": "image", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "return_format": "array", + "library": "all", + "min_width": "", + "min_height": "", + "min_size": "", + "max_width": "", + "max_height": "", + "max_size": "", + "mime_types": "", + "preview_size": "medium" + }, + { + "key": "field_673602f069b1e", + "label": "Custom Gallery", + "name": "custom_gallery", + "aria-label": "", + "type": "group", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "layout": "block", + "sub_fields": [ + { + "key": "field_6736031369b1f", + "label": "Custom Gallery ID", + "name": "custom_gallery_id", + "aria-label": "", + "type": "text", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "default_value": "", + "maxlength": "", + "placeholder": "", + "prepend": "", + "append": "" + }, + { + "key": "field_6736031e69b20", + "label": "Custom Gallery Title", + "name": "custom_gallery_title", + "aria-label": "", + "type": "text", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "default_value": "", + "maxlength": "", + "placeholder": "", + "prepend": "", + "append": "" + }, + { + "key": "field_6736032769b21", + "label": "Custom Gallery Posts", + "name": "custom_gallery_posts", + "aria-label": "", + "type": "post_object", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "post_type": [ + "fellows" + ], + "post_status": [ + "publish" + ], + "taxonomy": "", + "return_format": "object", + "multiple": 1, + "allow_null": 0, + "bidirectional": 0, + "ui": 1, + "bidirectional_target": [] + } + ] + }, + { + "key": "field_673617502c71d", + "label": "Fundraising Photo", + "name": "fundraising_photo", + "aria-label": "", + "type": "image", + "instructions": "", + "required": 0, + "conditional_logic": 0, + "wrapper": { + "width": "", + "class": "", + "id": "" + }, + "return_format": "array", + "library": "all", + "min_width": "", + "min_height": "", + "min_size": "", + "max_width": "", + "max_height": "", + "max_size": "", + "mime_types": "", + "preview_size": "medium" + } + ], + "location": [ + [ + { + "param": "post_template", + "operator": "==", + "value": "template-giving-campaign-24.php" + } + ] + ], + "menu_order": 0, + "position": "normal", + "style": "default", + "label_placement": "top", + "instruction_placement": "label", + "hide_on_screen": "", + "active": true, + "description": "", + "show_in_rest": 0, + "modified": 1731598192 +} diff --git a/wp-content/themes/blankslate-child/includes/template-helpers.php b/wp-content/themes/blankslate-child/includes/template-helpers.php index f8037e4..de12751 100644 --- a/wp-content/themes/blankslate-child/includes/template-helpers.php +++ b/wp-content/themes/blankslate-child/includes/template-helpers.php @@ -14,7 +14,7 @@ function get_current_datetime() { return date('Y-m-d H:i:s'); } -function log_data($data, $method = 'console') { +function log_data($data, $method = 'console') { // methods: console, dom if ($method === 'console') { echo '