Applying different coding to extra fields.
-
I have the extra fields module and awpcp 3.0.1 installed on my wordpress site, I’ve added two extra fields into my listings, one for physical address, into which I’ve added a section of code to convert that field into a google maps link like so
$html .= ”;
} else if (count($value) > 0) {
$value = awpcp_extra_fields_render_field_single_value($field, $value[0]);
$html .= sprintf( ‘<span class=”awpcp-extra-field-value”><address>%s</address></span>’, $value );
this also uses the convert address to google maps link plugin.
Now I’ve added a second extra field called keywords, I was hoping to change the field name and value to the same color as the background so they aren’t on my listings looking messy but will still be recognized by the search form. My problem is that awpcp extra fields php file doesn’t differentiate between one field and another, so the address coding is affecting my keywords field and if I were to hide my keywords field I would also be hiding the address field. Is there any way of differentiating between different fields? for example some type of Query against row number etc?Thanks in advance.
https://www.ads-software.com/plugins/another-wordpress-classifieds-plugin/
- The topic ‘Applying different coding to extra fields.’ is closed to new replies.