How to use custom page titles on different themes in Concrete5? - concrete5

I am using Concrete5 5.6.3.3. I have multiple themes active on the same site. The current page <title> uses the SiteName::PageName format across all themes. I want to use a custom titles on different themes.
For example on theme1, I would like to keep the SiteName but on Theme2, I would like to remove SiteName and use something else.
I tried adding my own title on other themes' header but it does not seem to have any effect. It keeps showing me SiteName::PageName. How do I fix this?

You can set a variable called $pageTitle before you include header_required.
As you can see here, that variable will be used from outside of the element if it's set:
https://github.com/concrete5/concrete5-legacy/blob/master/web/concrete/elements/header_required.php#L19

Related

How to add new setting fields to an existing setting page in Wordpress

For a new Wordpress plugin development, I would like to add few custom fields in the exiting setting page of COD.
The examples I have found so far, most of them are creating a new setting page and adding setting fields there.
However I want to use existing COD setting page and add few more fields on the same setting page. How to achieve that ?
Edit:
Please note that I am trying to achieve that by writing a Wordpress plugin. I understand that it requires to use various Wordpress functions like register_setting(), setting_fields(), add_setting_section() etc. But the sequence they should be called is confusing. It is helpful if a sample example is provided.
There are some important links that describe how to add new menu-page/submenu-page/options etc :
https://codex.wordpress.org/Administration_Menus
https://codex.wordpress.org/Creating_Options_Pages

Wordpress custom URLs for pagination pages

I’m trying to find a way to make custom URLs for each pagination page separated by "nextpage" tag. For example if first page is:
http://myblog.com/my-topic/
the second one will be:
http://myblog.com/my-topic/2/
Is it possible to customize this link? I want it to be:
http://myblog.com/my-topic/something/
or if it is necessary to contain number it can also be:
http://myblog.com/my-topic/page-2-something/
or
http://myblog.com/my-topic/2-something/
I was searching through a lot of plugins, but it seems non of them provide this option. It would be very useful for SEO, don’t you think? Each page url would contain some specific keyword related to its content. I guess the best approach would be to add a parameter to "nextpage" tag, containing specific word.
Is there some plugin or known hack for making this possible? I’m using the latest WP 4.7.3

How create different page for every different posts in wordpress?

I am developing a website where I am required to have individual pages for every different posts. I have to put 8 posts in eight different styles and properties, that is why I need those pages.
For example as we know for each page template we can make something like
page-templateone.php
Like that I want something similar for posts, just for example:
post-numberone.php
You can create a following php file in your theme folder
single-{post_type}-{post_slug}.php
For example, you have a post with a slug very-important-post. To have a template for this post alone, you need to create a file called single-post-very-important-post.php
If you'd like to be able to select template from the post editing screen, in 4.7 post type templates became available. Read more here
If you'd like to be able to do it in the older verion, take a look here

css formatting for a certain content

The thing (wordpress) is how can I make wordpress to format in a specific way (diferent from others) posts related to a certain category (it was in loop-single right?)
Does anyone have a nice link about this?
THX!
You'll want to use WordPress' Category Templates. For example if you have a category named news you can create template file named category-news.php (make sure you have permalinks enabled) or you can use the category ID. From there modify the contents of the category-news.php using CSS classes or IDs to display the styling you want for the category.

Theming the default search results page in Drupal

I'm trying to customise the mark-up of the default search results page in Drupal 6. Specifically I'd like to remove the search box and the title from the page - I know I can hide it with CSS, but I'd rather it wasn't rendered in the first place.
Ideally, in the same why that you theme a particular content type node by copying the node.tpl.php and renaming it to something like node-blog.tpl.php and then amending the mark-up accordingly - is there an equivalent way to do this for the search results page?
How you get the search box determines how you can hide it. Generally search boxes come from two places.
A block, created by views or some search module.
Defined / created in the theme itself.
How do you remove those?
A block is easy to remove, as you can in it's settings select which pages to display it on.
If the search box is created in the theme, it's a bit more tricky to remove. You have to find out what it is called, when it is defined which should happen in the template.php. Then you need to make a preprocess_function in your theme, where you with some logic, can remove the variable or set it to an empty string.
Alternatively, you could create a custom page.tpl.php for your search result page, where you exclude the search box, when it is printed in the page template.
So while it can be done, it requires some work in the second case if you want to purify your markup.

Resources