## 8 – Page title and body field of specific page

I have a page–front.html.twig file. I can’t figure out how to show a specific node title and body summary on the frontpage with only using twig. I know I can create a view of something like that and show it with: `{{ drupal_view('viewmachinename', 'blockname') }}`, but in my opinion it’s a little bit overkill for just showing the title and body of specific node.

Normally I show the current node title and body summary with `{{ node.label }}` and `{{node.body.summary}}`, but I don’t know how to show the page title and body summary with an other nid.

I try to show the page title and body summary with `nid 2` on the frontpage.

## AppleScript: How to add text in a text file at a specific location

I want to add some tags in text files save as with .xml extension. The input.txt is like this:

Purolator Edmonton

607431612227

And the output.xml should be like this:

``````<tags>
<tag1>Purolator Edmonton</tag1>
<tag2>607431612227</tag2>
</tags>
``````

## How to show the author box of a specific role in WordPress?

i wanna show the authorbox of "subscriber" (mean specific role user) in single.php
if subscriber make any post than only show the authorbox after the post.not for "author" "editor" or "admin"

## nodes – Clip sites to a specific content type

I’m searching for a possibility to clip websites to Drupal much like the Clipper Chrome extension for Notion or Evernote.

In Notion, it lets me add Youtube videos to any database, takes the page title, the platform icon, the thumbnail, the URL and embeds the video to a new entry in my database. I would like to do the same with Drupal and expend on the data which is clipped like getting the channel and create a relation from one content type to another.

## entities – Clip (web)sites to a specific content type in drupal

i’m searching for a possibility to clip websites to drupal much like the “Clipper” chrome extensions for notion or evernote? (https://chrome.google.com/webstore/detail/save-to-notion/ldmmifpegigmeammaeckplhnjbbpccmm?hl=de)

In notion it lets me add youtube videos to any database, takes the page title, the platform icon, the thumnail, the url and embeds the video to a new entry in my database. I would like to do the same with drupal and expend on the data which is clipped like getting the channel and create a relation from one content type to another.

## API Security(APIs to be exposed to a specific client)

We have microservice-based architecture.
Currently, we have APIs which we have exposed over the internet for all users.

Now we want to provide APIs to a specific client and only this specific client should be able to access this API.

What security practices we should follow? I mean what is the best way to secure such APIs. Provide a token to client and hard check for API with token on each request oy anything else?

## php – Redirect logged on user to a specific page based on wp user role, page id

I am trying to redirect users(subscribers) to a particular page based on the following conditions
`1. (subscriber) user is logged on 2. specific page id is matched 3. wp user role = subscriber` which is the default role set when a user is registered on the platform

The Challenge i am having is conditions 1 and 2 works but not 3.

Here is my code:

``````function add_login_check()
{
if ( is_user_logged_in() && is_page(1865)) {
wp_redirect('http://destredirectedpage.php');
exit;
}
}
add_action('wp', 'add_login_check');
``````

Interesting enough when i tested the above code using administrator role it works as expected but with subscriber role i get redirected automatically to the subscriber profile page upon logon.

## differential equations – How to add a velocity boundary condition with specific time period

I have a wave equation for displacement and velocity, I want to add this boundary condition $$v(x=0,t>0)=1$$
My mathematica code is

``````sol = NDSolve({1/1000 D(u(x, t), {t, 2}) == D(u(x, t), {x, 2}),
D(u(x, t), t) == v(x, t), u(x, 0) == 0, v(x, 0) == 0,
v(0, t > 0) == 1, v(L, t) == 0}, {u(x, t), v(x, t)}, {x, 0, L}, {t,
0, 1})
``````

L is a constant.

## 8 – How can I limit an entity reference selection to a specific field value on the reference

I have a content type `Research` which has a an entity reference type of `People`.

The problem is that I don’t want to show ALL people but only people which have a certain value under their field named `type`.
I was trying to find it here:

Anyone an idea how to only show a content-type for a certain field value of that content type

## How to make Irssi automatically send a message to a username on connecting to a specific server?

I want Irssi to automatically message NickServ with the message "CONFIRM <PASSWORD HERE>" whenever I connect to irc.rizon.net, and I want it to get the password from a gpg-encrypted file. How could I accomplish this?