cforms II User Forum

Registration is currently disabled.


Login form protected by Login LockDown.

Lost password?
Advanced Search

— Forum Scope —


— Match —


— Forum Options —


Wildcard usage:
*  matches any number of characters    %  matches exactly one character

Minimum search word length is 4 characters - maximum search word length is 84 characters

Topic RSS
magically appearing.
No, I'm serious....
August 7, 2012
4:27 pm
Mark Edwards

line 968 cforms.php

I have modified this line to output a comment..

$field = '<!-- tata --><select' . $readonly.$disabled . ' name="'.$input_name.'" id="'.$input_id.'" class="cformselect' . $field_class . '" '.$fieldTitle.'>';

and Lo and Behold … View Source… from the rendered form…

<li id="li--4" class=""><label id="label--4" for="cf_field_4"><span>Event Type</span></label><!-- tata --><br /><select name="cf_field_4" id="cf_field_4" class="cformselect" >

Now, I'm trying to get rid of the <br /> before the <select as it is stuffing up the rendering of the select boxes in the form. But, for the life of me, I can't see in the code where this is getting added in.

I added the comment in to see where the correct render line was in the code, but the <br /> seems to be coming from outside the plugin. Any ideas? This only appears to happen for "Select" type fields…

August 25, 2012
10:18 am
Munich, Germany
Forum Posts: 6400
Member Since:
March 6, 2005

This is your WP core or WP theme interfering with cforms and adding BR and P tags via the WP autop filter.

I'll change the position/priority of cforms in the chain of functions called by WP, which hopefully should fix this. Try yourself, simply open cforms.php, at the end of the file, look for:

add_filter('the_content', 'cforms_insert',101);

change to the above or an even higher number to see if that fixes your issues.

Forum Timezone: Europe/Berlin

Most Users Ever Online: 959

Currently Online:
30 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

tracedef: 43

mores: 21

Gyrus: 20

frozenwaste: 18

asuffredini: 15

photoworks: 14

Member Stats:

Guest Posters: 3762

Members: 1463

Moderators: 3

Admins: 2

Forum Stats:

Groups: 1

Forums: 4

Topics: 5359

Posts: 18741

Newest Members: juredujmovic, dreamkeeper, rajattyagi, wrokaa, lukass

Moderators: Paul (421), cnymike (8), sonika (95)

Administrators: Oliver (6400), Nicky (3)