Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Razz

    (@razz)

    Of course, as soon as I put out a call for help do I figure out the problem.

    I can’t account for the site suddenly having the redirect issue, but I at least found a fix.

    Because the site is being developed under a subdomain, there are specific rewrite rules required for the .htaccess file. Help was found here:

    https://stackoverflow.com/questions/21947648/default-wordpress-htaccess-causing-redirect-loop

    which pointed me to the official WordPress htaccess examples page. There, I found an .htaccess example specifically for WordPress installed under a subdomain, specifically this:

    # BEGIN WordPress
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # uploaded files
    RewriteRule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule . index.php [L]
    # END WordPress

    When replacing my main .htaccess file with this, my site immediately responded to trying to access /wp-admin/ with great success. Permalinks have been changed back to %post-name% instead of the Default, and everything works as it once did.

    I hope my plight will be useful to anyone else who has this specific problem.

    Got the following to work on AI1EC 1.10 Standard and WordPress 3.6 :

    Open wp-content/plugins/all-in-one-event-calendar/app/helper/class-ai1ec-app-helper.php. The line in question is line #198 and reads

    'rewrite' => true,

    If you have a hard time finding it, or you are not on AI1EC 1.10 Standard, search class-ai1ec-app-helper.php for “args for custom post type” (excluding quotation marks).

    In that section, change 'rewrite' => true,

    to

    'rewrite' => array( 'slug' => 'event'),

    You can replace ‘event’ to anything you want the permalink to be.

    Save this file and then log in as an administrator to your WordPress installation. Go to Settings > Permalinks. Change the permalink format to something other than what it currently is. Hit “Save Changes” and the page will reload with your new settings. Select your previous settings (the permalink structure that you prefer…any one will do) and hit “Save Changes”.

    Your AI1EC links should now not have “ai1ec_events” in the address.

    However, mine does still have “instance_id” attached at the end…so if someone could help me out with that one, it would be much appreciated.

    Thread Starter Razz

    (@razz)

    i hate myself. i solved my problem. basically, you need to put the is_category() function in an if statement (which i knew) but the issue was the parameters for the is_category() function. upon finding the Conditional tags page, i figured out the problem.

    Here is my code in case anyone ever needs to know this.

    <?
    if (is_home()){
    <img src="welcome.jpg">
    }
    
    if(is_category('Travels')){
    echo '<img src="travels.jpg">';
    }
    if(is_category('Musings')){
    echo '<img src="musings.jpg">';
    }
    if(is_category('Lunch')){
    echo '<img src="lunch.jpg">';
    }
    ?>
Viewing 3 replies - 1 through 3 (of 3 total)