Is it possible to have a simple URL like http://example.com/page_slug and add the page to whatever position I want in the menu especially a child position?
The problem is that whenever I attach a page to a parent menu, I got many levels in the slug like: http://example.com/parent/page_slug
I got the answer here.
With the option 'routes' in the header section, I can set a specific slug regardless of the folder name or the parent article.
routes:
default: '/my_slug'
Related
I would like actually to be able to do some modifications on the layout we receive once we get https://demo.docusign.net/Signing/StartInSession.aspx?t=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx
So there I would like to remove :
the whole 'other actions' button/menu
the whole block with css class: 'title', 'id-card', 'image', 'information'
removing the padding of the body to get the document a little higher (in place of the above information block)
Is there a way to give parameters to get a custom layout for this session, or we have to do 'dirty things' in order to remove those elements from the DOM after we loaded it from the url ?
Thanks !
Edit: Actually we are not allowed to access the elements of the received frame:
Remaining only query strings options ?
The whole options are there:
https://www.docusign.com/supportdocs/pdf/docusign-signing-resource-file(v1.1).pdf
It is in the admin menu, under 'Brands' menu, and you need to 'edit' an existing label in order to access the ressource file management :)
I have a generic page template that I wish to reuse for lots of pages, but each page also needs to have its own template within that. The generic page template might include a page banner and breadcrumbs for example.
The way I'm currently doing this is having every page be an ad-hoc clone of the generic template, however, this isn't easily managed when changes need to be made to the generic template itself as I then need to make that change on all ad-hoc templates too.
I could get around this by creating a new page that uses the generic template at the parent level and then nest all my pages under it, acting as a master page, but I feel like that's polluting the content tree unnecessarily as I already have a master template at the very root.
Is there a way to make page templates inherit from other templates without actually creating a physical master page in the content tree?
If it were possible to make specific webpart containers not shared to all pages that use the same template that would work too.
ad-hoc are not good as you understand.
You can have 2 master templates: 1 will be your root, 2nd one down in the tree. All page under second master can inherit both templates at same time:
For example you have:
the root master for the whole site that contains site menu and footer and placeholder
your store master template for you store which has store menu and banner and placeholder.
All your products under the store master will inherit both store master and root master. For that you have to go
template >specific ancestor pages > and check both masters : root and store
Another option to share content is add placeholder web part to your pages and point it to the shared page (you have to set "Page to display" property). I have a couple masters that are completely different but they share the same footer. So I have place holder on both of them that point to this shared footer page.
Having a page template inherit from another template will work, the problem is if you don't use that page template on a page, there will be no content for the child page template to inherit from so defeats the purpose of inheritance. Best bet would be to add those items to a parent page template. Assuming a content tree like so:
Page
-- Page 1
-- Page 2
On "Page" add your items in that template and hide or show them based on page type and or level. Then for the "Page 1" and "Page 2" pages, set a default page template for those page types. Then the user will not have to add or select a template, it will auto select for them. Then all they ahve to do is add content for the banner under that "Page 1" or "Page 2" page. The breadcrumbs should then auto show based on the child page showing or setting the node level.
I have created menu and its child links like
About
contact us
portfolio
our location
I have used menu block to display sub menu only when about in click and display sub menus in another layer.
Now my requirement is when i click on any sub menu in parent menu then the parent menu should be active. To achieve this task i searched a lot off and found menu position module for this purpose. I have configured and specify page path in Restricted to certain pages, but now it is now working. What i have mistake or any other solution for this problem. Please let me know the right solution.
<?php
$block = module_invoke('menu_block', 'block_view', '1');
print render($block['content']);
?>
I am adding this code below the topbar menu. but inside the menubar wrapper.
If my understanding clear then you will need this menu - Menu Position https://www.drupal.org/project/menu_position
This module allows for the creation of rules that will dynamically add the current page into the menu system at the requested spots.
If you dont want to use this module then you will need to append menu-id in the menu link's li and then through jquery / js will need to add certain classes to parent menu items.
Actually there is no requirement to use any module for this situation. What i have done to achieve it. I just modified template.php of zurb foundation theme. i have copied the code(foreach loop code) from here and added to the template.php file as mentioned in the page and added the css like below:
#main-menu li.active-trail a,
#main-menu li a.active, #main-menu li a:hover {
background:#fec325;
/* IE6-9 */
}
and that's it. i have achieve what i want. I hope anybody who is looking same kind of problem can find this solution useful for this kind of requirement.
I would like to use a different layout view for anonymous users. I have tried using url alternates and I am not sure how I can create a layout for anonymous users since there is no particular url for them.
The idea is that, if a new user visits the site I want to show a splash screen with very limited information with an option to register/ login to view the full site. This splash screen will have a completely different layout / look and feel from the rest of the site.
I tried using the Anonymous user layer but all I could do was move widgets (maybe I am missing something).
Any help would be greatly appreciated.
Thanks!
There is no out of the box solution but you can do something like this to get what you want:
Add new layout in a file with the name of your choosing - for example, you could name it Splash.cshtml.
Add the code below to the top of your Layout.cshtml template:
#if (WorkContext.CurrentUser == null) {
#Display.Splash()
return;
}
The code will check if the user is logged in. If it's not, it will render the content of your Splash.cshtml template, and stop the rendering of the rest of the Layout.cshtml template.
If you need to display any of the widgets in your Splash.cshtml template, you could add it by simply adding #Display(Layout.NameOfTheZone) where you should replace NameOfTheZone with the actual name of the zone you're using inside the Layout.cshtml template. Generally, anything that you use inside Layout.cshtml template with the Model object, you can use through Layout object inside any of your views.
I have the following fields inside a view:
User ID
Teaser
I selected "exclude from display" for the User ID field.
In the Teaser field, I selected the "rewrite the output of this field" option. This way, I can use html to completely control the structure of the view's output. Moreover, I can call the User ID field by using it's token, [uid].
For example, I can do the following in the teaser's rewrite:
Visit Profile
The problem with the above code is that the path is relative. It will only work on the front page of the site.
For example, if this link is clicked in
www.example.com/node/1
then it will visit a non-existent URL of:
node/1/user/[uid]
I have tried the following: http://chopapp.com/#o7osql65
But views fields does not allow PHP codes.
I might be approaching this entirely wrong. Does anyone have any suggestions? Thanks.
You'll want to rewrite the output of the UID field, and have it be rendered as a link. Even if you exclude it from display initially, it will still be available as a link via its token to other fields. One of the options when selecting to 'output this field as a link' is to make the link absolute.