473,387 Members | 1,512 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Display Hyperlinks from Stored Text

Hi -

I have a job board site where users input position descriptions and "how to apply" information. Invariably, the How to Apply field contains email and web addresses that display as plain text when I show them on dynamically-generated pages. How do I get hyperlinks to show up? I'm a beginner, using asp and Sql Server.

Thanks for any help you can provide.
Feb 8 '08 #1
4 1170
CroCrew
564 Expert 512MB
Hello schmoolie,

Here are a few examples:

Example 1:
Expand|Select|Wrap|Line Numbers
  1. <%response.write("<a href='www.Microsoft.com'>Microsoft</a>")%>
  2.  
Example 2
Expand|Select|Wrap|Line Numbers
  1. <%response.write("<a href='" & MyRs("DatabaseURL") & "'>" & MyRs("DatabaseSiteName") & "</a>")%>
  2.  
  3.  
Hope it help you out~
Feb 8 '08 #2
Thanks, but I'm looking for something that will display a textfield that includes a bunch of plain text with a hyperlink embedded in it. I don't want to display the entire text output as a hyperlink, just the portion of it that's a web address or an email address. This will likely be embedded somewhere in an unpredictable place in the text.




Hello schmoolie,

Here are a few examples:

Example 1:
Expand|Select|Wrap|Line Numbers
  1. <%response.write("<a href='www.Microsoft.com'>Microsoft</a>")%>
  2.  
Example 2
Expand|Select|Wrap|Line Numbers
  1. <%response.write("<a href='" & MyRs("DatabaseURL") & "'>" & MyRs("DatabaseSiteName") & "</a>")%>
  2.  
  3.  
Hope it help you out~
Feb 8 '08 #3
CroCrew
564 Expert 512MB
Are you saying that you want to embed a hyperlink within a <textarea> of a <form>?
Feb 8 '08 #4
CroCrew
564 Expert 512MB
As far as I know you cannot have active HTML code in a <textarea>. What you could do is use a Rich Text Area that would allow you to use HTML. But, this would not be a <form> element. But again, with some advanced JavaScript you could pull the information out of the Rich Text Area and submit it along with a <form> if need be.

Here is some code:
Expand|Select|Wrap|Line Numbers
  1. <html>
  2.     <head>
  3.         <title>Example</title>
  4.         <style>
  5.             #xTextArea 
  6.             { 
  7.                 height: 200px; 
  8.                 width: 400px; 
  9.                 border: medium inset #CCCCCC; 
  10.                 overflow: auto; 
  11.             } 
  12.         </style>
  13.     </head>
  14.     <body>
  15.         <div id="xTextArea"> 
  16.              This is a link to <a href='www.Microsoft.com'>Microsoft</a> home page.<br>
  17.              <%response.write(MyRs("MessageFromDatabase")%>
  18.         </div> 
  19.     </body>
  20. </html>
  21.  
Hope this helps~
Feb 8 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: deko | last post by:
I store hyperlinks as text in a table like this: Invoice11-21-2003.pdf#file://P:\Finance\PrefVendors\Receipts\Invoice11-21-20 03.pdf I need to run a report that lists the documents - or...
1
by: Tom | last post by:
I have a project database in which I use hyperlinks to call up various related supporting documents (e.g., proposals, contracts, reports, site photos, etc.). The documentes are in Word, Excel, PDF...
2
by: Sam Collett | last post by:
Say I have string foo = "Some text http://www.google.com more text fred.bloggs@somewhere.com more"; How could I parse it to find the links and store the results in a string array, i.e. to get...
0
by: Lasse Vågsæther Karlsen | last post by:
I was wondering if someone knew about a control for .NET that allows me to display log messages from an application while it is running. The following things are necessary: - word-wrap -...
6
by: dee | last post by:
Here is a a list of my hyperlinks in my home page: <A class="theclass" href="Default.aspx">Home</A> <A class="theclass" href="Search.aspx">Search</A> <A class="theclass"...
4
by: Seefor | last post by:
Hi, I want my text hyperlinks to have a dotted border underneath, so I did this which works fine: a, a:link, a:visited, a:hover, a:active { color: #000; text-decoration: none;
2
by: Bishoy George | last post by:
I have a database table with many columns: ItemID , ItemName , ItemLink , ItemSize I want to display items through a datagrid or whatever in the way that the ItemName is written and has the...
2
by: Joe Campbell | last post by:
I have a DBA that wrote a stored procedure that does a SELECT from a particluar SQL Server table. Within that stored procedure he links over to grab a column from another database table. I need to...
1
by: suparna | last post by:
The CSV file has few urls in an order. While opening the CSV file using Excel Sheet, the urls are not having the hyperlinks. It is stored as plain text. So we need a program that will store these...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.