Welcome, Guest ( Customer Panel | Login )




 All Forums
 VPCart Forum
 Problems and bugs
 Field 17 not in database when including form
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

WMS
Starting Member

3 Posts

Posted - October 15 2008 :  07:57:21  Show Profile  Reply with Quote
Hi,

I've been trying to incorporate a form in one of my sites, which has worked flawless however, there is an error on top of the page when I'm loading it:

---------------

Get Your Free Catalog

Field 17 not in database

Other text etc etc

---------------

I suspect this is caused because the first name of the form is:

<input type="text" name="CustomFields[17]" id="CustomFields_17_1" value="">

I'm guessing VPASP tries to replace the [17] when processing the template and/or the translations in the site?

The most obvious solution would be to rename the field to a different name with [ ], but that's not an option.

How can I make sure that the error doesn't appear in when loading the page?

WMS
Starting Member

3 Posts

Posted - October 21 2008 :  07:27:04  Show Profile  Reply with Quote
Anybody has any idea?
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - October 21 2008 :  09:06:32  Show Profile  Reply with Quote
Yes if the page that is loading includes a template then this will be what's causing the problem. The template is trying to display [17] just like [catalogid] in the products template. You shouldn't need to include the square brackets in the name of the text field.

Regards,

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

WMS
Starting Member

3 Posts

Posted - October 21 2008 :  09:09:33  Show Profile  Reply with Quote
That I do understand, but I can't change to not-using the square brackets. I need to find a way to (temporarily) disable using templates for this page.
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - October 21 2008 :  10:07:04  Show Profile  Reply with Quote
Which page is it?

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

Admiral The X
VP-CART New User

USA
52 Posts

Posted - April 04 2009 :  17:42:57  Show Profile  Visit Admiral The X's Homepage  Reply with Quote
better late than never but...

if you are willing to use java this may help...

I have a similar situation where i need square brackets to make bulletin board code [img] http:// type stuff, to accomplish this i used Javascript

first i define the piece of code i need to have the square brackets in inside of the tmp_product javascript header area as a java variable
yourstring= "{url=" + location.href + "}{img" + "}http://www.yoursite.com/shopping/" + tmpimg + "{/img" + "}{" + "/url}";

then for each instance of { i run the following code to apply an open square bracket
yourstring= yourstring.replace(/{/,String.fromCharCode(91));

and this to apply the close square bracket
yourstring= yourstring.replace(/}/,String.fromCharCode(93));

this code executes character replacement per execution so for example in my case i need to perform a loop to replace all the curly braces with square brackets.

in your particular case your addressing the "name" field... which i'm hoping is not the field java uses to identify HTML tags. i hope it uses the ID field, but I cant recall these small details - too many languages per day. start to get lost, lol.

Air Armory - Airsoft
http://www.AirArmory.com - shop
http://sitrep.airarmory.com - news
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000
0 Item(s)
$0.00