News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

?

Started by NyYaNkEeFaN95, February 06, 2011, 09:12:28 AM

Previous topic - Next topic

ARG01

I have no hov.gif image in my files. I didn't know that there was suppose to be one?  ;)
No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

busterone

Here is the code from that theme's index.template.php for the linktree. There is no call for an image.

// Show a linktree. This is that thing that shows "My Community | General Category | General Discussion"..
function theme_linktree($force_show = false)
{
global $context, $settings, $options, $shown_linktree;

// If linktree is empty, just return - also allow an override.
if (empty($context['linktree']) || (!empty($context['dont_default_linktree']) && !$force_show))
return;

echo '
<div class="navigate_section">
<ul>';

// Each tree item has a URL and name. Some may have extra_before and extra_after.
foreach ($context['linktree'] as $link_num => $tree)
{
echo '
<li', ($link_num == count($context['linktree']) - 1) ? ' class="last"' : '', '>';

// Show something before the link?
if (isset($tree['extra_before']))
echo $tree['extra_before'];

// Show the link, including a URL if it should have one.
echo $settings['linktree_link'] && isset($tree['url']) ? '
<a href="' . $tree['url'] . '"><span>' . $tree['name'] . '</span></a>' : '<span>' . $tree['name'] . '</span>';

// Show something after the link...?
if (isset($tree['extra_after']))
echo $tree['extra_after'];

// Don't show a separator for the last one.
if ($link_num != count($context['linktree']) - 1)
echo ' »';

echo '
</li>';
}
echo '
</ul>
</div>';

$shown_linktree = true;
}

Siirist

Quote from: G1 on February 06, 2011, 10:44:15 AM
I have no hov.gif image in my files. I didn't know that there was suppose to be one?  ;)

Here ya go
Needed information:
- What's your SMF version?, What MODs are installed? What Theme(s) are you using? Have you backed up your database?

--> At least 50% of the questions asked are answered in the Online Manual <--
Mods for ver 1.x will NOT run on ver 2.x

NyYaNkEeFaN95

hmm i dont know what is happening then

ARG01

I see why i don't have it. I have the original download of epic but there is an updated version of epic204 that does contain the hov.gif image.  ;)
No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

NyYaNkEeFaN95

i have it on my server but it wasnt in my theme download wierd.

ARG01

I am not positive that the hov.gif has anything to do with the linktree though as the two small arrows that I have teem to be a text that hovers with the linktree titles.
No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

NyYaNkEeFaN95

I dont think it does at all.

NyYaNkEeFaN95

Ok my forum tech fixed it he might post the resolution soon

Jdrowlands

Whoever made the theme botched it up ;)

Special characters (which in this case seperate the links in the tree) cannot be used in xhtml, you need to use an entity instead, like this: &raquo;

In other words, replace (in index.template.php) this:

echo ' »';

with this:

echo ' &raquo;';

Hope this helps anyone else who has this problem =)

Siirist

Thank you for posting.
If this is solved, can you go to the bottom left of topic and "Mark as solved"?
Needed information:
- What's your SMF version?, What MODs are installed? What Theme(s) are you using? Have you backed up your database?

--> At least 50% of the questions asked are answered in the Online Manual <--
Mods for ver 1.x will NOT run on ver 2.x

ARG01

Quote from: Jdrowlands on February 06, 2011, 12:19:24 PM
Whoever made the theme botched it up ;)

Special characters (which in this case seperate the links in the tree) cannot be used in xhtml, you need to use an entity instead, like this: &raquo;

In other words, replace (in index.template.php) this:

echo ' »';

with this:

echo ' &raquo;';

Hope this helps anyone else who has this problem =)

I get what you are stating but can you explain why the original files work on some sites and not on others? It cant be a browser issue because the unaltered theme files work fine on my test site regardless of which browser I use. Can it be a database or hosting issue?  ;)

No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

Jdrowlands

Quote from: G1 on February 06, 2011, 01:00:37 PM
Quote from: Jdrowlands on February 06, 2011, 12:19:24 PM
Whoever made the theme botched it up ;)

Special characters (which in this case seperate the links in the tree) cannot be used in xhtml, you need to use an entity instead, like this: &raquo;

In other words, replace (in index.template.php) this:

echo ' »';

with this:

echo ' &raquo;';

Hope this helps anyone else who has this problem =)

I get what you are stating but can you explain why the original files work on some sites and not on others? It cant be a browser issue because the unaltered theme files work fine on my test site regardless of which browser I use. Can it be a database or hosting issue?  ;)

Probably not. It's down to how the browser handles the incorrect special characters. There a lot of things could factor, such as operating system and language as well.

But that's beside the point, xhtml should never have any special characters in it at all.

ARG01

Understandable.  ;)
No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

MrPhil

The whole problem is that the moron that wrote the theme used a hard-coded non-ASCII character as the separator. You never put hard-coded (binary) characters above value 0x7F into code files. You always use HTML entities (like &rdaquo;, or its numeric equivalent, &# 187;). (Note that non-ASCII binary characters are OK in language support files, as it is explicit what character encoding is to be used)

Anyway, you need to search the source files for something containing the name "linktree" (most likely place) and look in the function that generates that linktree. Some place you'll see some hard-coded character like » (or maybe some other character, depending on the code page the file was edited in and what code page you're viewing it in), being used as the separator. Change it to an HTML entity and it will always display correctly.

ARG01

#35
Quote from: MrPhil on February 06, 2011, 01:19:58 PM
The whole problem is that the moron that wrote the theme used a hard-coded non-ASCII character as the separator.

Is the moron thing really necessary? What is truly expected to be gained by such a comment?  >:(


No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

MrPhil

It is absolutely inexcusable for a coder to write "code" files, that might be used under any of a number of different character encodings, with hardcoded (binary) characters outside of the ASCII set. These non-ASCII characters are very likely to display incorrectly if a character encoding is used that is different than what the file was edited with. UTF-8 is guaranteed to fail with the infamous "?", while other encodings may simply give one or more unexpected character(s). Any code repository (including SMF) should check for non-ASCII characters in a mod or theme (outside of language files) and summarily reject it if any are found. Language support files, which are intended to be used under a specified character encoding, may of course contain non-ASCII characters.

I stand by what I said and make no apologies. This very error has come up again and again, and the solution has been given again and again, and no one seems to ever learn from it. I'm getting tired of it.

ARG01

Quote from: MrPhil on February 07, 2011, 10:58:56 PM
I stand by what I said and make no apologies. This very error has come up again and again, and the solution has been given again and again, and no one seems to ever learn from it. I'm getting tired of it.

Ok, so your an expert at coding. We all get it, no need to keep bragging about it. But the childish name calling is just plain rude, and rudeness is one of the very reasons that some are beginning to go elsewhere for support. Nobody here claims to be perfect and believe it or not, some people may even make an occasional mistake or two. If you cannot not offer support without being rude the don't bother to offer at all. If your getting tired of it, stay away from topics like this and move on. ???
No, I will not offer free downloads to Premium DzinerStuido themes. Please stop asking.

Road Rash Jr.

Quote from: G1 on February 07, 2011, 11:58:27 PM
But the childish name calling is just plain rude, and rudeness is one of the very reasons that some are beginning to go elsewhere for support. Nobody here claims to be perfect and believe it or not, some people may even make an occasional mistake or two. If you cannot not offer support without being rude the don't bother to offer at all. If your getting tired of it, stay away from topics like this and move on. ???

Well said G1, seems to be a lot of that going around :o
Never argue with an Idiot like myself, they just drag you down to their level then beat you with experience.

Advertisement: