Topics – How to geocode an address using the Google Map API

Drupal 8

Modules:

composer require drupal/geofield_map
composer require drupal/geocoder:^3.0@beta
composer require geocoder-php/google-maps-provider
composer require drupal/address

Add a node:

enter the image description here

enter the image description here

enter the image description here

API access denied. Request:
https://maps.googleapis.com/maps/api/geocode/json?address=6303%20Richmond%20Hwy%2CAlexandria%2CVA%2C22306%2CUnited%20States&language=en&region=&key=sfgdgdgd
– Message: This API project is not authorized to use this API.

I spent hours to fix it but I couldn't. When I add a node, the geocode should be automatically converted. But it is not converting. How can i fix it?

Topics – Exception UnknownExtensionException: Module does not exist or is not installed

I get this error on my site

Drupal Core Extension Exception UnknownExtensionException: the module
does not exist or is not installed. in
Drupal Core Extension ExtensionList-> getExtensionInfo () (line 346 of
… core / lib / Drupal / Core / Extension / ExtensionList.php).

This error is occurring on the shared hosting server.

  public function getExtensionInfo($extension_name) {
$all_info = $this->getAllInstalledInfo();
if (isset($all_info($extension_name))) {
  return $all_info($extension_name);
}
throw new UnknownExtensionException("The {$this->type} $extension_name does not exist or is not installed."); // line 346

}

I've been searching online and came across a lot of discussions, but I couldn't fix it. How can I fix the error?

Php: 7.0
Drupal: 8

Topics: How can I call my controller methods from Javascript in Twig?

This is the Twig file –

And Javascript for this is –

function interestedAds()
    {
        document.getElementById('MyInterestedAdsContainer').style.display="block";
        document.getElementById('PersonalDetailsContainer').style.display="none";
        document.getElementById('MyAdsContainer').style.display="none";
    }
    function personalDetails()
    {
        document.getElementById('PersonalDetailsContainer').style.display="block";
        document.getElementById('MyInterestedAdsContainer').style.display="none";
        document.getElementById('MyAdsContainer').style.display="none";
    }
    function myAds()
    {
        document.getElementById('MyAdsContainer').style.display="block";
        document.getElementById('PersonalDetailsContainer').style.display="none";
        document.getElementById('MyInterestedAdsContainer').style.display="none";
    }

I want when I click Interested Ads, I should get data from My Drivers

Here is my controller

class COlxMyAdsController extends COlxDatabaseHandler {

    protected $view;

    public function __construct($container){
        parent::__construct($container);

        $this->view=$container->view;
    }

    public function fetchMyLiveAdIdsByUserId( Request $request, Response $response ) {
        $args=$request->getParams();
        $args=$args('id');
        $liveAdIds = $this->m_objOlxUserDetails->fetchMyLiveAdIdsByUserId($args);
        return $this->view->render($response,'profile.twig',compact('liveAdIds'));
    }

    public function fetchMyDeniedAdIdsByUserId( Request $request, Response $response ) {
        $args=$request->getParams();
        $args=$args('id');
        $deniedAdIds = $this->m_objOlxUserDetails->fetchMyDeniedAdIdsByUserId( $args );

        return $this->view->render($response,'profile.twig',compact('deniedAdIds'));


    }

    public function fetchMyPendingAdIdsByUserId( Request $request, Response $response ) {
        $args=$request->getParams();
        $args=$args('id');
        $pendingAdIds = $this->m_objOlxUserDetails->fetchMyPendingAdIdsByUserId( $args );

        return $this->view->render($response,'profile.twig',compact('pendingAdIds'));

    }

    public function fetchMyInterestedAdIdsByUserId( Request $request, Response $response ) {
        $args=$request->getParams();
        $args=$args('id');
        $interestedAdIds = $this->m_objOlxUserDetails->fetchMyInterestedAdIdsByUserId( $args );

        return $this->view->render($response,'profile.twig',compact('interestedAdIds'));


    }
}

topics: update 7 to 8, how to delete .less / scss files

I am upgrading a website from Drupal 7 to Drupal 8 and suddenly I see all these .less files influencing page style. I found them in the / srss directory of the theme (mytheme / srss / bootstrap /)

When I look at the current Drupal 7 version of the site, the navbar.less and navs.less files are not referenced.

In the Drupal 8 version of the site, I see that navbar.less and navs.less style menu links. Turning off their attributes (browser only), specifically padding and margins, makes things closer to where they're supposed to be.

Deleting or moving the _navbar.less and _navs.less files does nothing. Even after clearing the cache.

How do I remove or neutralize these * .less files from my site?

Thank you.

topics: print a taxonomy term and a D8 url views template

I am totally new to drupal 8. I have used d7 and now I am migrating.

I have set up a view with 4 items.

I've managed to print on a custom views theme

  1. My title
  2. Image url
 {% for row in content('#view').result %}


   {% set image_uri = row._entity.field_image.entity.uri.value %}


   {{ image_uri|image_style('blog_298x200') }}

   {{ content('#view').field('title').value(row) }} 



 {% endfor %}

My template file is called: block – views-block – main-article-block-miniatures-slider.html.twig

I would be very grateful for any advice to get what I need:

  1. The node URL
  2. The taxonomy (field_categorie) and its url
  3. Creation date

I have installed twak twig module to make things easier for me.

Buy Guest Post for the following topics

Health: I will send the title and keywords for all health articles
Movies and series: right here I'd send titles and keywords
WordPress, blogs, tips, tricks, marketing, themes, plugins, etc. they will also provide a list of titles and keywords
Finance: the same here would send titles and keywords

Rules I am looking for expert article writers no less, articles should be researched and written as if you were an expert in the field should have photos

it has to be original

must have at least 1000 words

I need to see real examples of his work before I even talk about his cost.
SEMrush

If interested, reply here or send me a private message.

Topics: Access a template variable page.html.twig in another twig template using a preprocess function

Drupal core version 8.8.3

Using a preprocessor function like below

function subtheme_bs_preprocess_book_tree(&$variables) {
  $variables('page_id') = code here to read the node.nid variable required;
}

I can see the node.nid value I need using the kint function in the page.html.twig file, but I can't understand how to call the variable in my book_tree preprocess function.

I have tried many combinations and I have no idea how to do it.

Image of & # 39; nid & # 39; which I would like to access.

For this current page, it is 115.

The nid node -

What CMS forum allows authors to moderate their own topics?

Hello, I am looking for forum software to install on my website, which could allow any author of a new topic to moderate their topic with the same rights as a regular moderator, mainly by editing other member's responses.

I joined a hundred BBSs (running most of the softwares) and none of them allowed the authors to moderate their own thread. So I assumed it wasn't a built-in feature, possibly because pyramid moderation was the only one known to developers.

If there are too many forum CMS with this feature then I am looking for a very modern one, in the spirit of the Speech but in PHP.
SEMrush

Topics: Setting Views Contextual Filter Settings Dynamically with Twig in Webform

I am trying to embed a view into a web form whose context filter value is set based on a user selection. I have created a node view with a context filter and a web form with a select element and a calculated twig element. In the calculated twig element I have the following code:

{% set gsheatcheck = (data.gs_aut_heat_rejection_rating) %}
{% if gsheatcheck == '1' %}
{{ drupal_view('aps_heat_rejection', 'page_1', 'TSER=1--20') }}
{% elseif gsheatcheck == '2' %}
{{ drupal_view('aps_heat_rejection', 'page_1', 'TSER=21--40') }}
{% endif %}

My problem is if gsheatcheck = 1 the view shows correctly (showing nodes whose TSER value is 1-20), but if gsheatcheck = 2 the view shows nodes whose TSER value is 1-40 (apparently ignoring the two limits of the midrange) .

I thought this could be a caching issue, but turning caching off for the view does not produce a different result.

This is what Devel for Render shows:

concerns:
  '#type': webform_wizard_page
  '#title': Concerns
  gs_aut_heat_rejection_rating:
    '#type': webform_rating
    '#title': 'heat rejection rating'
    '#description': 'Is heat rejection a concern for you?'
    '#default_value': 0
  test_view_1:
    '#type': webform_computed_twig
    '#title': test_view_1
    '#template': |
      {% set gsheatcheck = (data.gs_aut_heat_rejection_rating) %}
      {{ gsheatcheck }}
      {% if gsheatcheck == '1' %}
      {{ drupal_view('aps_heat_rejection', 'page_1', 'TSER=1--20') }}
      {% elseif gsheatcheck == '2' %}
      {{ drupal_view('aps_heat_rejection', 'page_1', 'TSER=21--40') }}
      {% endif %}
    '#ajax': true

For reference, I am using the following versions: Drupal (8.8.4), Webform (8.x-5.9), Twig Tweak (8.x-2.5), and Contextual Range Filter (8.x-1.0-rc1).

I'm probably going for this the wrong way, so any ideas will be greatly appreciated. AUNT

What CMS forum allows authors to moderate their own topics?

Hello, I am looking for a forum software to install on my website, which could allow any author of a new topic to moderate their topic with the same rights as a regular moderator, mainly by editing the responses of other members.