pcwaredirect Posted January 2, 2005 Posted January 2, 2005 i made a bunch of new catagories but as of right now I have no sub catagories or products in them. When i click on a catagory, it gives me an error "unable to determine the page link" Can someone please tell me how to fix this? thank you so much in advance Jeremy
ozcsys Posted January 2, 2005 Posted January 2, 2005 i made a bunch of new catagories but as of right now I have no sub catagories or products in them. When i click on a catagory, it gives me an error "unable to determine the page link" Can someone please tell me how to fix this? thank you so much in advance Jeremy <{POST_SNAPBACK}> Are your categories the only links that you are having problems with? A url would be a help The Knowledge Base is a wonderful thing. Do you have a problem? Have you checked out Common Problems? There are many very useful osC Contributions Are you having trouble with a installed contribution? Have you checked out the support thread found Here BACKUP BACKUP BACKUP!!! You did backup, right??
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 Are your categories the only links that you are having problems with? A url would be a help <{POST_SNAPBACK}> www.pcwaredirect.com/catalog ignore the navigation menu on the left side the one im having the problem with is on the right side thanks
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 www.pcwaredirect.com/catalog ignore the navigation menu on the left side the one im having the problem with is on the right side thanks <{POST_SNAPBACK}> also i looked in the admin/application_top.php and im not sure if this is where i check to see if my register_global is set to on or off but here is the code // Check if register_globals is enabled. // Since this is a temporary measure this message is hardcoded. The requirement will be removed before 2.2 is finalized. if (function_exists('ini_get')) { ini_get('register_globals') or exit('FATAL ERROR: register_globals is disabled in php.ini, please enable it!');
Guest Posted January 2, 2005 Posted January 2, 2005 You have an URL somewhere that does not contain a valid page as the first paramater to the call to tep_href_link(). Bobby
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 You have an URL somewhere that does not contain a valid page as the first paramater to the call to tep_href_link(). Bobby <{POST_SNAPBACK}> how can i find this? I would think it should work as is because the catagories were just added and all of the sudden they are not working do you know where i could look? or can i post some code for you?
Guest Posted January 2, 2005 Posted January 2, 2005 No need to post code. Take a look at the page when you get the error. It stops outputing after this: <!-- body_text //--> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td class="pageHeading">Welcome to PC-Ware Direct</td> <td align="right"><img src="images/" border="0" alt="Welcome to PC-Ware Direct" title=" Welcome to PC-Ware Direct " width="57" height="40"></td> </tr> </table></td> </tr> <tr> <td><img src="images/pixel_trans.gif" border="0" alt="" width="100%" height="10"></td> </tr> <tr> The next thing that comes directly after that is the product_listing.php file. I would assume the error is related to the query being constructed or due to a contribution that you installed (some that modified product_listing.php??). Bobby
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 No need to post code.? Take a look at the page when you get the error.? It stops outputing after this: <!-- body_text //--> ? ?<td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> ? ? ?<tr> ? ? ? ?<td><table border="0" width="100%" cellspacing="0" cellpadding="0"> ? ? ? ? ?<tr> ? ? ? ? ? ?<td class="pageHeading">Welcome to PC-Ware Direct</td> ? ? ? ? ? ?<td align="right"><img src="images/" border="0" alt="Welcome to PC-Ware Direct" title=" Welcome to PC-Ware Direct " width="57" height="40"></td> ? ? ? ? ?</tr> ? ? ? ?</table></td> ? ? ?</tr> ? ? ?<tr> ? ? ? ?<td><img src="images/pixel_trans.gif" border="0" alt="" width="100%" height="10"></td> ? ? ?</tr> ? ? ?<tr> The next thing that comes directly after that is the product_listing.php file.? I would assume the error is related to the query being constructed or due to a contribution that you installed (some that modified product_listing.php??). Bobby <{POST_SNAPBACK}> are you sure it would have nothing to do with my global? I looked on google and put the error message in and it was talking about the global setting in my php.ini file. I have no idea what would have modified my product listing. It was just working the other day and i dont recall what would have changed it. I am looking through my php files and i dont even see product listing.php could this be the problem?? :) I have the following files product info.php product reviews.php product reviews info.php product reviews write.php products new.php
Guest Posted January 2, 2005 Posted January 2, 2005 It is located here: includes/modules/product_listing.php The error being generated is located in includes/functions/html_output.php => tep_href_link() and is due to a null page parameter. Find the reason for a null page parameter and you're all set. Bobby
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 It is located here: includes/modules/product_listing.php The error being generated is located in includes/functions/html_output.php => tep_href_link() and is due to a null page parameter. Find the reason for a null page parameter and you're all set. Bobby <{POST_SNAPBACK}> i dont know php so i dont know if there is supposed to be a ' or a ; ect... wish me luck
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 i dont know php so i dont know if there is supposed to be a ' or a ; ect... wish me luck <{POST_SNAPBACK}> here is my code if your bored and want to help the uneducated newbie :) $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id'); if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> <?php } $list_box_contents = array(); for ($col=0, $n=sizeof($column_list); $col<$n; $col++) { switch ($column_list[$col]) { case 'PRODUCT_LIST_MODEL': $lc_text = TABLE_HEADING_MODEL; $lc_align = ''; break; case 'PRODUCT_LIST_NAME': $lc_text = TABLE_HEADING_PRODUCTS; $lc_align = ''; break; case 'PRODUCT_LIST_MANUFACTURER': $lc_text = TABLE_HEADING_MANUFACTURER; $lc_align = ''; break; case 'PRODUCT_LIST_PRICE': $lc_text = TABLE_HEADING_PRICE; $lc_align = 'right'; break; case 'PRODUCT_LIST_QUANTITY': $lc_text = TABLE_HEADING_QUANTITY; $lc_align = 'right'; break; case 'PRODUCT_LIST_WEIGHT': $lc_text = TABLE_HEADING_WEIGHT; $lc_align = 'right'; break; case 'PRODUCT_LIST_IMAGE': $lc_text = TABLE_HEADING_IMAGE; $lc_align = 'center'; break; case 'PRODUCT_LIST_BUY_NOW': $lc_text = TABLE_HEADING_BUY_NOW; $lc_align = 'center'; break; } if ( ($column_list[$col] != 'PRODUCT_LIST_BUY_NOW') && ($column_list[$col] != 'PRODUCT_LIST_IMAGE') ) { $lc_text = tep_create_sort_heading($HTTP_GET_VARS['sort'], $col+1, $lc_text); } $list_box_contents[0][] = array('align' => $lc_align, 'params' => 'class="productListing-heading"', 'text' => ' ' . $lc_text . ' '); } if ($listing_split->number_of_rows > 0) { $rows = 0; $listing_query = tep_db_query($listing_split->sql_query); while ($listing = tep_db_fetch_array($listing_query)) { $rows++; if (($rows/2) == floor($rows/2)) { $list_box_contents[] = array('params' => 'class="productListing-even"'); } else { $list_box_contents[] = array('params' => 'class="productListing-odd"'); } $cur_row = sizeof($list_box_contents) - 1; for ($col=0, $n=sizeof($column_list); $col<$n; $col++) { $lc_align = ''; switch ($column_list[$col]) { case 'PRODUCT_LIST_MODEL': $lc_align = ''; $lc_text = ' ' . $listing['products_model'] . ' '; break; case 'PRODUCT_LIST_NAME': $lc_align = ''; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a>'; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a> '; } break; case 'PRODUCT_LIST_MANUFACTURER': $lc_align = ''; $lc_text = ' <a href="' . tep_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $listing['manufacturers_id']) . '">' . $listing['manufacturers_name'] . '</a> '; break; case 'PRODUCT_LIST_PRICE': $lc_align = 'right'; if (tep_not_null($listing['specials_new_products_price'])) { $lc_text = ' <s>' . $currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . '</s> <span class="productSpecialPrice">' . $currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . '</span> '; } else { $lc_text = ' ' . $currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . ' '; } break; case 'PRODUCT_LIST_QUANTITY': $lc_align = 'right'; $lc_text = ' ' . $listing['products_quantity'] . ' '; break; case 'PRODUCT_LIST_WEIGHT': $lc_align = 'right'; $lc_text = ' ' . $listing['products_weight'] . ' '; break; case 'PRODUCT_LIST_IMAGE': $lc_align = 'center'; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>'; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a> '; } break; case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; } $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-data"', 'text' => $lc_text); } } new productListingBox($list_box_contents); } else { $list_box_contents = array(); $list_box_contents[0] = array('params' => 'class="productListing-odd"'); $list_box_contents[0][] = array('params' => 'class="productListing-data"', 'text' => TEXT_NO_PRODUCTS); new productListingBox($list_box_contents); } if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> <?php } ?>
Guest Posted January 2, 2005 Posted January 2, 2005 Try changing this: case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; } to this: case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(FILENAME_DEFAULT, tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; IF that doesn't work I wish you luck... Bobby
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 Try changing this: case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; } to this: ? ? ? ? ?case 'PRODUCT_LIST_BUY_NOW': ? ? ? ? ? ?$lc_align = 'center'; ? ? ? ? ? ?$lc_text = '<a href="' . tep_href_link(FILENAME_DEFAULT, tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; ? ? ? ? ? ?break; IF that doesn't work I wish you luck... Bobby <{POST_SNAPBACK}> it didnt work :(
Guest Posted January 2, 2005 Posted January 2, 2005 I'm in a generous mood so will help you pinpoint the problem. In includes/functions/html_output.php find this code: if (!tep_not_null($page)) { die('</td></tr></table></td></tr></table><br><br><font color="#ff0000"><b>Error!</b></font><br><br><b>Unable to determine the page link!<br><br>'); } ...and change it to this: if (!tep_not_null($page)) { return 'imyourbustedlink_nowfindme_andcorrectme'; } That will keep the script from exiting with the terminal error and will process the whole page. Now, just find the link with the text above and start pinpointing the problem. Bobby
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 FYI: for other users with this problem: Chemod figured out the problem for me. the busted link was in my notify box. He noticed i had search engine safe URL's enabled in my admin/configuration/mystore in the admin console. I turned this off and all of my links were working again thanks bobby for all of your help! Sincerely, Jeremy Gagliardi, President, PC-Ware Direct
pcwaredirect Posted January 2, 2005 Author Posted January 2, 2005 FYI: for other users with this problem: Chemod figured out the problem for me. the busted link was in my notify box. He noticed i had search engine safe URL's enabled in my admin/configuration/mystore in the admin console. I turned this off and all of my links were working again thanks bobby for all of your help! Sincerely, Jeremy Gagliardi, President, PC-Ware Direct <{POST_SNAPBACK}> Im sorry, I made a typo... bobbies user name is CHEMO
Guest Posted January 3, 2005 Posted January 3, 2005 Thank you for the follow up post. If you need help in the future there are lots of members here that can help! Bobby
Recommended Posts
Archived
This topic is now archived and is closed to further replies.