• In mstw-ss-utility-functions.php (in /wp-content/plugins/mstw-schedules-scoreboards/includes/) on line 794

    $ret_url = get_site_url( null, '/game/'.$game_slug, null );

    This will break the game pages for any users who make use of the site_url setting in wordpress.

    This should read

    $ret_url = get_home_url( null, '/game/'.$game_slug, null );

    which should have zero impact upon users who don’t have a different site_url to the install location for wordpress.

    https://wordpress.org/plugins/mstw-schedules-scoreboards/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Mark O’Donnell

    (@markodonnell)

    Hi gusc,
    Thanks for this post. I assume you referring to the Site Address URL setting on the Settings->General admin screen vs. the WordPress Address URL (??) This issue as been a bit of a confusing mess for some time. I will take another look at it and see how I can accommodate all (or at least more) of the possible configurations.

    Thanks.
    -Mark

    Thread Starter gusc

    (@gusc)

    Yeah, strangely enough get_site_url returns the “WordPress Address (URL)”

    while get_home_url returns the “Site Address (URL)”.

    In my particular case

    WordPressurl = http://www.domain.com/wordpress

    Site url = http://www.domain.com

    So for my visitors wordpress is not part of the url structure..

    Where this gets interesting is when creating games the posts are setup as

    http://www.domain.com/game/{gameid} (in the admin pages) (a valid page)

    but the links from the tables point to

    http://www.domain.com/wordpress/game/{gameid} (results in a 404 error page)

    The code in my first post corrected this, so it pointed to http://www.domain.com/game/{gameid} (the valid link, and it displays correctly).

    I can send you the link to our site if you would like, but would rather not post it for general view.

    Anyway hope that helps.

    I’m assuming that before you could accept this change, someone would need to confirm that when siteUrl is not set in the admin page, that get_home_url still returns the wordpress url.

    Plugin Author Mark O’Donnell

    (@markodonnell)

    You got it. That’s the issue. I need to figure out how to handle changes to both the WordPress URL and the site URL. I suspect WP provides a function or function to handle the various cases, I thought I was using it, but I guess I’ll dig a bit deeper. Thanks.

    -Mark

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Site_URL’ is closed to new replies.