Archives FluxBB.fr

Les archives de FluxBB.fr

Vous n'êtes pas identifié(e).

#1 03-07-2009 20:54:23

levy
Membre

Image Hyperlink Underline Problems

I hope you guys don't mind if I post a question in English, if you do, that's totally fine, I just don't know that much French, and I didn't want to use an awful online translator that would ruin the language.

As this mod originates from these forums, I figured you guys would know what's up with my forum.

Hey all, I've been testing my website for any bugs, and stumbled upon one. It's a bit perplexing, but I'm sure it has an easy fix.

I have a modification on my website that allows for the tags "img align=(c,r,l)", in addition to the normal "img". This is useful for quickly floating an image for a news story.

I have "a:link" set to show a line underneath any linked objects (text and images), which turns dotted upon "a:hover".

When I post a topic with an image that is linked using "img align=", i.e.:

[url=http://reviewstash.com/files/vizopropellerdualfancard/packageback.jpg][img]http://reviewstash.com/files/vizopropellerdualfancard/packagebackS.jpg[/img][/url]

The post shows the image as having the specified underline and hover.

However, if I post a topic using the standard "img" linked, there is no underline, and no hover.

I'm not sure why this is, but if you guys have any insight I'd greatly appreciate it - here is my parser.php:

http://snipt.org/knkn

If it helps, removing the section about "img align="'s "$style"/spacing in parser.php results in the bbcode still working (yet not floating the image), and the underline working on that bbcode.

Hors ligne

#2 04-07-2009 01:10:21

Mpok
Néo Admin

Re : Image Hyperlink Underline Problems

Hi,

Posting in english on a french forum should not be a big problem (i mean, less than the contrary... wink)

The fact u have a link (so underline and hover behavior) on your image is because your [c][img][/c] tag is embedded in an [c][url][/c] tag.
That's the [c][url][/c] tag which leads to that behavior.

To check that, u can go to the admin menu, "options" sublink, and uncheck the option which makes url a link (sry, i don't have the precise english name of that option, just read and u'll find it easily).
After unchecking that option, the pbm should be "visually" solved (no link on images).
But it is not really, as the regular [c][url][/c] tags will not work anymore as they should do, after that...

Then, i don't understand WHY u embed your [c][img][/c] in an [c][url][/c] JUST for alignment... (from the code u provided above)

That's not the way things should be used :
- if u want an image floating left, u should type : [c][img]_the_url_[/img][/c]
- if u want an image floating right, u should type : [c][img]_the_url_[/img][/c]
--> NO [c][url][/c] INVOLVED...

Notes :
- i don't know HOW the [c][img][/c] embedded in [c][url][/c] are floating (for u)...
- your parser.php seems ok (i just verified img-related parts), except for a ";bo" string u should suppress (that's in 'handle_img_tag' function).

Hors ligne

#3 04-07-2009 01:37:43

levy
Membre

Re : Image Hyperlink Underline Problems

Thanks for the help.

What if I want the images floated and linked? When I use  the image links without an underline, but when I use [url][img][/url] there is no underline.

Here are my CSS files:

http://snipt.org/knlk
http://snipt.org/knlj

Here is a page with the underline:

http://reviewstash.com/viewtopic.php?pid=3211#p3211

Page without:

http://reviewstash.com/viewtopic.php?pid=499#p499

Both are linked images.

Hors ligne

#4 04-07-2009 03:02:31

Mpok
Néo Admin

Re : Image Hyperlink Underline Problems

levy a écrit :

What if I want the images floated and linked? When I use  the image links without an underline, but when I use [url][img][/url] there is no underline.

Ok levy... so if u WANT images linked (aligned or not), forget my previous comment.
(but ur previous code wasn't than clear, admit it...)

Then, we're going to css.. (btw, good move on proposing ur css files, it shows u understand the pbm... and maybe can resolve it without me wink).

Unfortunately, i'm NOT the one for css-pbms (cos i've totally rewritten css-files for my fluxbb install..).
I would suggest something like :

.pun a img {
    text-decoration: none;
}

But i'm not sure, and i can't say where to put it in your css-files.
But that's the idea : suppress the underline on images embedded in a link...
(maybe in your css, this rule deserves a better 'specification' (than ".pun"))

Hors ligne

#5 04-07-2009 03:26:02

levy
Membre

Re : Image Hyperlink Underline Problems

I tried slapping it in section /* 3. LINKS */ to no avail.

But, I'm not trying to completely remove the underlining, even though it's a glitch, I like it. I'm trying to get [img] is and am unsure of why [img] have seperate CSS.

Hors ligne

#6 06-07-2009 13:22:41

Mpok
Néo Admin

Re : Image Hyperlink Underline Problems

They don't have seperate css...
What 'align' does is JUST adding "inline-style" which is only : float (left or right) property, and some margin properties.

Hors ligne

Pied de page des forums