Jump to content
AndZyk

Show page name under page title

Recommended Posts

Hello,

when you add a page you can see the page name of the page under the page title field. But when you change the page title afterwards, you have to go to the settings tab to also change the page name.

We have many clients that change the page title afterwards but forget to change the page name, because they don't look in the settings tab or forget it.

Is it possible to show the page name on the content tab under the page title?

I hate to say this, but I like how WordPress handles this better:

permalink.png.16590b8519b0357bb80773bbe79529eb.png

Or should I open an GitHub request?

Regards, Andreas

  • Like 1

Share this post


Link to post
Share on other sites

Yes, it's possible.

Set $config->advanced = true; on your config file and a "System" tab will appear while editing the template. And there you can make the change. See screenshot.

image.thumb.png.f04e2d8da2f1d9571aaa72316749441c.png

 

Similar thread:

 

 

 

Edited by Sergio
Added link to old thread.
  • Like 3

Share this post


Link to post
Share on other sites

@Sergio Thank you for the hint. 😉

This solution is ok, but I don't like, that the page name is now before the page title and takes up so much space.

A smaller page name edit field under the page title (like the WordPress one) or a quick link to the field in the settings tab would in my opinion be nicer.

I know that ProcessWire doesn't want to clutter up the back-end and that is a reason why I love it and I know that I could add a note in the page title field or a hook for changing the page name on every save.

But I think in this case, showing the page name under the page title would be better then hiding it under the settings tab. Maybe @ryan could consider this wish. 🙂

Regards, Andreas

  • Like 1

Share this post


Link to post
Share on other sites
4 minutes ago, AndZyk said:

This solution is ok, but I don't like, that the page name is now before the page title and takes up so much space.

Yes, is not the best solution from a UX point-of-view. But I don't think that adding it below the title, as WP does, is the best way around. In most cases, we don't want the user to edit the page name by mistake. In your situation, I would take a look at @adrian's PageRenameOptions module https://modules.processwire.com/modules/page-rename-options/.

Another option is to add a warning, using a hook, if the page title is edited to alert the user to also change, or check, the page name on the Settings tab. 

  • Like 3

Share this post


Link to post
Share on other sites

Thanks for pointing to that module @Sergio - I use it on every site. It would be hard enough for me to remember to change the page name to match a new title, let alone expecting a client to do it. Given that PW has the core Page Path History functionality, I rarely see the need to not change the name when the title changes.

  • Like 5

Share this post


Link to post
Share on other sites
4 hours ago, AndZyk said:

Is it possible to show the page name on the content tab under the page title?

 

You could do it with a quick JS/CSS hack: (after you did the advanced mode stuff described above)

let lis = document.querySelectorAll('#ProcessPageEditContent > ul.Inputfields > li.Inputfield');
lis.forEach(function(li, index) {
	li.style="order:" + index;
});
document.querySelector('#wrap_Inputfield__pw_page_name').style="order: 2";

(only tested with Chrome + AdminThemUIKit)

  • Like 2

Share this post


Link to post
Share on other sites
6 hours ago, adrian said:

I use it on every site

Me too, it's an essential module.

I hesitate to say "should be in the core" because I know the PW philosophy on such things. But I wonder if certain modules that are widely needed and used could be highlighted somewhere within the core. So for instance there could be a link to PageRenameOptions from the PagePathHistory module config, so that when you install that module you get a heads-up that there is a useful related third-party module that you might want to consider also.

  • Like 1

Share this post


Link to post
Share on other sites

And what about a multilanguage site?

In general I think the easiest solution would be to display the page name and a link below the title that links to the Content tab. In case of a multilanguage site, display the current language name only. 

  • Like 1

Share this post


Link to post
Share on other sites

Thank you all for your feedback. 😀

I will then try out the Page Rename Options module, because it looks more like what I am looking for.

Regards, Andreas

  • Like 1

Share this post


Link to post
Share on other sites

Just in case and in order to complete the list of possible ways and solutions.

And this comment by @szabesz to even more possible solutions:

  • Like 2

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By louisstephens
      So I ran into a very strange issue today. I have a template with a pagetable and I went to add an item to it, when I went to select an image (for an image field) the page instantly threw up an error
      "ProcessPageSearchLive: No search specified"
      The page's content also switched to the image attached. This all worked perfectly last week (local mamp box). Has anyone experienced this before, and how did you solve it?
       

    • By louisstephens
      So I ran into a strange error this morning when trying to publish a page. I went to publish a new page under "clients", but I get an error that says "Cannot be published until errors are corrected". I thought perhaps I had missed a required field so I checked, but none of the fields are marked as required. I then checked to see if I could just add a basic page (default basic-page.php template) under the homepage, but I get the exact same error when trying to publish. When looking at the template, I don't see any error messages being displayed above any fields.
      The odd thing I found though was if I got to "settings"  and uncheck "unpublished", I can then publish the page without errors. I did upgrade earlier today to the newest version to hopefully fix an issue I had yesterday (which it did). Has anyone run into this error before? 
      **EDIT**
      Well, after a lot of staring and pulling my hair out, I found the issues. I had installed multi-language support sometime ago (and due to the project changing, had to remove it). Apparently in my haste, I did not remove all the dependencies so it was still trying to check for the multi-language title (I am guessing) even though it actually wasnt on the page. I went through the database and removed it and can now save/publish pages without issues. 
    • By Pip
      Hi everyone, 
      Is there a way for us to replicate the "http://mydomain.com/processwire/page/edit/?id=xxx" and change the template to match my site template? 
      I'm terribly happy with the admin / backend page edit. It covers literaly everything I want to empower my non super admin user in updating pages such as validation, repeater management, file upload. 
      I wish not to allow the users to see the backend for both security and aesthetic reasons. 
      Thanks and hope to hear from you soon. 
       
    • By EyeDentify
      Hello dear PW gurus.

      I have stumbled over a strange error that i all of sudden got when trying to upload an image to a images field on a page.
      There where images allready stored in the field that i wanted to keep, but during the upload the error apear and after that all images are gone from the field and i can´t upload any, i just get the error every time.
      I am running ProcessWire 3.0.153 dev.
      Update:
      After looking in the assets folder i find the folder for the page and the image files seems to be there including the ones i tried to upload when the error occured.
      But they don´t show up in the images field in the page editor.
       
      The error reported:
       
      SQLSTATE[01000]: Warning: 1265 Data truncated for column 'ratio' at row 1 And here is a screenshot of the event:

      The TracyDebugger Error reporting:

      I hope you fine folks could point me in a direction.
      But it seems our old pal set_time_limit() is back.

      Regards, EyeDentify
    • By Spyros
      Hello
      I'm having a strange issue with the $page->find(), for some reason I'm missing some of the pages from the results. I found then that I was missing all the pages with the same "PAGE NAME". Is it a bug or am I missing something?
      PS 
      If I change the "PAGE NAME" of one of the missing ones then I'm retrieving the page without any problem.
      Thank you
×
×
  • Create New...