Hi,
How do you create a hyper link that opens in another
window and displays your source code in text format??
The following example doesn't work:
<a href="filename.txt" target="_blank" width="600" height="400"> link </a>
The above code doesn't display the source code
It interprets it even though my filename is .txt (dot txt)
Any help will be much appreciated
Displaying Code In New Window - Help
Moderator: General Moderators
- social_experiment
- DevNet Master
- Posts: 2793
- Joined: Sun Feb 15, 2009 11:08 am
- Location: .za
Re: Displaying Code In New Window - Help
Strange; the target="_blank" is the correct method for opening a new window in the browser. Do you have an .htaccess file set up; maybe it is causing certain file types to be processed as .php (i'm guessing your refering to php code here)
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” - Mosher’s Law of Software Engineering
-
litebearer
- Forum Contributor
- Posts: 194
- Joined: Sat Mar 27, 2004 5:54 am
Re: Displaying Code In New Window - Help
@social-exp:
What is an htaccess file? I'm relatively new
in this so please bear with me guy..
@litebearer:
Thanks for the link. But now the text file
should be filename.txt (dot txt) - the examples only deal
with .php (dot php) files
What is an htaccess file? I'm relatively new
in this so please bear with me guy..
@litebearer:
Thanks for the link. But now the text file
should be filename.txt (dot txt) - the examples only deal
with .php (dot php) files
- social_experiment
- DevNet Master
- Posts: 2793
- Joined: Sun Feb 15, 2009 11:08 am
- Location: .za
Re: Displaying Code In New Window - Help
http://www.javascriptkit.com/howto/htaccess.shtml
This url will explain about .htaccess
This url will explain about .htaccess
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” - Mosher’s Law of Software Engineering