Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Hack, v3.0] Auto-open 'page options' (slug, tags, navigation, etc.)
#1
This is a quick hack (not upgrade-safe!) for auto-opening the page options in the page edit section. I am currently setting up a v3.0 beta testing site so having the options for slugs, navigation, etc. open without having to click is a bonus for me. Haven't checked on v2.03.1.

The file to be edited is at /admin/template/js/jquery.getsimple.js, look for the comment

Code:
// edit.php
at line number 206 or thereabouts. Right below that comment, insert the following snippet which simply slides open the options and then toggles the state of the button with which you would normally open up the page options.
Code:
// START Auto-open page options on edit page load
    $("#metadata_window").slideToggle('fast');
    
    $("#metadata_toggle").toggleClass('current');    
// STOP

Maybe this is helpful for someone else, too. Enjoy.
Reply
#2
I put this code into the small plugin Auto-open Page Options: it automatically opens the page options when editing pages.
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
#3
Thanks for that! Awesome.
Reply
#4
Cool!
Reply
#5
At first I thought "cool, just what I need" but then I installed it and realized it's basicly "off the other way". ;-)

I wonder if this could be slightly improved without too much trouble:
Save the state the page settings are currently at automatically.
If it's open ATM, keep it open, if it's closed, keep it closed.
So that this doesn't toggle to one fixed state each time a page is saved.

Or did I miss something?

Thanks a lot!!! :-)

Tom
Reply
#6
It auto opens page options when editing a page, so you do not have to click it, thats all it does.
Not sure what you are seeing.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#7
That is what I am seeing too.

Problem is: Sometimes I want that, sometimes not.
The only way to change the behaviour right now is to enable and disable the plugin, but that's pretty tedious for something I personally would love to be able to change on the fly in a consistent manner.

Example
When I first add a page I want the settings open for a while. With the plugin active it will work and stay open even if I save several times.
Now I have the settings finished and edit the content. If I leave the plugin active, I have to close the settings after each save or scroll down much further (save often, right? ;-) ).

But the only way to switch ATM is going through plugin activate and deactivate for something I personally would love to either toggle directly on the page or simply have saved automatically to the state it currently is at when I save the page.

So the result would be:
If I save the page with settings open, they stay open. If I save the page with settings closed, they stay closed.

My question was, if such a functionality can be added without too much trouble.
(IMO it should work like that by default, but that's just me ;-) )

Cheers and thanks,

Tom
Reply
#8
No all this does it trigger the thing, it is probably literally 1 line of javascript.
But its a good idea, open only on create perhaps would be easy to add a single conditional.

But remembering each page seems overkill.

You could use css and just move it to the bottom maybe below content.
I hate the page options, that is why in 3.3 it will be tabbed interface.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#9
Auto-open Page Options version 2.0:
  • remembers the state of the options, when the page was last saved, in a cookie (@Thomas Helzle)

@shawn_a: the old version (1.0) was deleted instead of being kept under archived versions in Extend.
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
#10
Oh is this your plugin? I thought this was an old unmaintained plugin.
cookies, clever.

Ill look into the archive issue.
Are you sure the archive was there to begin with ?

I checked nanogallery ( recently updated ) and its archives are fine.
I do not think the original version was ever copied into archives to begin with, maybe because it was so long ago, or maybe there is a bug with the adding the first one, or was a long time ago bug.

Ill fix it, it never moved the file.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#11
I think I had that as well. When I uploaded v1.1 of theme Startling, v1.0 was gone.
Reply
#12
Thanks a lot mvlcek! You're the best :-)

(Sorry for the late reply, I got no notifications from the thread until today).

Looking forward to the tabbed GUI Shawn!

Cheers,

Tom
Reply
#13
(2013-07-20, 05:53:43)mvlcek Wrote: Auto-open Page Options version 2.0:
  • remembers the state of the options, when the page was last saved, in a cookie (@Thomas Helzle)

I was looking for a Auto-Open plugin like this but why save last state in a cookie?

My thought is that you only need to have two states (every time) when editing a (special) page: 1. page options directly visible/open or 2. not!

Together with a custom field to accomplish that.
Reply
#14
Needed this Auto-Open plugin but only for my Special Pages. On my Special Pages I don't use the content and also wanted to hide the page meta info part. Some of that is already set with Special Page Configure.

I converted mvlcek's plugin into attached plugin 'specialpage_options_auto_open'. The Auto-Open trickers only on Special Pages so I removed the Cookie part.

Use on tab 'Pages', edit a Special Page


Attached Files
.zip   specialpage_options_auto_open.zip (Size: 1.01 KB / Downloads: 4)
Reply




Users browsing this thread: 1 Guest(s)