Problem adding link with unicode text Problem adding link with unicode text
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Problem adding link with unicode text

Started by linuxhata, October 29, 2005, 12:26:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

linuxhata

I've used search, and found no similar problem

I've added this code to theme.php (waterdrop), after the "albums" link

<!-- BEGIN forum_list -->
                        <a href="http://www.damireke.com/forum/" title="ფორუმი">ფორუმი</a>
                        <img src="themes/water_drop/images/orange_carret.gif" width="8" height="8" border="0" alt="" />
<!-- END forum_list -->

for some strange reasons, I'm getting error "unexpected $ in theme.php at line 1395"

What I'm doing wrong?

artistsinhawaii


I can't see anything wrong with the link you added.  I even ran it on my own setup. The problem lies elsewhere.  Did you check to see if you had an extra $ <--character in 1395? Or a space between the $ and the parameter that doesn't belong?

Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

linuxhata

Problem only arises when I try to save edited theme.php in UTF-8. If I save it in plain format, there is no problems, but my text is converted to garbage in such case (it requires UTF-8 to be displayed). If I save to UTF-8, then again, we have this problem.

artistsinhawaii

Possibly, the only way around this is to mimic the ALB_LIST_LNK menu pattern and place two declared parameters, appropriate to your link,  in your language file and have theme.inc.php call these from the language file.  Save the language file in utf-8, and the theme.inc.php file as text.
Dennis
Learn and live ... In January of 2011, after a botched stent attempt, the doctors told me I needed a multiple bypass surgery or I could die.  I told them I needed new doctors.

Joachim Müller

don't save coppermine core files (except the language files) in utf-8, as most editors deliberately add a byte order mark (aka "BOM") at the very start of the page but don't display it. Don't add unicode special chars into the core code files. Instead: use html entities as a workaround, or define strings in your language file that hold your language stuff.

linuxhata

Hm, I've solved that problem in this way:

Instead editing theme.php in frontpage, I've opened it from notepad, made changes, and then saved as utf-8. Everything works ok now, thanks all for hints.

Joachim Müller

never, ever use a WYSIWYG editor like MS frontpage to edit coppermine files.

linuxhata

Personally, I'd prefer not to edit anything at all, but we have no choice..... :)

Joachim Müller

yeah, but when you feel the urge to edit anything, use an editor instead of an app that is meant to be used only by complete newbies to play with html pages they created in the first place. Frontpage can not be used with any pre-mad script, it is just plain wrong to use it at all. This is not meant to be a flame against the app or the company that created it, but you should use the tools for what they have been built to be used. Frontpage has been bult to doodle an html page on your local PC, you can't use it for anything else.