Please disregard the 'View article...' shown at the bottom of many posts as this is the result of restoring old forum posts from a backup.

Editing any settings or module content opens in the front page of the site

I have a page with a custom theme having basically index.php for all pages except the front page is frontpage.php. Now when I set it up, something goes wrong since when ever editing a module content, adjusting any settings, it opens all on the front page view, not on the index view. 

How should this be debugged that would find the proper way to set it up?


  • Do you have an 'action_map.php' file within the theme with lines which aren't commented out? The logic for selecting the theme/subtheme template is found in the expTheme.php subsystem file, the getTheme() function at line #574.
  • Ouch, didn't get any email that you had answered here.
    Yes, the lines not commented out are following:

    The rest is commented out except of course the opening and closing of the php (and "the if sentence" related to it).
  • I do not see the website would act based on this exptheme.php logically. The fallback theme should be index.php, right? Anyway, it is falling to frontpage.php that is set up as a Default / Front page. 

    There are two type of "default" pages that confuse a bit but I have index.php page the one that is wished to be opened when editing any module or settings. It insists to open the frontpage.php all over when editing. 
  • I'll be out for a it only when editing items on the 'front page' or when editing any item?
  • Editing anywhere.
    I think the loop is cut that it doesn't redirect it back to the right index theme. I sent via email earlier those two theme files. Maybe something wrong in those and I'm blind. 
  • I have not found a solution yet. :(
  • I'm thinking that your system (and maybe Exponent in general) thinks the page your on is the 'default' page and therefore loads that subtheme template.  A possible quick fix MIGHT be to edit the theme's action_maps.php file adding the following:
    '*'=>array(                     // wildcard for all modules
    'edit'=>'Default' // 'edit' action will use the 'Default' subtheme
  • edited August 2017
    Hello, that indeed works for the edit. But when I save the edited text, it jumps again to the front page.
    So, we have a point here, we are going for the right direction.

    So, if I submit a contact form, the next page "Please confirm your submission" still goes also for the front page that is not very handy. Also after submitting the form (Thanks for your submission) you stay on the front page, not contact page.
  • Just to clarify...when you say it jumps back to the front page are we talking it displays the front page CONTENT (e.g., the actual front page), or uses the front page SUBTHEME TEMPLATE?
  • It uses the front Page subtheme. But if the front page is e.g. a full page slideshow, you barely see anything else. 
  • After looking at the code, it is operating as expected, but not as YOU would desire...Exponent attempts to maintain the subtheme from the calling page (e.g., I believe you are only experiencing this when editing or submitting a form from the home/default page).

    I'll have to put some thought into a possible work-around for the form submission since we are sending form data (PUT) instead of passing commands through the url (GET)
  • I believe this happens with any action that wants to EDIT or SAVE something, e.g., edit or save configuration info, taking a new module into usage etc.
  • Ok, you can likely address the issue with forms with another entry in the action_maps.php file
    'forms'=>array(                     // forms module
    '*'=>'Default' // wildcard for all actions will use the 'Default' subtheme
    I'm investigating a non-intrusive method to prevent changing the behavior of Exponent for those that expect it to act as it has been doing.
Sign In or Register to comment.