By tryitonce on
I need to transfer text with anchor links form node body to a CCK field.
When I did this the anchors are there - but the links are not working.
The url of the node is:
http://www.example.com/en/articles/communication
the anchor link in the node body is
http://www.example.com/en/articles/communication#media
the anchor name is <a name="media">
the anchor link is <a href="#media">Media</a>
the new CCK field is named:
field_article_prem_content
I guess I need to integrate the field name with the anchors name and / or link?
But how - all help welcome - just a bit more detailed for a trying enthusiast - thanks.
Comments
-
I read somewhere on the forum that anchors are not "handled by the server" (apologies for the ambiguity, I am recalling the post from memory). In this case, an individual wanted to use pathauto to change the path of a URL that had an anchor in it. In the end he was unable to do so. Sorry I do not have more information. Perhaps others will.
_
Thanks, but anchors are working in the body of the node.
So, adding a CCK field to the node should require to add the CCK field address to the anchor?!?
This should be possible and the person with the right know-how might just give us the hint in no time - let's hope for some enlightenment.
.
I just realized what you are talking about; in this case, you should look at the contemplate module. It will allow you to customize the template for a particular node type, and because you can manipulate the html in the contemplate viewing pane, you can add an anchor to the precise CCK field you want.
_
Thanks, great hint and I certainly will look at it in more detail - http://drupal.org/project/contemplate
My initial test shows it is not doing what I need.
My problem are anchors inside the "premium" CCK field that holds the bulk and body of the article and will only be visible to the members.
I am not looking for anchors of CCK fields. There is only one CCK field and the anchors are inside this field:
Teaser
Premium CCK field
What I need is to get the Anchor Links for the items from the teaser to the CCK field
Introduction - Marketing - Radio - TV - Newspaper - Media Anchor and / or to get these anchor links to work in the CCK field.
Well, we will get to the bottom of this eventually .... I hope ....
_
After testing the Premium module - I think it will be the answer for the task in hand.
However, anchor linking across CCK fields would still be a good think in other situations.
http://drupal.org/project/premium