Sponsored Content
Top Forums UNIX for Dummies Questions & Answers deny directly allow indirectly (.htaccess) Post 302275815 by pludi on Monday 12th of January 2009 08:51:59 AM
Old 01-12-2009
Example .htaccess
Code:
SetEnvIfNoCase Referer "^http://$" html_ref=1
Order Allow,Deny
Allow from env=html_ref

Will allow access only if the browser submits a referer field starting with "http://" (e.g. embedded in a site)
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

.htaccess?

For a schoolproject, I have to set up an intranet at a company headquarters in the Netherlands. But they want to give the division in the United States access to that intranet. I have to find out how to do that. I've heard that you can do that by giving certain people access to the intranet with... (1 Reply)
Discussion started by: Puc conDoin
1 Replies

2. UNIX for Dummies Questions & Answers

.htaccess

i want to protect a folder on my HP.... does the folder need more than ".htaccess" and ".htpasswd" to be protected , and ask for login and password??? Please help ...... i use HTAdmin 1.2.1 to manage my access files.. The systemadmin cant or wount answer.....:confused: Avenger (3 Replies)
Discussion started by: Avenger
3 Replies

3. Cybersecurity

htaccess

Something is wrong. I do everything right make the .htaccess file and stuff, but when I try the htpasswd command it says command not found. I use Putty SSH client and I think server is running RedHat 7.1 with Apache some version. HELP!!! (1 Reply)
Discussion started by: _hp_
1 Replies

4. Cybersecurity

Logging htaccess

hi i am trying to make a log of all users who access my website, i am using htaccess to administrate logins, how does htaccess store a session i.e where is the valid user login temporarily stored while a user is using the site or is there already some sort of logging being done by htaccess. ... (2 Replies)
Discussion started by: omnibarb
2 Replies

5. UNIX for Dummies Questions & Answers

ssh directly with a password

Can someone please tell me how to ssh into a computer when I have a username and password? Like something like: ssh username : pass @ server Can I do something like that directly? (6 Replies)
Discussion started by: Legend986
6 Replies

6. UNIX for Advanced & Expert Users

Redirect with htaccess

Hi, I would like to use htaccess 301 redirect with URL hiding. Ex: when browse the website 'abc.com' it should show the contents of the page 'xyz.com/start/index.html' but in addressbar should show the domain 'abc.com'. I know it works with html URL frame rewrite. But my question is it... (0 Replies)
Discussion started by: chandranjoy
0 Replies

7. Web Development

.htaccess redirect with #

I have the following directive in my .htaccess: #RewriteRule ^mozrank/?$ "http://www.seobook.com/#a_aid=dh" The problem is that the redirect is going to http://www.seobook.com/%23a_aid=dh How to preserve the # when redirecting? (2 Replies)
Discussion started by: rlopes
2 Replies

8. Shell Programming and Scripting

Download on a link doing it indirectly

How do I download on a link doing it indirectly, with once redirection by using curl commands or Bash script of them (2 Replies)
Discussion started by: abdan
2 Replies
Arch::FileHighlighter(3pm)				User Contributed Perl Documentation				Arch::FileHighlighter(3pm)

NAME
Arch::FileHighlighter - syntax-highlight file's content using markup SYNOPSIS
use Arch::FileHighlighter; my $fh = Arch::FileHighlighter->new( [ 'internal(pm+c)', 'none(txt), 'enscript', 'internal', ] ); my $html_ref = $fh->highlight($0); print $$html_ref; print ${$fh->highlight('file.c', '/* some code */')}; DESCRIPTION
This class processes file contents and produces syntax highlighting markup. This may be used together with css that defines exact text colors and faces. The default is to use the builtin "internal" processing, that is pretty poor; only very basic file types and syntax constructions are supported. It is suggested to configure and use the external "enscript" utility. GNU enscript understands quite a rich number of file types and produces a useful syntax highlighting. "enscript" filter is used by default if /usr/bin/enscript is found. It is possible to configure different filters ("none", "internal", "enscript") depending on file name extension. In any case the resulting markup is always unified, i.e. all special characters are HTML-encoded using SGML entities, and the markup that looks like <spanclass="syntax_foo">bar</span> is used. METHODS
The following methods are available: new, instance, highlight. new [filters] Create a new instance of Arch::FileHighlighter. filters is arrayref of strings of the form filter(ext1+ext2+...)", where filter is one of "enscript", "internal" or "none". Special extension ":xml" is a shortcut for "html+htm+sgml+xml+wml+rss+glade". The filters optionally constrained by file extensions are probed sequentially and the first passed one is used. Note that if enscript is configured in the sequence, but is not installed, then its probing may print a warning to stderr. The "enscript" filter is handled a bit specially, it may take parameters "mono" (less colors) and "asis" instead of the file extensions. If enscript returns html without any tags, then the filter is handled as failed, unless "asis" is given. By default, filters is [ 'internal' ], or [ 'enscript', 'internal' ] depending on presense of '/usr/bin/enscript'. instance [filters] Alternative constructor. Return the last created instance of Arch::FileHighlighter or create a new one. The purpose of this alternative constructor is to allow the singleton behaviour as well as certain Aspect Oriented Programming practices. highlight filename [content] Process filename using configured filters (as described in the constructor) and produce the file content with embeded <span class="class">...</span> markup. class is one of: syntax_keyword syntax_builtin syntax_comment syntax_special syntax_funcdef syntax_vartype syntax_string syntax_constant If content is provided (either string or reference to string), it is used, otherwise the content of filename is loaded. BUGS
Awaiting for your reports. AUTHORS
Mikhael Goikhman (migo@homemail.com--Perl-GPL/arch-perl--devel). SEE ALSO
For more information, see enscript, Arch::Util, Syntax::Highlight::Perl. perl v5.10.1 2005-10-23 Arch::FileHighlighter(3pm)
All times are GMT -4. The time now is 07:53 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy