I'd like to "grab" a few hundred urls from a few hundred html pages.
Pattern:
<h2><a href="http://www.the.url.might.be.long/urls.asp?urlid=1" target="_blank">The Website</a></h2>
I am writing a tomcat app, and have a need to do authentication within the URL like this:
https://user:[email protected]
Except for the life of me i'm not sure how to set it up or able to find the docs to read up on it, clearly my google skills need work.
Can anyone tell me where i should be looking for this kind of info or where to start?
Cheers
Andy
Please, I have another simple question for experienced programmers.
Is it possible to get source code of any webpage with javascript at client side?
With AJAX maybe?
But I need that the server I am downloading the url from does see the IP of the client.. with AJAX it will show my script server IP, right?
Thank you in advance.
I'm trying to set the Default URL of my MVC application to a view within an area of my application. The area is called "Common", the controller "Home" and the view "Index".
I've tried setting the defaultUrl in the forms section of web.config to "~/Common/Home/Index" with no success.
I've also tried mapping a new route in global.asax, thus:
routes.MapRoute(
"Area",
"{area}/{controller}/{action}/{id}",
new { area = "Common", controller = "Home", action = "Index", id = "" }
);
Again, to no avail.
I want to take my .htaccess file and add a second rule for another vanity URL as I already have one declaring the page. So how would I write it so I can go to my page, and the next vanity being a variable for a profile?
Ex:// mywebsite.com/page/profile
Here is my current .htaccess file.
RewriteEngine On
RewriteBase /
RewriteRule ^([a-zA-Z0-9-]+)$ index.php?p=$1 [L]
RewriteRule ^([a-zA-Z0-9-]+)/$ index.php?p=$1 [L]
requests ----- should be written to new url
/institute/dps ----- /institute.php?slug=dps
/institute/abc ----- /institute.php?slug=abc
/institute/123 ----- /institute.php?slug=123
I am using following rule in .htaccess
RewriteRule ^institute/(.*)$ /institute.php?slug=$1
However, it's not working. the page insitute.php get's execution, but the query string always comes empty.
Any suggestions?
I have one problem.
I have one button and one textarea in a frame.I want to show the source code in that textarea when I click on button. show source code of URL that I want to show.
help pleas!
Hi All,
I am using asp.net with C# [3.5]. I want to display Image before my URL in browser, like IE and mozilla used to have. I want to display my custom image.
Please help.
Thanks in advance
HI, I need to remove a querystring when a user clicks a particular LinkButton.
So for example if the querystring is http://UserProfileManager.com?UserID=1234 .... when the user clicks on the Linkbutton, I want the url to be http://UserProfileManager.com. The issue is that everything is on one page, and I am using
Any ideas would be appreciated.
How can I rewrite a simple number based URL to a sub folder?
I want http://mysite.com/123 to redirect to http://mysite.com/en/123.
The number could be anything from 1 - 9999. My attempt in htaccess was:
RewriteRule ^([0-9]+)$ /en/$1/ [R]
But that doesn't work.
H!,
I have a solution in which there is several other sub projects (windows application).
in every project I have some web services added.
Now the problem :
how can i set the URL of each web service individually from the app.Config file??
is there a setting I missed to set ?
can it be automatically done or I have to code for it ?
Thank you friends.
I have log in functionality that will check for a session, if it not there the user will be redirected via Request::instance()-redirect('managers/error/1');
In the error action in the managers controller I can't get the value 1 which represents a specific error msg.
How can I capture the value "1" from the url, I'm only using standard routes.
I have a client who is wanting to create a link which contains product codes so that his customers hit a page with just those products displayed in an attempt to increase conversion rates from affilliate sites.
My question is whats the best way to send these multiple products in a single URL
For example:
http://www.mydomain.co.uk/bespoke-list.php?catNo=234-324-232-343
Obviously then the site would grab the codes from the string and display them...
We're going to be using PHP!
Thanks in advance.
What is the elegant way to convert JSONObject to URL parameters.
For example, JSONObject:
{stat: {123456: {x: 1, y: 2}, 123457: {z: 5, y: 2}}}}
this should be like:
stat[123456][x]=1&stat[123456][y]=2&stat[123457][z]=5&stat[123457][y]=2
of course with escaped symbols, and of course JSON object could be more complicated..
Maybe there already exist some mechanisms for that?
Thanks,
I need to be able to block the urls that are stored in a text file on the hard disk using Python. If the url the user tries to visit is in the file, it redirects them to another page instead. How is this done?
I want to hide the URL of my PHP page; that is, I don't want to write /register.php directly in the href tag, I want to write /register/ and have it open the register.php page directly. I want to do that for all the webpages.
Hey guys,
I've seen URL's like this around and I'm just wondering how it is they are used.
Until now I've been using www.mysite.com/users/?id=33
How can I use the other format?
I have an ajax navigation similar like here.
now if a menu is clicked window.location.hash is added like this #about
i want to REmove the hash (#) so that people can easily copy and share the link naturally.
How this can be done in april 2012 without a pagerefresh crossbrowserwise (IE7+,FF,Opera,Safari) ?
For inspiration: Here is actually someone already doing this, click on "portfolio" or "features" and watch the url in your browser.
thanks for tips
Hi folks,
I have configured the standard "frontpage" view in order to display a list of nodes, just by displaying a field (the banner image).
Unfortunately the URL /frontapge does not return the previewed template, but the same page that would get displayed before the views module was installed.
Help would be much appreciated.
Hi,
I need some help with regards to the url redirection. Here is the problem.
We have a website with a section as http://www.site.com/sectionxxx/index.jsp
we have another domain http://www.sectionxxx.com.
The task is to forward any request comming for the http://www.sectionxxx.com; direct to http://www.site.com/sectionxxx/index.jsp.
Any idea?
P
my current url is something like:
http://something.somedomain.com/about_us/profile.php?tab1=about_us
a more complicated on is:
http://something.somedomain.com/exchange_hosting/feature/outlook_web_access.php?tab1=exchange_hosting&tab2=feature&tab3=outlook_web_access
i want to make them shorter:
http://something.somedomain.com/about_us/profile
http://something.somedomain.com/exchange_hosting/feature/outlook_web_access
my .htaccess
#################################
# Directory Indexes #
#################################
DirectoryIndex index.php
#########################################
# REWRITE RULES #
#########################################
RewriteEngine On
RewriteBase /
Options +FollowSymlinks
<IfModule mod_rewrite.c>
#not a file
RewriteCond %{REQUEST_FILENAME} !-f
#not a dir
RewriteCond %{REQUEST_FILENAME} !-d
#this dosen't work
#RewriteRule ^([a-zA-Z0-9_-]+)/([a-zA-Z0-9_-]+)$ /$1.php?tab1=$0&tab2=$1
</IfModule>
# END #
Does this mean that it will be looking for index.php and provide the GET variable y with /home/xxx/public_html/control/&x=shell?
http://www.xxx.com/control/?y=/home/xxx/public_html/control/&x=shell
Long story: Website got defaced, and found this b374k script when browsing to one of the page, I am trying to figure out where exactly they injected this script, thus trying to figure out a hint from this url where the scripts resides in.
Hello all , I am trying to create url routing like this
http://msdn.microsoft.com/en-us/magazine/dd347546.aspx
but I am having few questions , first why he is adding lines to the web.config , I tested it and it didnt appear that they're doing something as I commented them and nothing major appeared
second I am having this line of code that is crashing
var display = BuildManager.CreateInstanceFromVirtualPath(_virtualPath,typeof(Page)) as IProfileHandler;
when casted as ihttphandler it's working , but when I am casting it to iprofilehandler(which is implemeting ihttphandler) it's giving null !
hello all , I am trying to create url routing with strongly typed objects for pages but I keep getting null object on the first line so it's crashing
//Getting the suitable executing Page
var display = BuildManager.CreateInstanceFromVirtualPath(_virtualPath,typeof(Page)) as IProfileHandler;
//Setting Page Parameters
display.MemberId = Convert.ToInt32(requestContext.RouteData.Values["ID"]);
//Return Page
return display;
public interface IProfileHandler : IHttpHandler
{
int MemberId
{
get;
set;
}
}