Recent Topics

1 Mar 30, 2005 16:56    

Hi,
b2evolution 0.9.0.11 dont support (HTML) anchor and cross references? [1] Why?
Can you tell me a hack or fix the problem in a next release?
I will not use the "textile plugin".

The german post: http://forums.b2evolution.net/viewtopic.php?t=3670

[1] http://www.w3.org/TR/html401/struct/links.html#h-12.2.3

2 Aug 18, 2005 02:02

Any news on that? Are there any fixes?

3 Aug 18, 2005 06:35

are you talking about footnotes?

I can put up some nifty code that lets you do footnotes using the quickedit bar thing in the admin area ... the code I use for wordpress could VERY easily be used in b2evo.

By the way, this isnt a BUG and should have been posted elsewhere, it's being moved.

4 Aug 18, 2005 09:26

No I was talkning about support for anchors

5 Aug 18, 2005 17:17

You mean including them in your post? Like "<h1 id="foo">? Not 'name' by the way. The link above points to html401 stuff. name was deprecated in xhtml1.

6 Aug 18, 2005 17:26

oops, my bad -- I guess I could have checked his linked reference :P

7 Aug 18, 2005 17:38

EdB wrote:

You mean including them in your post? Like "<h1 id="foo">? Not 'name' by the way. The link above points to html401 stuff. name was deprecated in xhtml1.

A ok, it was in 2001 I learnt HTML :oops: , thanks for the update. Yes, I wanted to include them in a very long post. I'll try it.

UPDATE: Doesn't work. Error message "h4 may not have attribute id"

8 Aug 18, 2005 18:06

I was asking just to make sure I understood the question. Given that I've never hacked this file and only have the tiniest understanding of how it all works: lets try to hack conf/_formatting.php so that you can post the various h# tags with an 'id' attribute.

Find:

// Allowed Attribute classes
define('A_coreattrs', 'class title');

You could probably be done with the whole thing by changing this to:

// Allowed Attribute classes
define('A_coreattrs', 'class title id');

The problem is, well, I don't know what the problems would be. Why it's not there in the first place makes me think there might be some security risk of some sort.

Anyway I would be more inclined to add a new line to that section:

define('A_extrastuff', 'id');

Then down the page a bit tack A_extrastuff to the tags I wanted to:

// Array showing allowed attributes for tags
$allowed_attribues = array
(
	// 'div' => A_attrs,								// Strict
	'div' => A_attrs.' '.A_TextAlign,		// Transitional

	// 'p' => A_attrs,								// Strict
	'p' => A_attrs.' '.A_TextAlign,		// Transitional

	// 'h1' => A_attrs,								// Strict
	'h1' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional
	// 'h2' => A_attrs,								// Strict
	'h2' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional
	// 'h3' => A_attrs,								// Strict
	'h3' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional
	// 'h4' => A_attrs,								// Strict
	'h4' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional
	// 'h5' => A_attrs,								// Strict
	'h5' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional
	// 'h6' => A_attrs,								// Strict
	'h6' => A_attrs.' '.A_TextAlign.' '.A_extrastuff,		// Transitional

	// 'ul' => A_attrs,	// Strict
	'ul' => A_attrs.' type compact',	// Transitional

When both of these potential hacks don't work don't blame me! Instead search the forums for different stuff about editting the formatting file or allowing different tags in posts and make sure you search for the name 'stk'. Seems to me he knows what's going on in this file and has written it up extensively.

10 Aug 18, 2005 20:30

I was wondering about a viable application for this. Pretty cool actually because your post is *very* long. Good - glad you got it going.


Form is loading...