CMS Builder Head code interfering with Form code

6 posts by 3 authors in: Forums > CMS Builder
Last Post: January 26, 2010   (RSS)

So I have a form on a page that posts to another page.. that other page has some cmsb script on it to display news data and whatnot.. but also has some regular php code to submit the form data to an email. And the form works just fine.. but it seems to interfere with cmsb error codes and displays a Undefined variable error code from the form. You can run tests on this.. right now it's going to my email. Let me know what you suggest I can do to get the page to ignore this error.

thanks
form page: http://www.gaalliance.org/bap/comments-prep.php
form destination: http://www.gaalliance.org/bap/comments-confirmed.php
John Tedesco

Creative Director



JAM Graphics

Re: [jtedescojam] CMS Builder Head code interfering with Form code

By Dave - January 26, 2010

Hi jtedescojam,

Can you attach both php pages so we can see the code?

Thanks!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] CMS Builder Head code interfering with Form code

Sure... "comments-prep.php" is the file with the form... "comments-confirmed.php" is the result.

thanks
John Tedesco

Creative Director



JAM Graphics

Re: [jtedescojam] CMS Builder Head code interfering with Form code

By Chris - January 26, 2010 - edited: January 26, 2010

Hi jtedescojam,

I don't think the errors you're getting have anything to do with CMSB-related code on that page. They're all coming from lines 264-317, which is where you're generating a string to send to mail():

Notice: Undefined variable: Section in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 264
Notice: Undefined variable: Question in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 268
Notice: Undefined variable: text in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 271
Notice: Undefined variable: proposed in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 274
Notice: Undefined variable: reason in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 277
Notice: Undefined variable: radio2 in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 281
Notice: Undefined variable: page2 in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 283
Notice: Undefined variable: Section in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 284
Notice: Undefined variable: Question in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 288
Notice: Undefined variable: Text in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 291
Notice: Undefined variable: Proposed in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 294
Notice: Undefined variable: Reason in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 297
Notice: Undefined variable: radio3 in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 301
Notice: Undefined variable: page3 in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 303
Notice: Undefined variable: Section in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 304
Notice: Undefined variable: Question in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 308
Notice: Undefined variable: Text in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 311
Notice: Undefined variable: Proposed in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 314
Notice: Undefined variable: Reason in /hermes/web07/b2561/as.gaalliance/public_html/bap/comments-confirmed.php on line 317


Try replacing each of your variables in that string:

Section: $Section-Heading1

with:

Section: ".@$_REQUEST['Section-Heading1']."

I hope this helps! Please let me know if you have any questions.
All the best,
Chris

Re: [chris] CMS Builder Head code interfering with Form code

Sorry for this. the (-)DASHES in the form Input ID's and NAMES were causing the issue.

SORRY :(
John Tedesco

Creative Director



JAM Graphics