Zen Cart Logo
Forums / Installing on a Linux/Unix Server / Funny code at top of webpage

Funny code at top of webpage

Locked

Views: 2,539

Results 1 to 13 of 13
This thread is locked. New replies are disabled.
2 Apr 2008, 8:37 PM
#1
paws4pets avatar

paws4pets

New Zenner

Join Date:
Aug 2007
Posts:
12
Plugin Contributions:
0

Funny code at top of webpage

Hi,

Seem to got this text at the top of my webpage, can anybody help?

{\rtf1\ansi\ansicpg1252\deff0\deflang2057{\fonttbl{\f0\froman\fcharset0 Times New Roman;}{\f1\fswiss\fcharset0 Arial;}} {*\generator Msftedit 5.41.21.2507;}\viewkind4\uc1\pard\sb100\sa100\f0\fs24 \par \pard\f1\fs20\par }

Thanks

2 Apr 2008, 8:54 PM
#2
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: Funny code at top of webpage

It means that you have one or more corrupt files. But it's not possible to be specific about which one(s). I'd recommend switching to the default template to see if this goes away. If it does the problem is with one of your template files, otherwise it's one of the core Zen Cart files.

2 Apr 2008, 10:11 PM
#3
fairestcape avatar

fairestcape

Totally Zenned

Join Date:
Mar 2008
Location:
Cape Town & London (depends on the season)
Posts:
2,957
Plugin Contributions:
0

Re: Funny code at top of webpage

If you have edited any of your core files (the PHP files) using a HTML editor, MSWord, notepad - or an editor that formats text, you are likely to corrupt the file.

Now, I have no idea if you have done this, but if you have you should check all the files you edited for errors.

The first thing you must do is download a good text editor - CRIMSON editor is a good one and it's free on the WWW. Google for Crimson Editor.

Next, download and install WINMERGE.

You will use Winmerge to COMPARE your edited copies with the originals. Winmerge will find differences in the two files and highlight them for you - making corrections easier.

You should FTP any changed files back to your hard drive, and do edits there. Then make sure you FTP the edited files to your custom (over-rides) template.

2 Apr 2008, 10:26 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Funny code at top of webpage

Correct. Those are RTF headers caused by editors not designed to edit text-only files.

ref: http://www.zen-cart.com/forum/showthread.php?t=53327

2 Apr 2008, 10:33 PM
#5
araunah avatar

araunah

New Zenner

Join Date:
Dec 2004
Location:
The Internet
Posts:
76
Plugin Contributions:
0

Re: Funny code at top of webpage

I found a nice and free editor for those who are interested in editing php files and do not have any editor: pspad.com. I love it and use it all the time.

2 Apr 2008, 10:39 PM
#6
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Funny code at top of webpage

I use Notepad ++
http://notepad-plus.sf.net

2 Apr 2008, 10:49 PM
#7
fairestcape avatar

fairestcape

Totally Zenned

Join Date:
Mar 2008
Location:
Cape Town & London (depends on the season)
Posts:
2,957
Plugin Contributions:
0

Re: Funny code at top of webpage

Steven300:

I use Notepad ++

... and for newbies, please note that it's NOTEPAD++ not NOTEPAD.

3 Apr 2008, 4:51 AM
#8
rosers avatar

rosers

New Zenner

Join Date:
Apr 2008
Posts:
17
Plugin Contributions:
0

Re: Funny code at top of webpage

i cant get into admin page 404 eror i have deleted cookies changes ssl what do i do i can get into shop but not admin

3 Apr 2008, 6:07 AM
#9
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,772
Plugin Contributions:
9

Re: Funny code at top of webpage

First, it's not a good idea to jump into a post that is not related to your problem. Mostly because it may not be looked at by the folks able to help you.

It would have been better to start a new thread stating "can't access admin" AFTER you searched for that in the forum.

That said, there are two configure files. One is admin/includes/configure.php. If that file is incorrect, you will not be able to access the admin.

3 Apr 2008, 12:04 PM
#10
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Funny code at top of webpage

fairestcape:

... and for newbies, please note that it's NOTEPAD++ not NOTEPAD.

I'm not a newbie, but, for the record, I've never used anything but plain ol' Notepad to edit Zen files, and haven't ever had a problem. Others obviously have, though, so Notepad ++ or Crimson would probably be the way to go.

3 Apr 2008, 12:18 PM
#11
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Funny code at top of webpage

stevesh:

I'm not a newbie, but, for the record, I've never used anything but plain ol' Notepad to edit Zen files, and haven't ever had a problem. Others obviously have, though, so Notepad ++ or Crimson would probably be the way to go.

I use Notepad if it's just a quick change that's required. I find Notepad ++ is useful for more complex changes as it adds colour to the code, and shows the line numbers.

3 Apr 2008, 2:34 PM
#12
vger avatar

vger

Past Contributor

Join Date:
Nov 2004
Location:
Norfolk, United Kingdom
Posts:
3,189
Plugin Contributions:
0

Re: Funny code at top of webpage

Yes, bog standard Notepad will do at a pinch. I find Text Pad better than Crimson Editor, because it has a much better, more user-friendly, "Find In Files" feature.

PS Pad is also very good.

Win Merge is absolutely essential too.

Vger

3 Apr 2008, 4:44 PM
#13
araunah avatar

araunah

New Zenner

Join Date:
Dec 2004
Location:
The Internet
Posts:
76
Plugin Contributions:
0

Re: Funny code at top of webpage

Vger:

PS Pad is also very good.

Yes PS Pad is great, until now it is the one I prefer but I never used notepad++, I am gonna give it a try. Thanks for the tip.