If i create a link in an article to a page whos address is something like /rfc-articles/article369.aspx, or why not /rfc-articles/article777.aspx.
What I would like to do is to detect if the link contains /rfc-articles/ and in that case fire a javascript. Is there any built-in support for this in umbraco or do I need to hack it together with jquery? :)
I was going to tell you how to do the simple jquery selector for this on the frontend of your site, but then I realised that you are probably asking a different question! You want to know about detecting which link has been set by the editor in Umbraco at the time of creation?? I'm afraid I don't know the answer to that, but thought it would be useful to clarify the question. Are the links created via the node picker, or entered direct into the html view by the editors (or both)?
I do know about selectors in jQuery and thats what I ended up doing, what I would like do to is to have umbraco to add an attribute on links to internal pages which have a special property set or is heading towards a specific node, as in /rfc-articles/ in my example above.
But I'll have to figure this later since I'm on a tight schedule, jquery will do for now and here it is
Detect if href link is to an internal page
Hi
In example
If i create a link in an article to a page whos address is something like /rfc-articles/article369.aspx, or why not /rfc-articles/article777.aspx.
What I would like to do is to detect if the link contains /rfc-articles/ and in that case fire a javascript. Is there any built-in support for this in umbraco or do I need to hack it together with jquery? :)
I'm running Umbraco 4.7.
Thanks
Hi Eric,
I was going to tell you how to do the simple jquery selector for this on the frontend of your site, but then I realised that you are probably asking a different question! You want to know about detecting which link has been set by the editor in Umbraco at the time of creation?? I'm afraid I don't know the answer to that, but thought it would be useful to clarify the question. Are the links created via the node picker, or entered direct into the html view by the editors (or both)?
Sorry for the diffuse question.
I do know about selectors in jQuery and thats what I ended up doing, what I would like do to is to have umbraco to add an attribute on links to internal pages which have a special property set or is heading towards a specific node, as in /rfc-articles/ in my example above.
But I'll have to figure this later since I'm on a tight schedule, jquery will do for now and here it is
is working on a reply...