Answer the question
In order to leave comments, you need to log in
How to change the output of the country selector?
Here is the code that displays a list and a button next to it! Is there a way to display links when you click on a cat. the language has already changed.
if ( $countries ) : ?>
<form name="wcpbc-country-selector" method="post">
<select name="wcpbc-manual-country">
<?php foreach ($countries as $key => $value) : ?>
<option value="<?php echo $key?>" <?php echo selected($key, $selected_country ); ?> ><?php echo $value; ?></option>
<?php endforeach; ?>
</select>
<input type="submit" value="select" />
</form>
<?php endif; ?>
Answer the question
In order to leave comments, you need to log in
<?php foreach ($countries as $key => $value) : ?>
<form method="post">
<input type="hidden" value="<?php echo $key?>" name="wcpbc-manual-country">
<input type="submit" value="<?php echo $value?>" />
</form>
<?php endforeach; ?>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question