Jump to content

Error: Unable to determine connection method on a link!


Goshawk

Recommended Posts

Hi,

I am a newbie in programming and php.

I am writing my first mod for a shopping cart but when I oen the page I get this error:

 

Error!

Unable to determine connection method on a link!

Known methods: NONSSL SSL

Function used:

zen_href_link('new_sumner_order.php', 'customers_firstname customers_lastname

entry_street_address, entry_city, entry_postcode entry_state', '')

 

This is the referring part of the url:

../new_sumner_order.php?origin=sumner_shop_customers.php&mode=NONSSL&selected_box=tools&customer=Array&cID=473

 

And here is the code used:

$action = (isset($_GET['action']) ? $_GET['action'] : '');
$cID = (isset($_GET['cID']) ? (int)$_GET['cID'] : false);
if ($cID) {
    require_once (DIR_WS_CLASSES . 'new_sumner_order.php');
}
$error = false;
$processed = false;

  if ( ($action == 'get_customer_details') && isset($_POST['cID']) ) {
    $this_customer = get_customer_sql_query(zen_db_input($_POST['customers_id']), 'customer');
    $this_customer_details = $db->Execute($this_customer['query_string']);
    $this_customer_details_to = $this_customer['query_name'];
    if ($_POST['customer_details_to']) {
      $this_customer_details_to = zen_db_prepare_input($_POST['customer_details_to']);
    }
  
    // error message: if no customer selected
    // TODO: change to dropbox in popup window
    if (empty($this_customer_details_to)) {
      $messageStack->add_session(ERROR_NO_CUSTOMER_SELECTED, 'error');
      $_GET['action']='';
      zen_redirect(zen_href_link(FILENAME_NEW_SUMNER_ORDER));
    }
}

<tr><?php echo zen_draw_form('customer', FILENAME_NEW_SUMNER_ORDER,
zen_get_all_get_params(array('action')) . 'action=get_customer_details', 'post');
echo zen_hide_session_id(); ?>
      <td class="formAreaTitle"><?php echo CATEGORY_CUSTOMER; ?></td>
    </tr>
    <tr>
      <td class="formArea"><table border="0" cellspacing="2" cellpadding="2"></td>
</tr>
<tr>
      <td class="main"><?php echo CUSTOMER_DETAILS; ?></td>
      <td class="main">
  	<?php zen_draw_hidden_field($_GET['cID']);
	  echo zen_href_link(FILENAME_NEW_SUMNER_ORDER, 'customers_firstname' . ' ' . 'customers_lastname' . '<br />' . 'entry_street_address' . ', ' . 'entry_city' . ', ' . 'entry_postcode' . ' ' . 'entry_state', $this_customer, 'NONSSL'); ?>
  </td>

 

What have I done wrong?

 

Many thanks,

 

Goshawk

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.