Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

arrrgghhh! where did THESE come from??


niknakgroup

Recommended Posts

Help, I am tearing my hair out!! I have been working on my site today, and all of a sudden I have the letters

n n n n nn
appearing at the top of every page. I have looked at every file I can think of that might have caused them, and have no idea where they have come from or how to get rid of them! Anybody have any ideas???

 

Also, I have the header tags controller mod installed and working, but I want my products to show their title as the page title. I have updated the sql, but it just has my default title up there. If I disable the htc part of product_info.php the title shows correctly, but bizarrely the items picture dissapears ?????

 

Are these both proof that I have a gremlin in the site with a weird sense of humour, or am I just being dumb???

 

Thanks in advance!

Please note - if I have suggested a contrib above, it doesnt mean it will work! Most of the contribs are not ones I've used, but may be useful for your particular problem....

Have you tried a refined search? Chances are your problem has already been dealt with elsewhere on the forums.....

if (stumped == true) {

return(square_one($start_over)

} else {

$random_query = tep_fetch_answer($forum_query)

}

Link to comment
Share on other sites

Only way I can think of, is to make a content search of "n n n n nn" inside your files.

 

Maybe you will need to download (ftp) the files, and use a local search.

 

SGershon

If at first you don't succeed, you must be a programmer.

 

Tip Posted: Languageless Reviews

Link to comment
Share on other sites

ISSUE:

Display shows the 'n' character in index page when categories are selected.

 

You have edited the index.php using the online file manager which has removed the \ backslashes from the code, this is a known issue with using the file manager to edit files, it is better to use an ftp program such as ws_ftp to download the file and edit it locally then ftp back to the server.

 

FIX:

To fix this issue you will need to find the 4 instances of "n"; on your index.php and change them to "\n";

 

around line #104 look for this code

while ($categories = tep_db_fetch_array($categories_query)) { 
     $rows++; 
     $cPath_new = tep_get_path($categories['categories_id']); 
     $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%'; 
     echo '                <td align="center" class="smallText" width="' . $width . '" valign="top"><a href="' . tep_href_link(FILENAME_DEFAULT, $cPath_new) . '">' . tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '<br>' . $categories['categories_name'] . '</a></td>' . "n"; 
     if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != $number_of_categories)) { 
       echo '              </tr>' . "n"; 
       echo '              <tr>' . "n"; 
     } 
   }

change to this

while ($categories = tep_db_fetch_array($categories_query)) { 
     $rows++; 
     $cPath_new = tep_get_path($categories['categories_id']); 
     $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%'; 
     echo '                <td align="center" class="smallText" width="' . $width . '" valign="top"><a href="' . tep_href_link(FILENAME_DEFAULT, $cPath_new) . '">' . tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '<br>' . $categories['categories_name'] . '</a></td>' . "\n"; 
     if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != $number_of_categories)) { 
       echo '              </tr>' . "\n"; 
       echo '              <tr>' . "\n"; 
     } 
   }

and then around line #256 look for this code

while ($filterlist = tep_db_fetch_array($filterlist_query)) { 
         $options[] = array('id' => $filterlist['id'], 'text' => $filterlist['name']); 
       } 
       echo tep_draw_pull_down_menu('filter_id', $options, (isset($HTTP_GET_VARS['filter_id']) ? $HTTP_GET_VARS['filter_id'] : ''), 'onchange="this.form.submit()"'); 
       echo '</form></td>' . "n"; 
     } 
   }

and change to this

while ($filterlist = tep_db_fetch_array($filterlist_query)) { 
         $options[] = array('id' => $filterlist['id'], 'text' => $filterlist['name']); 
       } 
       echo tep_draw_pull_down_menu('filter_id', $options, (isset($HTTP_GET_VARS['filter_id']) ? $HTTP_GET_VARS['filter_id'] : ''), 'onchange="this.form.submit()"'); 
       echo '</form></td>' . "\n"; 
     } 
   }

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Wow! Thank you all for quick replies - my PC was being ghosted so was using the laptop which has no ftp (hence the use of file manager in admin) and didn't know it removed the backslashes! As soon as I got back on normal PC all became clear - the backslashes had been removed in my header_tags.php file, hence all the "n"'s - btw a search for n nn didn't work as they were all singles....I think the use of the file manager also caused the lack of image on my product_info page, as edited using ftp and all is now fine....

 

Minor glitches and sudden panic help to keep me on my feet! Worth noting for others who (like me) didn't know about the file manager.

 

Thanks again, now to find another way to break my site....... :D

Please note - if I have suggested a contrib above, it doesnt mean it will work! Most of the contribs are not ones I've used, but may be useful for your particular problem....

Have you tried a refined search? Chances are your problem has already been dealt with elsewhere on the forums.....

if (stumped == true) {

return(square_one($start_over)

} else {

$random_query = tep_fetch_answer($forum_query)

}

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...