• Resolved wpguillaume

    (@wpguillaume)


    Hello @bastho,

    To comply with the graphical design on our website, we use only one map marker among the ones available.

    The solution we found is easy enough but needs to be applied again after each plugin update. (See below.)

    Is there another, better, update-compatible solution? Or could this feature be added to the plugin, ie, selecting in the plugin settings the marker(s) available in the post editor? Ideally, if only one marker is chosen, then the ability to select the marker in the editor should be disabled.

    Thank you!

    ***
    To select only one marker, for instance the orange #e87f0f one.

    1. In /wp-content/plugins/event-post/eventpost.php, inside function retreive() (sic), replace:

    if ($ob->color == ''){
        $ob->color = '000000';
    }

    with:

    if ($ob->color == ''){
        $ob->color = 'e87f0f';
    }

    2. Inside /wp-content/plugins/event-post/markers/ delete every <rrggbb>.png file but e87f0f.png
    ***

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Bastien Ho

    (@bastho)

    Hi,

    Thanks for using this plugin.

    For a more reliable replacement, you can put your marker(s) in a custom directory: in your theme or anywhere else and set the path in settings page.

    It will survive to the next updates.

    Thread Starter wpguillaume

    (@wpguillaume)

    Hi @bastho,

    Nice! ??

    For future reference, I was wondering why there were two settings for this, and I set them like this (the trailing slash was necessary):

    – For “répertoire de marqueurs personnalisé après ABSPATH/”, I put “wp-content/plugins/event-post—markers/”
    – For “URL du répertoire de marqueurs personnalisée”, I put “https://<our-website.tld>/wp-content/plugins/event-post—markers/&#8221;

    Thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Enforcing one map marker only instead of choosing among several’ is closed to new replies.