Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

how to print customers_id in account.php


vikal

Recommended Posts

Posted

hi

good morning

 

since yesterday i am trying to print the cusomers_id from the file account.php

 

i tried

 

tep_session_is_registered('customers_id')

 

$_GET['cID']

$_SESSION['customers_id']

 

and so on

 

but not works

 

as you know that account.php open only after the customers logon but

 

for the product query i need to current session id of customer...

 

it's small but in account.php there is no clue like cID and so

 

can you suggest me to print the customers_id in account.php

 

 

best regards

 

vikal

Posted
i tried

 

$_SESSION['customers_id']

 

did you try $_SESSION['customer_id'] (not customers)

 

<?php
echo 'Hello, your customer ID is ' . $_SESSION['customer_id'];
?>

 

 

Havn't tested it so not 100% sure if it'll work

Posted
did you try $_SESSION['customer_id'] (not customers)

 

<?php
echo 'Hello, your customer ID is ' . $_SESSION['customer_id'];
?>

 

 

Havn't tested it so not 100% sure if it'll work

 

hi

 

thanks for suggestion

 

but it works only for a while but after some moments...

 

if you echo "". $_SESSION['customer_id'];

 

then nothing produce

 

tell me na how to catch that customer_id permanently

 

regards

 

vikal

Posted
hi

 

thanks for suggestion

 

but it works only for a while but after some moments...

 

if you echo "". $_SESSION['customer_id'];

 

then nothing produce

 

tell me na how to catch that customer_id permanently

 

regards

 

vikal

 

hi

 

again asking for help

 

i have following query

 

$customer_query=tep_db_query("SELECT customers_folder_size from customers where customers_id='3'");

$fetch_c=tep_db_fetch_array($customer_query);

$products_query=tep_db_query("SELECT products_image, products_fileupload, products_free_chapter FROM products WHERE customer_id='3'");

 

$product_desc=tep_db_query("SELECT products_name FROM products_description WHERE products_id ='".$fetch['products_id']."' ");

 

yeah it works...if it is 3

 

 

but instead of 3 i need to use $_SESSION['customers_id'] to make my work dynamic....but $_SESSION['customers_id'] does not works

 

 

tell me other variable so that i can work easily....

 

 

 

vikal

Posted
tell me other variable

 

hi

 

i have check for this also tep_session_register('customers_id');

 

but does not work...

 

what to do...

 

guide me

 

regards

 

vikal

Posted

hi

 

good morning

 

i have check for this also tep_session_register('customers_id');

 

as sLaV- told me to do

 

i have tried $_SESSION['customers_id'] also but not working

 

 

 

what to do...

 

guide me please

 

regards

 

vikal

Posted

hi

 

is it that much hard problem no body gives me the hints...

please help me

 

best regards

 

vikal

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...