WordPress.org

Forums

Event Organiser
[resolved] Category link 404 and no sidebar (8 posts)

  1. ZeroGravity
    Member
    Posted 9 months ago #

    This has happened for the last couple of versions while I have been developing the site.

    1) When clicking on the category at the bottom of the event I get a 404 error.

    2) single-event.php in not calling the sidebar.

    http://wordpress.org/extend/plugins/event-organiser/

  2. Stephen Harris
    Member
    Plugin Author

    Posted 9 months ago #

    Hi Darren,

    Sorry for any inconvenience. The single-event.php doesn't call the sidebar by default (and hasn't done, at least since 1.3). You can copy the default template into your theme file and edit it there to include it (as well alter how events appear / what details are shown etc). See this page.

    Regarding the 404 categories, can you confirm that its not a permalink issue. Does www.yoursite.com?event-category=a-category-slug show events for that category slug?

    If not - in the settings could you uncheck 'group occurrences' and check 'show past events'. If events do show, then this is related to a bug for which I have a patch and will release shortly.

    Apologies again,
    Stephen

  3. ZeroGravity
    Member
    Posted 9 months ago #

    Thanks for the reply Stephen.

    I stumbled across the template solution after curfew last night and haven't been able to reply until now. I am working on a solution that will fit with Genesis.

    I also thought of the possible plugin issue this morning. I activated a random image plugin yesterday so wonder if that is causing the problems.

    No need to apologise. It looks like the issues are with my setup not the plugin. :) Shall keep you posted on findings.

  4. ZeroGravity
    Member
    Posted 9 months ago #

    Hi Stephen,

    Using http://www.yoursite.com?event-category=a-category-slug worked. I am wondering if a setting in my functions.php may be influencing this. I didn't think of it before now because standard post category listings work.

    I have turned off conical redirect so I can have a HTML landing page in the same folder as the WordPress install while I am developing the site. Saves time having to move the WordPress site and all that involves an no one knows the WordPress site is there.

    /** turn off the canonical redirect for development */
    if(!is_page()&&!is_single()) {
    	remove_filter('template_redirect','redirect_canonical');
    }

    Could that snippet be creating my 404 errors?

  5. Stephen Harris
    Member
    Plugin Author

    Posted 9 months ago #

    Seems like it's a permalink issue. Canonical redirect shouldn't effect this though...

    I'm assuming you've got pretty permalinks enabled in WordPress' Settings > Permalinks page. Save the event organiser permalink settings. Then go WordPress' Settings > Permalinks and save those as well. This will flush the permalink - meaning if the category rewrite rule hasn't be added - it should now be.

    If it still doesn't work, I'd recommend using this plug-in to check what the category URL is being interpreted as. It's likely that there is another rewrite rule that WordPress is using - and that this rewrite rule is taking you to something that doesn't exist.

  6. ZeroGravity
    Member
    Posted 9 months ago #

    Yes I have pretty permalinks enabled and the custom option set to /%postname%. I saved both permalink pages, Event Organiser first and the problem still occurs. It works fine with standard post categories.

    I installed the plugin but I'm not quite sure what to make of the output. Here are the category references.

    category/(.+?)/page/?([0-9]{1,})/?$
      category_name: (.+?)
              paged: ([0-9]{1,})
    
    category/(.+?)/?$
      category_name: (.+?)

    and

    category/([^/]+)/page/?([0-9]{1,})/?$
     event-category: ([^/]+)
              paged: ([0-9]{1,})
    
    category/([^/]+)/?$
     event-category: ([^/]+

    Are you able to shed some light on these for me? Thanks.

  7. Stephen Harris
    Member
    Plugin Author

    Posted 9 months ago #

    Ah it is a permalink conflict... what structure do you have for the event categories? It seems you have the structure category (e.g. yoursite.com/category/a-event-category-slug).

    The problem is that WordPress (by default) uses this structure for post categories - and these are seperate things. What you've post above tells me that WordPress is interpreting the url to be for a post category page (which does't exist) and not an event category page.

    Try using the structure event-category, say, for the event categories permalink structure. Then flush the rewrite rules (save the WordPress permalink settings) see if yoursite.com/event-category/a-event-category-slug works.

  8. ZeroGravity
    Member
    Posted 9 months ago #

    Problem Solvered!!! Thanks Stephen.

    Now I just need to play with the Genesis templating.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.