Beginner question regarding Array's
Posted on
16th Feb 2014 07:03 pm by
admin
Hi everyone, the page im working on has an array of variable at the top...
Code: $define_list = array('PRODUCT_LIST_MODEL' => PRODUCT_LIST_MODEL,
'PRODUCT_LIST_NAME' => PRODUCT_LIST_NAME,
'PRODUCT_LIST_MANUFACTURER' => PRODUCT_LIST_MANUFACTURER,
'PRODUCT_LIST_PRICE' => PRODUCT_LIST_PRICE,
'PRODUCT_LIST_QUANTITY' => PRODUCT_LIST_QUANTITY,
'PRODUCT_LIST_WEIGHT' => PRODUCT_LIST_WEIGHT,
'PRODUCT_LIST_IMAGE' => PRODUCT_LIST_IMAGE,
'PRODUCT_LIST_BUY_NOW' => PRODUCT_LIST_BUY_NOW);
I have written a statement to say if product_list_price is 0 dont display a buy now button..
Code: case 'PRODUCT_LIST_BUY_NOW':
$lc_align = 'center';
if ($define_list['PRODUCT_LIST_PRICE']== '0'){ //fix for call for price
$lc_text = ' ';
} else {
$lc_text = osc_link_object(osc_href_link(basename($_SERVER['SCRIPT_FILENAME']), $osC_Product->getKeyword() . '&' . osc_get_all_get_params(array('action')) . '&action=cart_add'), osc_draw_image_button('button_buy_now.gif', $osC_Language->get('button_buy_now'))) . ' ';
} break;
}
However its not working, Im unsure if its because my IF statement is correct or not, Ive read a few tutorials on google regarding it and im sure all the above code is correct, Can anybody tell me if theres something wrong or if it may be another matter?
No comments posted yet
Your Answer:
Login to answer
279
45
Other forums
problems with php variables in mysql query
i can't seem to get the following query to work.
select $q1c from $vote_rate where id = $re
New to Arrays
Hi I am new to PHP (a week and a half now) and I am just beginning to read about arrays. I understan
Calculating a rating by adding number of points and dividing by number of items
I have a site that users can post links to files to download. They can rate these files on a 1-5 sca
Storing the referrer in session... problems with tabs
Hello All
I am currently working on an ERP project based on the MVC methodology, when a user
update the selected existing records of database
Hi frndz,
I am new to php and get stuck....
Edit.php > Update.php > Updatea
Need Help with a query
Hello,
For some reason I am just not getting the right answer when I do this query and not quite
Help =( !! Upload Pics [PHP script]
Hello
I need help with a php script [MULTIPLE UPLOAD IMAGES] , where I want to add a feature (wat
parse error
Parse error: syntax error, unexpected '[', expecting ')' in /Users/admin/Sites/phptest/array.php on
insert mysql embeded videos as blobs?
Using TinyMCE my client will be able to embed images and flash videos into large columns of text whi
PHP SUBMIT
Code: <input name="doLogin" type="image" src="images/loginsubmit.jpg