Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

Using POST as the form submission method

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 01-19-2011, 02:28 PM
 
almenzies almenzies is offline
 

Advanced Member
  
Join Date: Nov 2005
Posts: 66
 

Default Using POST as the form submission method

Hey,

I've set up a very simple product enquiry page so that people can submit questions straight from the product details page.

I'd like to post some variables from the product details page to the enquiry page, but when I use the POST method it does not work (I'm re-directed to a search page).

I assume this is a security measure and is being controlled by auth.php (or a file referenced from there).

It works fine when I use GET, but ideally I'd like to avoid having all the variables in the URL.

My product enquiry page looks like this:

Code:
<?php require "./auth.php"; require $xcart_dir."/include/categories.php"; require "products.php"; $smarty->assign("main","productenquiry"); func_display("customer/home.tpl", $smarty); ?>

When I comment out the first line (auth.php) the correct url appears in the browser, but I get inclusion errors etc. When I include the line I am simply redirected to a search page.

Any help would be greatly appreciated.

Cheers.
__________________
http://www.ergofurniture.com.au
X-Cart Version 4.3.1
Reply With Quote
  #2  
Old 01-19-2011, 03:19 PM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,201
 

Default Re: Using POST as the form submission method

Do not include products.php. This script does search for products and returns the result and shows search page
__________________
Steve Stoyanov
CFLSystems.com
Web Development
Reply With Quote
  #3  
Old 01-19-2011, 03:46 PM
  gb2world's Avatar 
gb2world gb2world is offline
 

X-Wizard
  
Join Date: May 2006
Location: Austin, TX
Posts: 1,970
 

Default Re: Using POST as the form submission method

In case you find it easier - there is a free Product Enquiry mod at Xcartmods: http://www.xcartmods.co.uk/x-cart-direct-product-enquiry-form.html

---
__________________
X-CART (4.1.9,12/4.2.2-3/4.3.1-2/4.4.1-5)-Gold
(CDSEO, Altered-Cart On Sale, BCSE Preorder Backorder, QuickOrder, X-Payments, BCSE DPM Module)
Reply With Quote
  #4  
Old 01-21-2011, 01:29 AM
 
almenzies almenzies is offline
 

Advanced Member
  
Join Date: Nov 2005
Posts: 66
 

Default Re: Using POST as the form submission method

Doh!

Awesome, cheers Steve.
__________________
http://www.ergofurniture.com.au
X-Cart Version 4.3.1
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 04:41 AM.

   

 
X-Cart forums © 2001-2020