Hot answers tagged

14 votes
Accepted

500 error on installation since version 2.3

I might be shooting in the sky, but make sure that in your in your .htaccess you have RewriteBase / after RewriteEngine On
user avatar
11 votes
Accepted

How do I change the URL used to access Craft?

The cpTrigger config setting is what you're looking for.
user avatar
  • 66.4k
10 votes
Accepted

Getting logged out of admin area when refreshing site

The problem was actually Chrome using iOS emulation when viewing the site, thus spoofing the UA string into something different than the usual Chrome UA string when logging into the admin area. ...
user avatar
  • 1,332
10 votes
Accepted

Migrated Server, Now Getting Logged Out Constantly

Most likely wherever Apache/PHP is configured to save session files doesn't exist or isn't writable. If you've got the overridePhpSessionLocation config setting set to true, then that will be in ...
user avatar
  • 66.4k
9 votes
Accepted

"Conditional" field layout - hiding or showing fields based on another field

The feature request for this has been very popular since day one, so hopefully it's something P&T adds to the core some day. For the interim I just published a small plugin called Reasons, which ...
user avatar
8 votes
Accepted

Is it possible to display additional fields on the entries list in admin?

Yes, since Craft 2.3 you can edit the CP's index views for entries, assets, etc. from a plugin. Have a look at the documentation for the hooks defineAdditionalEntryTableAttributes and ...
user avatar
  • 35.8k
7 votes
Accepted

Asset URLs not HTTPS

Yii will check for the following server environment variables when determining if it’s an SSL request: HTTPS – should be set to “on”, “ON”, or “1”; or HTTP_X_FORWARDED_PROTO – should be set to “https”...
user avatar
6 votes

How do I change the URL used to access Craft?

You can edit this in the general config https://craftcms.com/docs/config-settings#cpTrigger return array( 'cpTrigger' => new-url, );
user avatar
  • 1,517
6 votes

Recovering (or creating a new) admin account

Download and install a fresh copy of Craft from http://buildwithcraft.com somewhere (doesn't matter if it's the same computer your existing site is on or not). During installation, remember the ...
user avatar
  • 66.4k
6 votes
Accepted

Can plugin have two links in admin navigation?

The top links in the CP header are often called nav tabs. Beyond the "default" nav tab for your plugin (pointing to the plugin's CP section), it's possible to declare additional tabs via the ...
user avatar
6 votes
Accepted

Specifying administrators for localized sites?

Yes. you can: Here I created a User group which has only access to the english part of the content. As you can see these are checkboxes. So you can grant access to multiple languages at once.
user avatar
  • 3,664
6 votes

Locked out of my Account, how to get back in?

This is not actually my answer since it's from Andrew Welch on Twitter here: https://mobile.twitter.com/nystudio107/status/1063135843441954816 If you have access to MySQL, you can change the admin ...
user avatar
5 votes
Accepted

Can I disable the control panel?

Good call Brad! Not sure why that didn't occur to me :) Here's how that's done: # Kill admin access RewriteCond %{REQUEST_URI} ^(.*)/admin RewriteRule ^(.*)$ - [F,L]
user avatar
  • 281
5 votes
Accepted

Loading an existing entries drafts in template/frontend

After doing some digging around I found the getDraftsByEntryId(entryId, locale) method of the craft.entryRevisions service that might help. The following should return the first draft of an entry. ...
user avatar
5 votes

"Conditional" field layout - hiding or showing fields based on another field

No, Craft doesn't offer conditionals in field layouts. Coming from Wordpress/ACF, I'd personally like to see something like that implemented in the future, but for now I can think of two possible ...
user avatar
5 votes

Recovering (or creating a new) admin account

I'm rusty on MySQL so it took me a while to go through this. I'm leaving this here for future internet travelers. It's based on Brad's solution, so read through that first, then you can use these ...
user avatar
5 votes

How do I UNLOCK my account?

If you don’t have access to another admin account, you could unlock the account directly in the database. Change the lock value to 0 for the account in the craft_users table.
user avatar
  • 35.8k
5 votes

Plugins not showing in Admin

Probably the name of the folder isn't the plugin handle. Check inside the plugin's folder to see if the actual plugin folder is inside there. For instance: forge@nys-production ~/nystudio107.com/...
user avatar
4 votes
Accepted

Sort matrix blocks in admin by a field within the matrix?

There is nothing that will automatically sort blocks for you in the Control Panel. Without writing a plugin with some very fancy JavaScript, the only way to arrange blocks is manually. You can ...
user avatar
  • 23.6k
4 votes

Post to an action URL fails, Get works

I believe that when you post data using name='action' from a form that craft automatically uses the actionUrl to route the request properly, so that if your controller is here: /craft/plugins/...
user avatar
4 votes

500 error on installation since version 2.3

In case it helps someone, my issue was the permissions for the root index.php file...It was 666 (writeable by group) and when I switched that file permissions to 644, the installation was able to move ...
user avatar
  • 61
4 votes

How can I restrict tags that are able to be used?

That’s not possible, as tags are meant to be more of a “folksonomy” rather than a strict taxonomy. Sounds to me like categories would be a better fit for your needs. With those, the options are ...
user avatar
4 votes

Changing the default admin path

Have you got your htaccess file working ok? By default the htaccess file is named incorrectly, it should be .htaccess nothtaccess`. You can read about renaming that file in the installation docs. As ...
user avatar
  • 610
4 votes

Craft CMS Log Rotation

Craft will automatically 'rotate' logs into new files as each current file reaches the maximum size (~1MB). This is why, if you look in /craft/storage/runtime/logs, you may see craft.log, craft.1.log,...
user avatar
  • 3,400
4 votes
Accepted

Log in as different users in backend front end at the same time?

You can use "incognito mode" in your browser, or you use another browser or computer for this type of front end testing.
user avatar
  • 35.8k
4 votes
Accepted

Settings in Admin Panel Blank

There's a chance that one of your plugins is causing this behavior. Go into your craft_plugins table, and change the value of enabled to 0 for every single plugin. If your Settings page is then ...
user avatar
  • 23.6k
4 votes

Would it be possible to create a plugin to warn a user if a page is being edited

Inspired in part by Mats' detailed answer, I've written a plugin that does just this: MN Snitch Enjoy!
user avatar
4 votes

Order entries based on date field in the Control Panel

The CpSortableCustomColumns plugin lets you sort your element index tables on custom fields. Sounds like it does exactly what you want.
user avatar
4 votes

How can I add a favicon to the admin part of Craft?

If you go to Craft Settings > General you can add a site icon in there plus a logo for the login page.
user avatar
  • 671
4 votes
Accepted

Can I rename my craft/ folder?

Absolutely! In fact, you've outlined the steps needed to do so... Rename craft folder Change $craftPath value in index.php That's it!
user avatar
  • 23.6k

Only top scored, non community-wiki answers of a minimum length are eligible