Jump to content

Send Configurable Options from custom page


FALKOR

Recommended Posts

  • 2 months later...

Problem still is actual. Any one can help me? 

I want to create configurator in custom page or index.php (`header.tpl`) and forward customization to product use `POST` or `GET` method.

I thinked that I can do it if add config to link, but WHMCS redirect me (when disabled requiered domain) from http://whmcs.loc/cart.php?a=add&pid=* to http://whmcs.loc/cart.php?a=confproduct&i=*

Also I want to get product list in index.php. Can I do it, or no?

Link to comment
Share on other sites

47 minutes ago, FALKOR said:

Problem still is actual. Any one can help me? 

have you read the linking to WHMCS docs page about config options..

https://docs.whmcs.com/Linking_to_WHMCS#Configurable_Options

Quote

There are many further options you can use, such as your own configurable options. The simplest way of formulating a url is to step through the order process as normal to the product configuration step, then right click > view source and get the field names and value IDS. These can then be used in your direct link URLs.

For example:


<p class="cartsubheading">Configurable Options</p>
<p>This product/service has some options which you can choose from below to customise your
order.</p>

<div class="cartbox">
<table cellspacing="0" cellpadding="0">
<tr><td>Disk Space:</td><td width="5"></td><td>
<input type="text" name="configoption[1]" value="100" size="5"> x 1MB $0.00USD
</td></tr>
</table>
</div>

You would then use the URL:


http://demo.whmcs.com/cart.php?a=add&pid=1&configoption[1]=100

This would set the value of the first configurable option to 100.

that might help you to pass the correct URL variables to the cart...

51 minutes ago, FALKOR said:

Also I want to get product list in index.php. Can I do it, or no?

only be querying the database - via hook, data feed, API etc - there's no inbuilt option to add products to the homepage.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated