From 0088d16e2ac5c7c4e24bf6f9b601c848888e3541 Mon Sep 17 00:00:00 2001 From: Kevin Koech Date: Fri, 13 Oct 2023 14:52:25 +0300 Subject: [PATCH 01/14] Set up themes --- .gitignore | 1 + Dockerfile | 2 ++ docker-compose.yml | 18 ++++++++++++++++++ 3 files changed, 21 insertions(+) create mode 100644 Dockerfile create mode 100644 docker-compose.yml diff --git a/.gitignore b/.gitignore index 2bcb9608..db4cb549 100644 --- a/.gitignore +++ b/.gitignore @@ -84,6 +84,7 @@ apple-touch-icon.png favicon.ico wpe-deploy-status-academyafrica robots.txt +wordpress # large/disallowed file types # a CDN should be used for these diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..4c8fadd2 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,2 @@ +FROM wordpress:6.3-php8.1-fpm-alpine +# COPY ./wp-content /var/www/html/wp-content/ \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 00000000..e55263d9 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,18 @@ +version: '3.1' + +services: + + wordpress: + image: wordpress:latest + restart: always + ports: + - 8080:80 + environment: + WORDPRESS_DB_HOST: host.docker.internal:3306 + WORDPRESS_DB_USER: academyafrica + WORDPRESS_DB_PASSWORD: academyafrica + WORDPRESS_DB_NAME: academyafrica + WORDPRESS_TABLE_PREFIX: wp_ + volumes: + - ./wordpress:/var/www/html + - ./wp-content/themes:/var/www/html/wp-content/themes \ No newline at end of file From 0fc6e1d5562adf12fbb8463229b357cc8fac6e77 Mon Sep 17 00:00:00 2001 From: Kevin Koech Date: Fri, 13 Oct 2023 16:14:25 +0300 Subject: [PATCH 02/14] - Set up development environment with docker - Add .env files --- .env.example | 5 +++ .gitignore | 21 ++++------- contrib/docker-compose/nginx/nginx.conf | 48 +++++++++++++++++++++++++ docker-compose.yml | 25 +++++++------ 4 files changed, 74 insertions(+), 25 deletions(-) create mode 100644 .env.example create mode 100644 contrib/docker-compose/nginx/nginx.conf diff --git a/.env.example b/.env.example new file mode 100644 index 00000000..4202bc92 --- /dev/null +++ b/.env.example @@ -0,0 +1,5 @@ + WORDPRESS_DB_HOST=host.docker.internal:3307 + WORDPRESS_DB_USER=dbuser + WORDPRESS_DB_PASSWORD=dbpassword + WORDPRESS_DB_NAME=dbname + WORDPRESS_TABLE_PREFIX=wp_ \ No newline at end of file diff --git a/.gitignore b/.gitignore index db4cb549..6d66be90 100644 --- a/.gitignore +++ b/.gitignore @@ -61,20 +61,9 @@ wp-content/mu-plugins/wpe-wp-sign-on-plugin* /xmlrpc.php /wp-admin /wp-includes -/wp-content/themes/twentyten -/wp-content/themes/boss -/wp-content/themes/boss-child -/wp-content/themes/twentyeleven -/wp-content/themes/twentytwelve -/wp-content/themes/twentythirteen -/wp-content/themes/twentyfourteen -/wp-content/themes/twentyfifteen -/wp-content/themes/twentysixteen -/wp-content/themes/twentyseventeen -/wp-content/themes/twentyeighteen -/wp-content/themes/twentynineteen -/wp-content/themes/twentytwenty -/wp-content/plugins/akismet* +/wp-content/themes/* +!/wp-content/themes/academyAfrica +!/wp-content/themes/hello-elementor /wp-content/plugins/* !/wp-content/plugins/index.php /wp-content/mu-plugins @@ -119,4 +108,6 @@ wordpress *.asx *.asf *.wmv -*.avi \ No newline at end of file +*.avi + +.env \ No newline at end of file diff --git a/contrib/docker-compose/nginx/nginx.conf b/contrib/docker-compose/nginx/nginx.conf new file mode 100644 index 00000000..32f1993f --- /dev/null +++ b/contrib/docker-compose/nginx/nginx.conf @@ -0,0 +1,48 @@ +server { + listen 80; + listen [::]:80; + + server_name localhost; + ## Your only path reference. + root /var/www/html; + + index index.php; + + location = /favicon.ico { + log_not_found off; + access_log off; + } + + location = /robots.txt { + allow all; + log_not_found off; + access_log off; + } + + location / { + # include the "?$args" part so non-default permalinks doesn't break when using query string + try_files $uri $uri/ /index.php?$args; + } + + location ~ \.php$ { + #NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini\ + try_files $uri =404; + fastcgi_split_path_info ^(.+\.php)(/.+)$; + fastcgi_pass wordpress:9000; + fastcgi_index index.php; + include fastcgi_params; + fastcgi_intercept_errors on; + fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; + fastcgi_param PATH_INFO $fastcgi_path_info; + } + client_max_body_size 100M; + + location ~ /\.ht { + deny all; + } + + location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { + expires max; + log_not_found off; + } +} \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index e55263d9..2f407338 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,16 +3,21 @@ version: '3.1' services: wordpress: - image: wordpress:latest - restart: always + image: wordpress:php7.4-fpm + restart: unless-stopped + env_file: .env + volumes: + - ./wordpress:/var/www/html + - ./wp-content/themes:/var/www/html/wp-content/themes + - ./wp-content/plugins:/var/www/html/wp-content/plugins + + nginx: + depends_on: + - wordpress + image: nginx:1.19 + restart: unless-stopped ports: - 8080:80 - environment: - WORDPRESS_DB_HOST: host.docker.internal:3306 - WORDPRESS_DB_USER: academyafrica - WORDPRESS_DB_PASSWORD: academyafrica - WORDPRESS_DB_NAME: academyafrica - WORDPRESS_TABLE_PREFIX: wp_ volumes: - - ./wordpress:/var/www/html - - ./wp-content/themes:/var/www/html/wp-content/themes \ No newline at end of file + - ./contrib/docker-compose/nginx/nginx.conf:/etc/nginx/conf.d/default.conf + - ./wordpress:/var/www/html \ No newline at end of file From afd370e36c58f709af02c93458e2b1897e9f5e05 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 16:25:41 +0300 Subject: [PATCH 03/14] Format .env example file --- .env.example | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.env.example b/.env.example index 4202bc92..c9d35d2f 100644 --- a/.env.example +++ b/.env.example @@ -1,5 +1,5 @@ - WORDPRESS_DB_HOST=host.docker.internal:3307 - WORDPRESS_DB_USER=dbuser - WORDPRESS_DB_PASSWORD=dbpassword - WORDPRESS_DB_NAME=dbname - WORDPRESS_TABLE_PREFIX=wp_ \ No newline at end of file +WORDPRESS_DB_HOST=host.docker.internal:3307 +WORDPRESS_DB_USER=dbuser +WORDPRESS_DB_PASSWORD=dbpassword +WORDPRESS_DB_NAME=dbname +WORDPRESS_TABLE_PREFIX=wp_ \ No newline at end of file From 9ac851d67c73bd33926b236618a3f09db9c9cad7 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 16:41:57 +0300 Subject: [PATCH 04/14] Add php uploads.ini file --- contrib/docker-compose/php/uploads.ini | 3 +++ docker-compose.yml | 1 + 2 files changed, 4 insertions(+) create mode 100644 contrib/docker-compose/php/uploads.ini diff --git a/contrib/docker-compose/php/uploads.ini b/contrib/docker-compose/php/uploads.ini new file mode 100644 index 00000000..6689ed03 --- /dev/null +++ b/contrib/docker-compose/php/uploads.ini @@ -0,0 +1,3 @@ +upload_max_filesize = 128M +post_max_size = 128M +max_execution_time = 60 diff --git a/docker-compose.yml b/docker-compose.yml index 2f407338..6c6b38f7 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,6 +10,7 @@ services: - ./wordpress:/var/www/html - ./wp-content/themes:/var/www/html/wp-content/themes - ./wp-content/plugins:/var/www/html/wp-content/plugins + - ./contrib/docker-compose/php/uploads.ini:/usr/local/etc/php/conf.d/uploads.ini nginx: depends_on: From afe0305479b19784c38f34cf3d985f9aecb0403e Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 16:58:21 +0300 Subject: [PATCH 05/14] Add basic readme --- .gitignore | 22 +++++++--------------- README.md | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+), 15 deletions(-) create mode 100644 README.md diff --git a/.gitignore b/.gitignore index 2bcb9608..6d66be90 100644 --- a/.gitignore +++ b/.gitignore @@ -61,20 +61,9 @@ wp-content/mu-plugins/wpe-wp-sign-on-plugin* /xmlrpc.php /wp-admin /wp-includes -/wp-content/themes/twentyten -/wp-content/themes/boss -/wp-content/themes/boss-child -/wp-content/themes/twentyeleven -/wp-content/themes/twentytwelve -/wp-content/themes/twentythirteen -/wp-content/themes/twentyfourteen -/wp-content/themes/twentyfifteen -/wp-content/themes/twentysixteen -/wp-content/themes/twentyseventeen -/wp-content/themes/twentyeighteen -/wp-content/themes/twentynineteen -/wp-content/themes/twentytwenty -/wp-content/plugins/akismet* +/wp-content/themes/* +!/wp-content/themes/academyAfrica +!/wp-content/themes/hello-elementor /wp-content/plugins/* !/wp-content/plugins/index.php /wp-content/mu-plugins @@ -84,6 +73,7 @@ apple-touch-icon.png favicon.ico wpe-deploy-status-academyafrica robots.txt +wordpress # large/disallowed file types # a CDN should be used for these @@ -118,4 +108,6 @@ robots.txt *.asx *.asf *.wmv -*.avi \ No newline at end of file +*.avi + +.env \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 00000000..d70e9186 --- /dev/null +++ b/README.md @@ -0,0 +1,43 @@ +### Repository Setup Guide + +1. **Add SSH Key to WP Engine** + + To get started, add your SSH key to WP Engine. For more information, refer to the [WP Engine SSH Gateway Documentation](https://wpengine.com/support/ssh-gateway/). + +2. **Create a Working Directory and Clone the Repository** + + Create a working directory and clone this repository into it. + +3. **Download and Restore Backups from WP Engine** + + Download and restore the latest backups from WP Engine using the instructions provided in the [WP Engine Restore Documentation](https://wpengine.com/support/restore/). Unzip the backups into your working directory. + +4. **Access the Remote Database Using SSH** + + Use SSH and local port forwarding to access the remote database. Here's an example command: + + ```bash + ssh -L 3307:127.0.0.1:3306 -i ~/.ssh/wpengine_ed25519 -o IdentitiesOnly=yes sacademyafrica@sacademyafrica.ssh.wpengine.net + ``` + + For more details, refer to the [WP Engine Remote Database Access Guide](https://wpengine.com/support/setting-remote-database-access/). + +5. **Update Environment Variables** + + Update the environment variables in the `.env` file using the database credentials from WP Engine. You can find the credentials with the following command once you have SSH access to the remote database: + + ```bash + grep WPENGINE_SESSION_DB_PASSWORD ./sites/environmentname/_wpeprivate/config.json + ``` + +6. **Start Containers** + + Run the following command to start the containers using Docker Compose: + + ```bash + docker-compose up -d + ``` + +7. **Access the Site** + + You can now access the site at [http://localhost:8080](http://localhost:8080). From 72d9dbd6f94c88b971a157dde2693a3396b90dfe Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 17:24:52 +0300 Subject: [PATCH 06/14] Update readme with admin access doc --- README.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d70e9186..d2d8bceb 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,14 @@ grep WPENGINE_SESSION_DB_PASSWORD ./sites/environmentname/_wpeprivate/config.json ``` + To access the admin dashboard from localhost, add the following to `wp-config.php` in the `wordpress` directory after the `WP_DEBUG` line: + + ```php + define( 'WP_SITEURL', 'http://localhost:8080' ); + define( 'WP_HOME', 'http://localhost:8080' ); + define( 'DOMAIN_CURRENT_SITE', 'http://localhost:8080' ); + ``` + 6. **Start Containers** Run the following command to start the containers using Docker Compose: @@ -40,4 +48,4 @@ 7. **Access the Site** - You can now access the site at [http://localhost:8080](http://localhost:8080). + You can now access the site at [http://localhost:8080](http://localhost:8080). \ No newline at end of file From 205b96249ed6f3957cf48af0383e8fdad111b74d Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 17:36:32 +0300 Subject: [PATCH 07/14] Reviewed changes --- .gitignore | 2 +- Dockerfile | 2 +- contrib/docker-compose/nginx/nginx.conf | 2 +- docker-compose.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 6d66be90..3f9c8036 100644 --- a/.gitignore +++ b/.gitignore @@ -110,4 +110,4 @@ wordpress *.wmv *.avi -.env \ No newline at end of file +.env diff --git a/Dockerfile b/Dockerfile index 4c8fadd2..9c7eb660 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,2 +1,2 @@ FROM wordpress:6.3-php8.1-fpm-alpine -# COPY ./wp-content /var/www/html/wp-content/ \ No newline at end of file +# COPY ./wp-content /var/www/html/wp-content/ diff --git a/contrib/docker-compose/nginx/nginx.conf b/contrib/docker-compose/nginx/nginx.conf index 32f1993f..ac69efab 100644 --- a/contrib/docker-compose/nginx/nginx.conf +++ b/contrib/docker-compose/nginx/nginx.conf @@ -45,4 +45,4 @@ server { expires max; log_not_found off; } -} \ No newline at end of file +} diff --git a/docker-compose.yml b/docker-compose.yml index 6c6b38f7..76a026c5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -21,4 +21,4 @@ services: - 8080:80 volumes: - ./contrib/docker-compose/nginx/nginx.conf:/etc/nginx/conf.d/default.conf - - ./wordpress:/var/www/html \ No newline at end of file + - ./wordpress:/var/www/html From cd2128fcfed8d1ce6a27e031934fb7fb830cc4c0 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Fri, 13 Oct 2023 17:48:52 +0300 Subject: [PATCH 08/14] Fix admin styles not working --- docker-compose.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docker-compose.yml b/docker-compose.yml index 76a026c5..d20da504 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -22,3 +22,5 @@ services: volumes: - ./contrib/docker-compose/nginx/nginx.conf:/etc/nginx/conf.d/default.conf - ./wordpress:/var/www/html + - ./wp-content/themes:/var/www/html/wp-content/themes + - ./wp-content/plugins:/var/www/html/wp-content/plugins From 001152d4d9bebb2d131358cf238c5df10a9793ee Mon Sep 17 00:00:00 2001 From: Kevin Koech Date: Mon, 16 Oct 2023 10:03:13 +0300 Subject: [PATCH 09/14] Add new line --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index c9d35d2f..4ca4732d 100644 --- a/.env.example +++ b/.env.example @@ -2,4 +2,4 @@ WORDPRESS_DB_HOST=host.docker.internal:3307 WORDPRESS_DB_USER=dbuser WORDPRESS_DB_PASSWORD=dbpassword WORDPRESS_DB_NAME=dbname -WORDPRESS_TABLE_PREFIX=wp_ \ No newline at end of file +WORDPRESS_TABLE_PREFIX=wp_ From 127db9e385cce7874c6b2adf9a5f29ffb88267a3 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Mon, 16 Oct 2023 11:46:55 +0300 Subject: [PATCH 10/14] Update environment variables --- .env.example | 3 +++ README.md | 1 - contrib/docker-compose/nginx/nginx.conf | 5 +++++ docker-compose.yml | 7 ++++++- 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 4ca4732d..9bf6fac5 100644 --- a/.env.example +++ b/.env.example @@ -3,3 +3,6 @@ WORDPRESS_DB_USER=dbuser WORDPRESS_DB_PASSWORD=dbpassword WORDPRESS_DB_NAME=dbname WORDPRESS_TABLE_PREFIX=wp_ +WP_DEBUG=true +SITE_URL=http://localhost:8080 + diff --git a/README.md b/README.md index d2d8bceb..5b2188a8 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,6 @@ ```php define( 'WP_SITEURL', 'http://localhost:8080' ); define( 'WP_HOME', 'http://localhost:8080' ); - define( 'DOMAIN_CURRENT_SITE', 'http://localhost:8080' ); ``` 6. **Start Containers** diff --git a/contrib/docker-compose/nginx/nginx.conf b/contrib/docker-compose/nginx/nginx.conf index ac69efab..3c1d0efa 100644 --- a/contrib/docker-compose/nginx/nginx.conf +++ b/contrib/docker-compose/nginx/nginx.conf @@ -45,4 +45,9 @@ server { expires max; log_not_found off; } + + proxy_connect_timeout 600; + proxy_send_timeout 600; + proxy_read_timeout 600; + send_timeout 600; } diff --git a/docker-compose.yml b/docker-compose.yml index d20da504..f32cb075 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,6 +6,11 @@ services: image: wordpress:php7.4-fpm restart: unless-stopped env_file: .env + environment: + WORDPRESS_CONFIG_EXTRA: | + define( 'WP_SITEURL', '${SITE_URL}' ); + define( 'WP_HOME', '${SITE_URL}' ); + define( 'WP_DEBUG', ${WP_DEBUG} ); volumes: - ./wordpress:/var/www/html - ./wp-content/themes:/var/www/html/wp-content/themes @@ -15,7 +20,7 @@ services: nginx: depends_on: - wordpress - image: nginx:1.19 + image: nginx:latest restart: unless-stopped ports: - 8080:80 From 1ea4c46b0e29b3b3835439d191fbc19ef46da484 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Mon, 16 Oct 2023 12:47:11 +0300 Subject: [PATCH 11/14] Fix nginx timeouts --- contrib/docker-compose/nginx/nginx.conf | 6 +----- contrib/docker-compose/php/uploads.ini | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/contrib/docker-compose/nginx/nginx.conf b/contrib/docker-compose/nginx/nginx.conf index 3c1d0efa..55b5be5e 100644 --- a/contrib/docker-compose/nginx/nginx.conf +++ b/contrib/docker-compose/nginx/nginx.conf @@ -34,6 +34,7 @@ server { fastcgi_intercept_errors on; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; + fastcgi_read_timeout 600; } client_max_body_size 100M; @@ -45,9 +46,4 @@ server { expires max; log_not_found off; } - - proxy_connect_timeout 600; - proxy_send_timeout 600; - proxy_read_timeout 600; - send_timeout 600; } diff --git a/contrib/docker-compose/php/uploads.ini b/contrib/docker-compose/php/uploads.ini index 6689ed03..1169da3d 100644 --- a/contrib/docker-compose/php/uploads.ini +++ b/contrib/docker-compose/php/uploads.ini @@ -1,3 +1,3 @@ upload_max_filesize = 128M post_max_size = 128M -max_execution_time = 60 +max_execution_time = 600 From 3b852d8a7829117b5069f9dde31e7ad71a14debb Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Mon, 16 Oct 2023 13:18:52 +0300 Subject: [PATCH 12/14] Update wordpress version --- docker-compose.yml | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index f32cb075..d5d6b1e5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,11 +1,12 @@ -version: '3.1' +version: '3.9' services: - wordpress: - image: wordpress:php7.4-fpm + image: wordpress:6.3.2 restart: unless-stopped env_file: .env + ports: + - 8080:80 environment: WORDPRESS_CONFIG_EXTRA: | define( 'WP_SITEURL', '${SITE_URL}' ); @@ -17,15 +18,3 @@ services: - ./wp-content/plugins:/var/www/html/wp-content/plugins - ./contrib/docker-compose/php/uploads.ini:/usr/local/etc/php/conf.d/uploads.ini - nginx: - depends_on: - - wordpress - image: nginx:latest - restart: unless-stopped - ports: - - 8080:80 - volumes: - - ./contrib/docker-compose/nginx/nginx.conf:/etc/nginx/conf.d/default.conf - - ./wordpress:/var/www/html - - ./wp-content/themes:/var/www/html/wp-content/themes - - ./wp-content/plugins:/var/www/html/wp-content/plugins From a5776b74427dbcb7e0868a806f9d363231ad47d9 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Mon, 16 Oct 2023 14:12:08 +0300 Subject: [PATCH 13/14] Remove dockerfile --- Dockerfile | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 9c7eb660..00000000 --- a/Dockerfile +++ /dev/null @@ -1,2 +0,0 @@ -FROM wordpress:6.3-php8.1-fpm-alpine -# COPY ./wp-content /var/www/html/wp-content/ From 7e3f148613ad12724af1e5c969e6a1ffecdd9ffd Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Thu, 19 Oct 2023 18:10:17 +0300 Subject: [PATCH 14/14] Header Nav Signed-off-by: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> --- wp-content/themes/academyAfrica/templates/navigation-header.json | 1 + 1 file changed, 1 insertion(+) create mode 100644 wp-content/themes/academyAfrica/templates/navigation-header.json diff --git a/wp-content/themes/academyAfrica/templates/navigation-header.json b/wp-content/themes/academyAfrica/templates/navigation-header.json new file mode 100644 index 00000000..5a33baea --- /dev/null +++ b/wp-content/themes/academyAfrica/templates/navigation-header.json @@ -0,0 +1 @@ +{"content":[{"id":"3a592e3f","settings":{"flex_direction":"row","flex_gap":{"unit":"px","size":0,"column":"0","row":"0"},"background_background":"classic","__globals__":{"background_color":"globals\/colors?id=ba19cf4"},"content_width":"full","min_height":{"unit":"px","size":92,"sizes":[]},"flex_justify_content":"center","flex_align_items":"center","flex_wrap":"nowrap","padding":{"unit":"px","top":"0","right":"60","bottom":"0","left":"60","isLinked":false},"width_tablet_extra":{"unit":"%","size":"","sizes":[]},"width_tablet":{"unit":"%","size":"","sizes":[]},"width_mobile":{"unit":"%","size":"","sizes":[]},"padding_mobile":{"unit":"px","top":"0","right":"024","bottom":"0","left":"24","isLinked":false}},"elements":[{"id":"6725b161","settings":{"flex_direction":"row","content_width":"full","width":{"unit":"%","size":20},"flex_justify_content":"center","flex_align_items":"center","_flex_size":"none","_element_width":"initial","width_tablet_extra":{"unit":"%","size":80,"sizes":[]},"width_tablet":{"unit":"%","size":"","sizes":[]},"width_mobile":{"unit":"%","size":80,"sizes":[]}},"elements":[{"id":"14e6a510","settings":{"__dynamic__":{"image":"[elementor-tag id=\"\" name=\"site-logo\" settings=\"%7B%7D\"]"},"image_size":"custom","image_custom_dimension":{"width":"35","height":"35"}},"elements":[],"isInner":false,"widgetType":"theme-site-logo","elType":"widget"},{"id":"6c89f1a","settings":{"__dynamic__":{"title":"[elementor-tag id=\"\" name=\"site-title\" settings=\"%7B%22before%22%3A%22%22%2C%22after%22%3A%22%22%2C%22fallback%22%3A%22%22%7D\"]","link":"[elementor-tag id=\"\" name=\"site-url\" settings=\"%7B%7D\"]"},"title":"Add Your Heading Text Here","title_color":"#FFFFFF","typography_typography":"custom","typography_font_family":"Open Sans","typography_font_size":{"unit":"px","size":18,"sizes":[]},"typography_font_weight":"600","typography_font_style":"normal","typography_line_height":{"unit":"px","size":28,"sizes":[]},"typography_font_size_mobile":{"unit":"px","size":13.5,"sizes":[]},"typography_line_height_mobile":{"unit":"px","size":"","sizes":[]}},"elements":[],"isInner":false,"widgetType":"theme-site-title","elType":"widget"}],"isInner":true,"elType":"container"},{"id":"60c04b3b","settings":{"flex_direction":"row","content_width":"full","width":{"unit":"%","size":25},"flex_justify_content":"flex-end","flex_align_items":"center","_flex_size":"grow","width_tablet_extra":{"unit":"%","size":10,"sizes":[]},"width_tablet":{"unit":"%","size":"","sizes":[]},"width_mobile":{"unit":"%","size":10,"sizes":[]},"flex_justify_content_widescreen":"flex-end","_flex_align_self_widescreen":"center","_flex_align_self_mobile":"center","_flex_size_widescreen":"grow"},"elements":[{"id":"71f2bcaf","settings":{"selected_icon":{"value":"fas fa-search","library":"fa-solid"},"primary_color":"#FFFFFF","hover_primary_color":"#FFFFFF","size":{"unit":"px","size":24,"sizes":[]},"_flex_align_self":"center","_flex_order":"end","hide_widescreen":"hidden-widescreen","hide_desktop":"hidden-desktop","hide_laptop":"hidden-laptop","align_mobile":"center","_flex_align_self_widescreen":"flex-end","_flex_align_self_mobile":"flex-end"},"elements":[],"isInner":false,"widgetType":"icon","elType":"widget"},{"id":"7f9c050a","settings":{"placeholder":"Search Courses","button_text":"Search","size":{"unit":"px","size":40,"sizes":[]},"input_typography_typography":"custom","input_typography_font_family":"Open Sans","input_typography_font_size":{"unit":"px","size":14,"sizes":[]},"input_typography_font_weight":"400","input_typography_text_transform":"none","input_typography_font_style":"italic","input_typography_line_height":{"unit":"px","size":18,"sizes":[]},"icon_size":{"unit":"px","size":16,"sizes":[]},"_flex_size":"grow","__globals__":{"button_text_color":"globals\/colors?id=ba19cf4","button_background_color":"globals\/colors?id=fc1e4c6","input_text_color":"globals\/colors?id=bc80d88"},"border_radius":{"unit":"px","size":0,"sizes":[]},"hide_tablet_extra":"hidden-tablet_extra","hide_tablet":"hidden-tablet","hide_mobile":"hidden-mobile"},"elements":[],"isInner":false,"widgetType":"search-form","elType":"widget"}],"isInner":true,"elType":"container"},{"id":"168a8fd","settings":{"flex_direction":"row","content_width":"full","width":{"unit":"%","size":55},"flex_justify_content":"space-between","flex_align_items":"center","_flex_size":"grow","_element_width":"initial","_flex_order_tablet_extra":"start","width_tablet_extra":{"unit":"%","size":10,"sizes":[]},"width_tablet":{"unit":"%","size":"","sizes":[]},"width_mobile":{"unit":"%","size":10,"sizes":[]}},"elements":[{"id":"10dc7bab","settings":{"menu":"navigation","align_items":"right","pointer":"none","submenu_icon":{"value":"fas fa-angle-down","library":"fa-solid"},"menu_typography_typography":"custom","menu_typography_font_family":"Open Sans","menu_typography_font_size":{"unit":"px","size":18,"sizes":[]},"menu_typography_font_weight":"600","menu_typography_line_height":{"unit":"px","size":21.6,"sizes":[]},"__globals__":{"color_menu_item":"globals\/colors?id=5b9c1e6","toggle_background_color":"globals\/colors?id=ba19cf4","background_color_dropdown_item":"","color_dropdown_item_hover":"globals\/colors?id=ba19cf4","background_color_dropdown_item_hover":"globals\/colors?id=aa6a735","color_dropdown_item":"globals\/colors?id=ba19cf4","dropdown_divider_color":"globals\/colors?id=ba19cf4","dropdown_border_color":"globals\/colors?id=ba19cf4","toggle_background_color_hover":"globals\/colors?id=ba19cf4","background_color_dropdown_item_active":"globals\/colors?id=aa6a735","color_dropdown_item_active":"globals\/colors?id=ba19cf4"},"full_width":"stretch","_flex_size":"grow","toggle_align":"left","dropdown":"tablet_extra","color_menu_item":"#F7F9FD","dropdown_typography_typography":"custom","dropdown_typography_font_family":"Open Sans","dropdown_typography_font_size_tablet_extra":{"unit":"px","size":16,"sizes":[]},"dropdown_typography_font_weight":"400","dropdown_typography_text_transform":"uppercase","dropdown_typography_font_style":"normal","dropdown_typography_letter_spacing_tablet_extra":{"unit":"px","size":1.6,"sizes":[]},"dropdown_border_border":"solid","padding_horizontal_dropdown_item_tablet_extra":{"unit":"px","size":20,"sizes":[]},"padding_vertical_dropdown_item_tablet_extra":{"unit":"px","size":20,"sizes":[]},"dropdown_divider_border":"solid","dropdown_divider_width":{"unit":"px","size":1,"sizes":[]},"dropdown_top_distance_tablet_extra":{"unit":"px","size":28,"sizes":[]},"toggle_color":"#FFFFFF","toggle_size_tablet_extra":{"unit":"px","size":24,"sizes":[]},"color_dropdown_item_hover":"#0C1A81","dropdown_typography_font_size":{"unit":"px","size":13,"sizes":[]},"dropdown_border_width":{"unit":"px","top":"1","right":"1","bottom":"1","left":"1","isLinked":true},"toggle_background_color":"#0C1A81","custom_css":"nav ul.elementor-nav-menu li.sign-in.menu-item {\n background-color: #fff;\n}\n\nnav ul.elementor-nav-menu li.sign-in.menu-item a.elementor-item.elementor-item-anchor {\n color: #0C1A81;\n font-family: Open Sans;\n font-size: 16px;\n font-style: normal;\n font-weight: 800;\n line-height: 19px;\n letter-spacing: 1.6px;\n text-transform: uppercase;\n}\n\n\nnav ul.elementor-nav-menu li.language-link.menu-item a i {\n font-size:24px !important;\n}\n\nnav ul.elementor-nav-menu li.user-profile.menu-item a i {\n font-size:24px !important;\n}\n\n@media all and (max-width: 1152px) {\n nav ul.elementor-nav-menu {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 100%;\n }\n\n nav ul.elementor-nav-menu li.sign-in.menu-item {\n order: -1;\n background-color: #EFF0FD;\n }\n\n nav ul.elementor-nav-menu li.user-profile.menu-item {\n order: -1;\n }\n\n nav ul.elementor-nav-menu li.sign-in.menu-item a.elementor-item.elementor-item-anchor {\n color: #0C1A81;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu {\n background-color: #fff;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item {\n display: flex;\n align-items: center;\n align-self: stretch;\n background: #0C1A81;\n box-shadow: 0px 1px 0px 0px #E2E8F0;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item:not(:last-child) {\n border-bottom: 1.5px solid #fff;\n }\n\n nav.elementor-nav-menu--dropdown ul.elementor-nav-menu li.menu-item a.elementor-item {\n color: #fff;\n font-family: Open Sans;\n font-size: 16px;\n font-style: normal;\n font-weight: 800;\n line-height: 19px;\n letter-spacing: 1.6px;\n text-transform: uppercase;\n width: 100%;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children {\n display: flex;\n flex-direction: column;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children a {\n display: flex;\n justify-content: space-between;\n align-items: center;\n width: 100%;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children a.highlighted {\n background-color: #0C1A81;\n color: #fff;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children ul {\n width: 100% !important;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children ul li {\n background-color: #fff;\n }\n\n nav.elementor-nav-menu--dropdown.elementor-nav-menu__container ul.elementor-nav-menu li.menu-item.menu-item-has-children ul li:not(:last-child) {\n border-bottom: 2px solid #0C1A81;\n }\n}","toggle_color_hover":"#FFFFFF","color_dropdown_item":"#0C1A81","dropdown_border_color":"#0C1A81","dropdown_divider_color":"#0C1A81","toggle_background_color_hover":"#0C1A81","background_color_dropdown_item":"#FFFFFF","menu_id":12859},"elements":[],"isInner":false,"widgetType":"nav-menu","elType":"widget"}],"isInner":true,"elType":"container"}],"isInner":false,"elType":"container"}],"page_settings":[],"version":"0.4","title":"Top Header","type":"header"} \ No newline at end of file