Currently, when I am writing a 'New Entry' and use the 'URL' button to place a link in the copy ... it puts a regular old link ... which is great.
However, I'd like that link to 'always' be created with the
target="_blank"
action already there. It is just a personal choice thing.
Where, in what file, would I have to edit the ".php" to make this happen?
Is it 'serendipity_entries.php' ... can't figure it out.
Is there a forum post or s9y link with a description which I can't seem to find?
Any help, much appreciated! Thank you! Serendipity is terrific.
'New Entry' ... URL button .... change/add default 'target'
'New Entry' ... URL button .... change/add default 'target'
"You're only given a little spark of madness. You mustn't lose it."
Robin Williams, comedian
Robin Williams, comedian
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: 'New Entry' ... URL button .... change/add default 'targ
I guess you are using the URL button in non-WYSIWYG mode?
If so, edit your serendipity_editor.js and search for the function 'wrapSelectionWithLink' - there you will find the '<a href' code, where you can just insert your 'target=...' portion.
However, remember that 'target' is an invalid attribute for XHTML1.0 - you may want to use javascript for that:
or something like that...
Regards,
Garvin.
If so, edit your serendipity_editor.js and search for the function 'wrapSelectionWithLink' - there you will find the '<a href' code, where you can just insert your 'target=...' portion.
However, remember that 'target' is an invalid attribute for XHTML1.0 - you may want to use javascript for that:
Code: Select all
<a href="http://www.google.de/" onclick="window.open('newwin', this.href); return false">google</a>
Regards,
Garvin.
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Thanks Garvin. I had not thought of that... good point. I'll just set a keystroke paste-it-in thingie and use the javascript. I realize it is important to be xhtml compliant ... i just don't think of it. I appreciate the tip. Thanks, again, for your help!
"You're only given a little spark of madness. You mustn't lose it."
Robin Williams, comedian
Robin Williams, comedian