forms – How to create a new parent section on the Configuration page?

When one navigates to Manage » Configuration, the page is divded into sections which (in the “Seven” theme at least) shows up in individual boxes. These sections have headings like “People”, “Content authoring”, “Development”, etc.

I am able to create a settings form and place this inside any of the existing sections on the configuration page by associating it with the parent key in hello_world.links.menu.yml.

Example:

hello_world.greeting_form:
  title: 'Salutation settings'
  description: 'Configure the salutation message.'
  route_name: hello_world.greeting_form
  parent: system.admin_config_development

This places a link to the settings form for the “Hello World” module in the “Development” section.

However, neihter this, nor any other of the pre-existing sections, are suitable for my use case.

I want to create a new section named “Experimental”, place along the others on the “Configuration” page. And make this the parent of my menu link. How do I do that?

Magento2 Ajax change store currency and refresh total on Checkout page while change address

I want to change the current store currency by ajax and refresh the total when changing the address on the checkout page. I have successfully changed store currency by below code:

$this->storeManager->getStore()->setCurrentCurrencyCode($currencyCode);

But problem is that when I am trying to refresh the total then the amount converted as per currency successfully but the currency symbol not changed. Below is the js code of refresh total:

cartCache.set('totals',null);
defaultTotal.estimateTotals(); 

docker – Traefik V2: Got 404 Page Not Found After Implement SSL Wildcard

So, I want to implement the SSL wildcard that I got from DigiCert to my running Traefik container (v2.4.8). Currently, I use Let’s Encrypt as my certificates resolvers, and my dashboard Traefik and Portainer can be accessed on HTTPS.
But after I implement the SSL wildcard, both dashboard Traefik and Portainer can’t be accessed, instead, it shows me “404 page not found” but I can see the cert implemented.
This is my docker-compose.yml file:

version: "3"

services:
  traefik:
    image: traefik:latest
    container_name: traefik
    restart: unless-stopped
    security_opt:
      - no-new-privileges:true
    environment:
      - TZ=Asia/Jakarta
    command:
      - --accesslog.fields.names.StartUTC=drop
      - --providers.docker
      - --providers.file.directory=/traefik-data/tls.yml
      - --providers.file.watch=true
    networks:
      - proxy
    ports:
      - 80:80
      - 443:443
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - ./traefik-data/traefik.yml:/traefik.yml:ro
      - ./traefik-data/acme.json:/acme.json
      - ./traefik-data/configurations:/configurations
      - ./traefik-data/cert:/cert
      - ./traefik-data/tls.yml:/tls.yml:ro
    labels:
      - "traefik.enable=true"
      - "traefik.docker.network=proxy"
      - "traefik.http.routers.traefik-secure.entrypoints=websecure"
      - "traefik.http.routers.traefik-secure.rule=Host(`traefik.mydomain.com)"
      - "traefik.http.routers.traefik-secure.middlewares=user-auth@file"
      #- "traefik.http.routers.traefik-secure.tls=true"
      - "traefik.http.routers.traefik-secure.service=api@internal"

  portainer:
    image: portainer/portainer-ce:latest
    container_name: portainer
    restart: unless-stopped
    security_opt:
      - no-new-privileges:true
    networks:
      - proxy
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - ./portainer-data:/data
    labels:
      - "traefik.enable=true"
      - "traefik.docker.network=proxy"
      - "traefik.http.routers.portainer-secure.entrypoints=websecure"
      - "traefik.http.routers.portainer-secure.rule=Host(`portainer.mydomain.com`)"
      - "traefik.http.routers.portainer-secure.service=portainer"
      #- "traefik.http.routers.traefik-secure.tls=true"
      - "traefik.http.services.portainer.loadbalancer.server.port=9000"

networks:
  proxy:
    external: true

My static configuration (traefik.yml):

api:
  dashboard: true

entryPoints:
  web:
    address: :80
    http:
      redirections:
        entryPoint:
          to: websecure
          scheme: https
          permanent: true

  websecure:
    address: :443
    http:
      middlewares:
        - secureHeaders@file
#      tls:
#        certificates:
#          - certFile: "/cert/bundle.crt"
#            keyFile: "/cert/mydomain.key"
#        certResolver: letsencrypt

providers:
  docker:
    endpoint: "unix:///var/run/docker.sock"
    exposedByDefault: false
  file:
    filename: /configurations/dynamic.yml
    filename: tls.yml

#certificatesResolvers:
#  letsencrypt:
#    acme:
#      email: me@example.com
#      storage: acme.json
#      keyType: EC384
#      httpChallenge:
#        entryPoint: web

My dynamic configuration (tls.yml):

tls:
  certificates:
    - certFile: "/cert/bundle.crt"
      keyFile: "/cert/mydomain.key"
  options:
    default:
      sniStrict: true
  stores:
    default:
      defaultCertificate:
        certFile: "/cert/bundle.crt"
        keyFile: "/cert/mydomain.key"

(dynamic.yml):

http:
  middlewares:
    secureHeaders:
      headers:
        sslRedirect: true
        forceSTSHeader: true
        stsIncludeSubdomains: true
        stsPreload: true
        stsSeconds: 31536000

    user-auth:
      basicAuth:
        users:
          - "admin:$apr1$UdkaACnx$IBAWRG7vIoTbHGRMolFq4q."

tls:
  options:
    default:
      cipherSuites:
        - TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384
        - TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
        - TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
        - TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
        - TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305
        - TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305
      minVersion: VersionTLS12

Or should I put the TLS configuration under provider docker like so as the doc said here:

providers:
  docker:
    tls:
      cert: path/to/foo.cert
      key: path/to/foo.key

Can you tell me what did I do wrong? I appreciate any help!
Thanks!

site collection – How do I acquire a single SharePoint page in PowerQuery?

This page – Site Contents – would be really useful to me:

https://……sharepoint.com/sites/……/……/_layouts/15/viewlsts.aspx?view=14

I want to pull this table into a excel sheet by means of PowerQuery, but when I try “Get Data” from the web address, I’m steered towards using a SharePoint Connector which won’t let me access that page.

How else could I do it?

Buying – bot/macro/Automate/etc upload videos/filehost, to series page | Proxies123.com

I have an series page, I am an uploader, I upload episodes manually, and I know that it could be automated.

Obviously, details are required for you to think about how to automate it, but it is “advanced” because it will require many things (connect with an app that can upload a file to multiple different filehosts, without using a browser/change pages> once all downloads are finished> copy links> and put the links on my page in a specific order/place etc etc

(I can pay ~210 usd or less, it DEPENDS on if the app/script has gui, parameterized to work in any file, etc)

Obviously, details are required for you to think about how to automate it

Customized for my page, although you can also change part of the page to make it work.It puts the embed link in itself, meaning that in some uploads / player as mega I must first put “embed” to the link.

 

seo – How can we troubleshoot why a 404 page doesn’t retain its url rather changes to another 404 page of its own?

I am working on a client website for a technical SEO audit for the first time. They have a 404 page where the URL of the missing page is not retained, instead, it goes to a separate 404 page. For example, let’s say as a user, I need to access https://www.example.com/careers , but this page is not there, so the browser redirects me too https://www.example.com/error/error/notfound?http:www.example.com. This page has all the content that a 404 page has, but the URL changes. Ideally, 404 page should not be there, that I understand, but for audit and temporary fix, shouldn’t the URL have been https://www.example.com/careers and that page should show “page not found” info? How can I check, why this is happening. Also, this page is running on a .NET platform.

8 – Conditional Show/Hide Child Terms on Edit Page

I have a content type with a term reference. The terms have child terms. On the admin editing side, I want to show only top level terms until selected, then show only the child terms for that parent.

This to prevent having a ginormously long field.

Parent 1
  Child 1
  Child 2
Parent 2
  Child 3
  Child 4
Parent 3
...

When a user edits a piece of content, I want to only show the parent terms initially. Then show/hide the child terms when the parent is checked.

Parent 1
Parent 2 (checked)
  Child 3
  Child 4
Parent 3
Parent 4
...

I’ve used conditional fields, state API, and select (other) modules. But this is showing and hiding children on the same field. So it’s a bit different.

Anyone have any advice for this scenario?

google docs – How to retrieve data from a googlesheet and display in a WordPress page?


Your privacy


By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our Cookie Policy.




magento2 – Magento 2: How to filter section show when page load?

I have set one grid in frontend using Uicomponent. I want to filter section expand when page load, after customer filter any value that it will close.
I try using below code.

$(document).ajaxComplete(function(){ 
trigger code for expand
});

but its every time expand.

How to create the page in WordPress plugin development. Clicking on button then a new page is created and also the URL created, so how to create that?

Can any tell me how to create that as I know how to register_post_type.
register_post_type( $post_type(‘post_type’),
array(
‘labels’ => array(
‘name’ => $post_type(‘name’),
‘singular_name’ => $post_type(‘singular_name’),
‘menu_name’ => $post_type(‘menu_name’),
‘name_admin_bar’ => $post_type(‘name_admin_bar’),
‘archives’ => $post_type(‘archives’),
‘attributes’ => $post_type(‘attributes’),
‘parent_item_colon’ => $post_type(‘parent_item_colon’),
‘all_items’ => $post_type(‘all_items’),
‘add_new_item’ => $post_type(‘add_new_item’),
‘add_new’ => $post_type(‘add_new’),
‘new_item’ => $post_type(‘new_item’),
‘edit_item’ => $post_type(‘edit_item’),
‘update_item’ => $post_type(‘update_item’),
‘view_item’ => $post_type(‘view_item’),
‘view_items’ => $post_type(‘view_items’),
‘search_items’ => $post_type(‘search_items’),
‘not_found’ => $post_type(‘not_found’),
‘not_found_in_trash’ => $post_type(‘not_found_in_trash’),
‘featured_image’ => $post_type(‘featured_image’),
‘set_featured_image’ => $post_type(‘set_featured_image’),
‘remove_featured_image’ => $post_type(‘remove_featured_image’),
‘use_featured_image’ => $post_type(‘use_featured_image’),
‘insert_into_item’ => $post_type(‘insert_into_item’),
‘uploaded_to_this_item’ => $post_type(‘uploaded_to_this_item’),
‘items_list’ => $post_type(‘items_list’),
‘items_list_navigation’ => $post_type(‘items_list_navigation’),
‘filter_items_list’ => $post_type(‘filter_items_list’)
)