Can anyone provide guidance on how to modify href attributes in this
way:
Markup: a href=22_foo.html#foo22-name
Modify to: a href=path/to/foo22-name.html
i.e. removing everything up to and including the #, prepending a fixed
path value and appending .html
Thanks
Jonny
// overwrite the existing href of the selected a
$('a').attr('href','path/to/' + hashval + '.html');
On Mar 15, 10:22 am, Jonny Stephens goo...@bloog.co.uk wrote:
Can anyone provide guidance on how to modify href attributes in this
way:
Markup: a href=22_foo.html#foo22-name
Modify
Oops. Wrote too soon.
Works fine for a single anchor. With multiples, all receive the same
href value as the first.
Needs an .each() somewhere?
On Mar 15, 5:44 pm, Jonny Stephens goo...@bloog.co.uk wrote:
Thanks Brad, that's perfect!
Jonny
On Mar 15, 5:29 pm, Brad nrmlcrpt...@gmail.com
This seems to work:
$('a').each(function() {
$(this).attr('href','path/to/' + RegExp([^#]+$).exec($(this).attr
('href')) + '.html');
});
On Mar 15, 7:03 pm, Jonny Stephens goo...@bloog.co.uk wrote:
Oops. Wrote too soon.
Works fine for a single anchor. With multiples, all receive the same
At present I'm triggering Cluetip thus, with Cluetip using the anchor
title attributes for tip titles:
a id=content-1 href=#content-1 rel=#content-1 title=Duis aute
irure dolor in reprehenderit in voluptate velit esse cillum
doloreDuis aute irure dolor in reprehenderit in voluptate velit esse
I want to generate title attributes from existing anchor text, e.g.
a href=foo.htmlFoo Foo/a
becomes
a href=foo.html title=Foo FooFoo Foo/a
The code below works in FF3 with Firebug reporting no errors, but
Safari reports a parsing error. IE is no go.
$('a').attr('title' , function()
());
});
Keep in mind, though, that an anchor might have an image inside,
rather than text. I doubt it'd be an issue. I guess jquery would
simply set it to the empty string.
On Wed, Mar 4, 2009 at 6:11 PM, Jonny Stephens goo...@bloog.co.uk wrote:
I want to generate title attributes from
Cycle's scrollHorz and scrollVert fx options allow back and forth
functionality for the Prev/Next and Pager functions.
The scrollVert transition scrolls Next content downwards and Prev
upwards.
I'd prefer these to be reversed:
Next = scrolls up, Prev = scrolls down.
Thought I'd found an
, Jonny Stephens goo...@bloog.co.uk wrote:
Cycle's scrollHorz and scrollVert fx options allow back and forth
functionality for the Prev/Next and Pager functions.
The scrollVert transition scrolls Next content downwards and Prev
upwards.
I'd prefer these to be reversed:
Next = scrolls up
: 0 };
};
On Feb 22, 3:57 pm, Jonny Stephens goo...@bloog.co.uk wrote:
Cycle's scrollHorz and scrollVert fx options allow back and forth
functionality for the Prev/Next and Pager functions.
The scrollVert transition scrolls Next content downwards and Prev
upwards.
I'd prefer
Thanks for your suggestions Ricardo.
Tabs 2 fails in requiring the trigger links to be located within the
same div as the content. Otherwise it fits well.
UI Tabs lacks the back button capability of Tabs 2 and doesn't play
with Safari 2, which (for better or worse) I'm required to support at
My oversight. Looking at the comments more closely shows Tabs 2
provides options for separation of navigation and content markup
(assigning navClass and containerClass classes respectively).
Thanks again.
Jonny
On Jan 27, 4:58 pm, Jonny Stephens goo...@bloog.co.uk wrote:
Thanks for your
I'm looking for a jQuery 1.2.6 compatible plugin providing the
following:
In a page with a number of sections in divs, on page load a specified
div is visible but all others are hidden.
Clicking a link in the sidebar navigation hides the current div and
reveals in that position the div which
13 matches
Mail list logo