A hyperlink or link is a reference to data that the reader can directly follow, or that is followed automatically.

learn more… | top users | synonyms

1
vote
2answers
24 views

Views: add (link to file field) to image field

In D7, I have an event content type containing an image field ("Featured image") and a file field ("Document"). I have a view of events containing documents, and would like to wrap a link around the ...
0
votes
0answers
10 views

Force all URLs to be absolute

I have installed the following modules: Pathologic Advanced Aggregation I implemented hook_link_alter() where I set $variables['options']['absolute'] = TRUE;. This helped with fixing: All ...
0
votes
0answers
11 views

Alter path of sub menu item when the user is on edit page

I want to alter the path of a sub-menu item which is been created from the core menu module from UI only. I wanted to change its path based on the url I tried implementing ...
0
votes
0answers
6 views

custom link and field update

I'm wondering if and how it can be done. I'm having a dashboard built. Basically, a quicktab using views. In one of these views, there are "custom fields" where I show icons. Some are basic edit link ...
1
vote
1answer
35 views

How to alter language item link html in Drupal 8

I am looking to modify the default output of Drupal 8 of links in a certain situation, the language switcher. Ideally I want to be able to do that in a twig template and not have to produce a massive ...
1
vote
1answer
82 views
+50

How to get the valid URL of a Link field from within a Twig template?

I have a Link field named field_my_link (machine name). Within a Twig template I can get the link's URL value with this: {{ node.field_my_link.uri }} If inside the Link's URL there is an external ...
3
votes
1answer
52 views

Customize the HTML of a link field from a custom theme

I've a Link field named field_home_link, attached to a Content Type named Home, and I'm trying to customize how it is rendered as HTML from inside a custom theme. Instead of the default generated ...
1
vote
0answers
28 views

How to create private links to unmanaged files ?

I have created my own module with custom block to display private downloads to authenticated users. The downloads files are provided by 3rd-party system and stored in private folder of Drupal ...
0
votes
1answer
24 views

Base URL for all external links

I have site that has multiple external links. I need a way to edit them all at once. For example: I have a site www.example.com that has multiple external links like SOME-IP/getaccess, ...
0
votes
0answers
10 views

How can I parse an URL from the Link module?

I am developing a website, my website, powering Drupal 7 and I know that the Link module already has something like displaying a link from http://website.com/some-article-here to website.com but I ...
0
votes
0answers
28 views

Drupal 8 register link?

I have a clean Drupal 8 install with bootstrap theme. I just want to add a simple link to the registration form in the user account menu and to it only be visible if you are not logged in. The login ...
0
votes
3answers
23 views

Turn text or link field in image

Users can enter links in separate fields that lead to their facebook, youtube pages. On output i would like to use images for those fields instead of showing ugly links. Is there a module to ...
1
vote
1answer
65 views

How do I create menu links programmatically?

I need to add some links to existing menu (or to new) programmatically in Drupal 8.
0
votes
0answers
27 views

Add target attribute to link in Drupal 8 [duplicate]

How to add attributes to links in Drupal 8, or maybe there are a better way to create link? $link = Link::fromTextAndUrl( t('Link text'), Url::fromUri('http://google.com', array()) ); ...
1
vote
1answer
35 views

Custom Drupal breadcrumbs - how to disable the last item

I have a D8 custom module providing its own breadcrumbs. The breadcrumbs are shown perfectly, but the current page (last item) is shown as a link. I want to change Change this but as I see it, the ...
0
votes
0answers
27 views

Why are Anchor links not being rendered?

I made a Link Field, set its URL to "#contact" and its text to "Comece o seu Projeto!". On the node page, it gets rendered as <div class="field field--name-field-chamada-para-acao field--type-link ...
0
votes
2answers
24 views

7 - “/es” showing up twice in URLs

I have a bilingual website using locale. I have a content type that has the "link" field. I have an Image Slider created with Views with the link as one of the fields. The url in the link field is ...
0
votes
0answers
13 views

why do links under the home menu point not work like ssub links from other pages?

I have a superfish drop down menu on my page and it works fine so far until I added links under the Home tab, the links don't seem to be propagated to the other pages. I have cleared my caches and I ...
0
votes
1answer
17 views

How to edit comment reply link for specific content type in Drupal 7

Is there a way I can programmatically edit comment reply links for a specific content type in Drupal 7? So I need to check for the content type before changing the links: <?php if ($node->type ...
0
votes
0answers
23 views

link to a faq item and expand it

Is there a specific way to link to an anchor on a FAQ item? I have tried just using the anchor tag #myitem and calling /faq#myitem takes me to the page but does not expand the item requested. I have ...
0
votes
1answer
20 views

How to link price to the product display?

I have a page of product teaser links (image, title, price) and I was able to successfully link all except the price to the content with the module Linked Field. The price field acts differently. The ...
0
votes
1answer
39 views

How to extend link field type in D8?

It's good to see the Link field type in D8. It takes a URL and (optionally) link text. I'm adding a multiple links field to a content type and would like users to be able to provide some styling ...
0
votes
0answers
14 views

Add content are not correctly re-parented

I decided to change Add content node/add/% from Navigation menu to Management menu. My prob is : Add a Content type Go to Add content and my new Add content's child link doesn't appear. It ...
0
votes
1answer
41 views

How to put links in a menu programmatically?

I'm using Drupal 7, and modules such as Service links and Flag. I would like to put the links proposed by these modules (share or flag) in a menu (main menu or other). Anybody know the way to ...
1
vote
1answer
32 views

How to select by default nodes of a content type in admin/content through a link?

I'd like to make a link to admin/content/, but when the page was displayed I'd like to have it filtered by a certain content type. The link can be like this admin/content/house so when I click it, ...
1
vote
2answers
72 views

Can we add the ?destination query parameter to a link from yml configuration?

When creating a link from yaml ie: mymodule.links.action.yml my_module.my_entity.add: route_name: node.add title: 'Add My Entity' route_parameters: node_type: 'my_entity' appears_on: ...
0
votes
1answer
52 views

How do I upload a PDF for users to download?

I am very new to Drupal. I simply want to provide a link in an article for users to download a pdf document. How do I upload the document on the admin side and then link to it in an article?
0
votes
1answer
88 views

Print node URL in a custom block template

I have a custom block that loads multiple nodes from the database and passes it to the twig template. Inside the template I loop the list printing some node details, but I need to create a link on the ...
1
vote
1answer
17 views

How to link to dblog filtered by type

In my custom D7 module, I'd like to link to admin/reports/dblog/, however, I'd like to have it filtered by a certain type so when you navigate to that link, the type is already filtered for you. Is ...
1
vote
1answer
13 views

Changing drupal project folder breaks links

I have a drupal project working in the server home directory. I want to move this from the server home directory to a subdirectory to make way for other drupal projects. I move the whole drupal ...
0
votes
0answers
47 views

Add element to the “Add new comment” link

I'm using a Bootstrap theme and would like to add a glyphicon to the "Add new comment" link so that it comes out something like this: <a href="..."><span class="glyphicon ...
1
vote
2answers
130 views

Edit “Read more” and “Add new comment” links in teaser in Drupal 8

I'd like to add a couple classes to the "Read more" and "Add new comment" links in my article teasers in Drupal 8. I'd do this in Drupal 7 by doing something like this in my theme file: function ...
1
vote
0answers
19 views

Additional parameters in check_plain()

I created link field in cck and add the URl like with apostrophe (https://www.sample.com/test's_data/test.pdf). But the View output displayed as ...
3
votes
2answers
284 views

How to set target=“_blank” for links in CKEditor

I use CKEditor in Drupal 8. I want that every link will open in a new tab of browser. I want that the code look like this <a href="#" target="_blank">my link</a> But if I use the ...
0
votes
0answers
30 views

Custom Content Type Won't Save Link value

I've created a custom content type, several of the fields are links, but for some reason when I try to add a value to a few of the links, they aren't saving their values. It's strange because I ...
2
votes
1answer
71 views

How do I create an ajax link?

I want to create an ajax linking a view (front page, for example). I create an ajax edit link to edit content directely in the node. I success to add a link but when i click to it, a popin was ...
0
votes
1answer
51 views

Migrating link fields to Drupal 8

I am trying to migrate a link field field_url from a Drupal 7 site to my Drupal 8 one. The link field is compound, it has a title and a url value. In my process plugin I am selecting the right values ...
3
votes
2answers
409 views

Add class to content field (link)

I want to add a class to the <a>-Tag of a Field that consists of a URL-link and a link text (it's a field of type "Link") and the name of the field is content.field_c_button_link So with twig in ...
0
votes
1answer
34 views

Convert links in content to internal form?

If I create a hyperlink inside a text field (such as node body) with an internal path uri such as "node/1234" or "index.php?q=taxonomy/term/5678", then I can use an input filter such as pathologic to ...
0
votes
2answers
23 views

How to add a class to term reference link? [duplicate]

I want to add a css class through Manage Display to a term reference field's anchor tag. Is there any module available for achieving the same?
0
votes
1answer
18 views

Re-use fields in a content type

I have a content type with 4 different sections to it. At the bottom of each section, there are 2 "Call to action" links. These links all point to the same 2 urls. I'd like to be able to set up 2 ...
1
vote
1answer
35 views

Referencing logged user and node relations.

I am trying to solve a problem with no luck: I have 4 objects in Drupal: -Company user (role company) -Mod user (role moderator) -Node Project -Node Person (not a user entity) Company user can ...
-1
votes
1answer
45 views

How to create a link for field value?

I am using views in that views i can able to give only title field as a link.I want to give field value also as link.while clicking on field link i need history of that field example-In my ...
0
votes
2answers
42 views

How to add User edit link in main menu [duplicate]

Site link here, in this 9 is the user id.it is different according to register users. When add link in main menu there is an option Path textbox in that text box if i add "user/9/edit" then link ...
2
votes
1answer
74 views

Get title from Route

I am trying to print out a few links on a custom page template. I would like to use the title and url from each route. I am trying to print out the title from the route. I know I can get the url ...
0
votes
1answer
31 views

Scroll to links for articles on page

I would like to create a block and place that on the right hand side of my site. Within the block I would like to have a list of links. The links would scroll the viewport down to that article. The ...
1
vote
0answers
47 views

One-time registration email link

I need to send to specific persons one-time registration email links, in order to create users with specific roles. The "normal" registration should be available as well.
0
votes
1answer
37 views

how to use panel to display content types but using condition? [duplicate]

I have two content types. Liquor product which have fields [Title, origin, effects, side effects, price, how to drink, etc.. ] Liquor store fields are [store name, address, contact no.] I am used ...
1
vote
1answer
43 views

Best way to migrate inline images in content fields to drupal 7

I am trying to create say "Articles" manually using scripts. Basically I am reading data from mysql table and creating nodes programmatically by looping the tables. However in mysql content field ...
1
vote
1answer
100 views

Setting current node url as default value for “Link” field

I have a content type with a field type Link. I would like to set default text and url for the field. Under: Structure » Content types » MY CONTENT TYPE » Manage fields I tried entering # and ...