How to make a HTML link?

This forum is user-to-user based and not regularly monitored by IDM.
Please see the note at the top of this page on how to contact IDM.

How to make a HTML link?

Postby moerl » Sat Oct 15, 2005 5:32 am

In UEStudio, is there an easy way to "linkify" regular text? That is, is there an easy way to select any text and turn it into an HTML link without having to manually type <a href=URL>NAME</a>?

Thanks
User avatar
moerl
Newbie
 
Posts: 6
Joined: Fri Oct 14, 2005 11:00 pm

Re: Simple HTML question

Postby Mofi » Sun Oct 16, 2005 2:28 pm

There is no standard button for this in the toolbar. But you can create a macro for this task and run the macro with a hotkey whenever you need it.

Solution 1:

InsertMode
ColumnModeOff
HexOff
IfSel
Clipboard 9
Cut
"<a href="">"
Paste
"</a>"
ClearClipboard
Clipboard 0
Else
"<a href=""></a>"
EndIf


Solution 2: This one asks for the url.

InsertMode
ColumnModeOff
HexOff
IfSel
Clipboard 9
Cut
"<a href=""
GetString "Enter the url:"
"">"
Paste
"</a>"
ClearClipboard
Clipboard 0
Else
"<a href=""
GetString "Enter the url:"
""></a>"
EndIf


Look also at Downloads - Additional Downloads - Macros here on this site. There are some useful macros for html editing.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 3937
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: How to make a HTML link?

Postby moerl » Sun Oct 16, 2005 10:49 pm

Awesome.. thanks a lot :)

I didn't even know there were downloadable macros on the site. I'll check them out, and thank you for your suggestions as well.
User avatar
moerl
Newbie
 
Posts: 6
Joined: Fri Oct 14, 2005 11:00 pm

Re: How to make a HTML link?

Postby Mofi » Wed Apr 11, 2007 6:31 am

Converting a text into an URL could be also done faster with a template as I now do.

Example 1: Template "Convert to URL"

<a href="[$replace$]">[$replace$]</a>


Example 2: Template "Insert URL"

<a href="^">[$replace$]</a>


Example 3: Template "Convert to mail URL"

<a href="mailto:[$replace$]">[$replace$]</a>


Maybe this can be also done with customized HTML toolbar commands, but I use the templates with hot keys because it is faster.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 3937
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: How to make a HTML link?

Postby Ugotmo » Fri Sep 21, 2007 8:20 pm

i added somethings I found useful to your script.

1) made it open a new tab when you click on the link

2) you can input the discription text



InsertMode
ColumnModeOff
HexOff
IfSel
Clipboard 9
Cut
"<a href=""
GetString "Enter the url:"
"">"
Paste
"</a>"
ClearClipboard
Clipboard 0
Else
"<a href=""
GetString "Enter the url:"
"" target=\rdblquote _blank\rdblquote >""
GetString "Enter the display text:"
""</a>"
EndIf
User avatar
Ugotmo
Newbie
 
Posts: 1
Joined: Thu Sep 20, 2007 11:00 pm


Return to UEStudio General Discussion

cron