Forum Replies Created

Viewing 1 replies (of 1 total)
  • Hey guys. Just in case you still need a solution for that or someone else stumbles across this topic. I had the exact same problem and came up with a solution that works if you only have one certain adress that you want to use. If you need several carriers you need to create your own workaround with several variables.

    So here’s the solution:
    – Go to wp-content/plugins/aftership-woocommerce-tracking and open the aftership.php.
    – Find the following code:
    $this->display_track_button($values['aftership_tracking_provider_name'], $values['aftership_tracking_number'], $required_fields_values);

    and comment it out like that:

    /* $this->display_track_button($values['aftership_tracking_provider_name'], $values['aftership_tracking_number'], $required_fields_values); */

    Then put this code below it:

    echo '<a href="PUT TRACKING ADRESS HERE'.$values['aftership_tracking_number'].'" target="_blank">Track</a>';

    You need to put your tracking-adress where it says “PUT TRACKING ADRESS HERE” and the script will add the tracking-number for you. You can style the newly created button by adding some css to the class “.tracking-button”.

    Here’s some css you can use and adapt if you don’t want to do it yourself:

    .tracking-button {
    display:block;
    padding:6px;
    background-color: #FFCC00;
    width:150px;
    text-align:center;
    border-radius:6px;
    margin-top:6px;
    color:black;
    }

    ——-
    Hopy this works for you. Have a good one 🙂

    • This reply was modified 8 years, 11 months ago by pearlex.
    • This reply was modified 8 years, 11 months ago by pearlex.
Viewing 1 replies (of 1 total)