I need to get rid of this company text field and Country drop down since the store serves locally.
Important : How I can overide the city (text area) to a drop down with my own custom city list.?
Extension1: you can install this free extension for display city
visit this link for how to install composer require php-cuong/magento2-city-dropdown
For more details how to set up check this link
Extension2: https://github.com/EaDesgin/Magento2-City-Dropdown
In your block \Magento\Directory\Model\ResourceModel\Country\CollectionFactory $countryCollectionFactory
public function getCountries()
{
$collection = $this->countryCollectionFactory->create()->loadByStore()->toOptionArray(false);
return $collection;
}
In your template file
<div class="field name required">
<label class="label" for="customer_country"><span>Country</span></label>
<div class="control">
<?php
$countryList=$block->getCountries();
?>
<div class="field country">
<select class="required-entry" id="country" name="country">
<option value="">Please Select</option>
<?php foreach ($countryList as $key => $country) {?>
<option value="<?php echo $country['value']; ?>"><?php echo $country['label']; ?></option>
<?php } ?>
</select>
</div>
</div>
</div>