A Uniform Resource Locator (URL) is a Uniform Resource Identifier (URI) that specifies where an identified resource is available and the mechanism for retrieving it.

learn more… | top users | synonyms

7
votes
0answers
208 views

Efficiently using Apache HttpClient in multithreaded environment

I have a library which is being used by customer and they are passing DataRequest object which has userid, various ...
3
votes
0answers
42 views

Determine base URL of PHP app

I have this little piece of code which determines the base URL of PHP: ...
0
votes
1answer
27 views

Loading URLs via a case statement

I have the following code which loads in a URL based on the id of a user-clicked button. I'm looking to compress it down as much as possible, and make it more modular and reusable: ...
-1
votes
1answer
31 views

Skipping Google search results that point to certain sites

I have the following code that will skip certain URLs if needed: ...
2
votes
1answer
114 views
1
vote
2answers
71 views

Recreating a URL string

This is what my viewObject looks like: ...
3
votes
1answer
93 views

Parsing URL query and appending it at end of the other URL

I am trying to grab the URL query of the URL which is in the browser's address bar, then append it at the end of the other URL and echo it to the browser. So, if I visit my script at: ...
2
votes
1answer
43 views

Building a SharePoint Search URL

I'm trying to build a URL to call the SharePoint Search REST API in TypeScript. The interesting part is building the querytext, which is done by my buildQueryText method. In my case it takes two ...
1
vote
0answers
53 views

URL validation and data extraction

What do you think about this approach to validate and analyze URLs? There are Url and Url<TResource> model types to ...
4
votes
1answer
48 views

Extracting various URL parameters in Rest Service and then passing it to Builder class

I have a service which takes a lot of key value parameters in a URL. Only a few are mandatory and others are optional. It's up to the customer whether they want to set those optional parameters or ...
3
votes
2answers
232 views

Parsing “mailto:”

Can you help me to review my "mailto:"-parsing function ? Since I'm trying to write less code, that is as simple as possible. I'm not sure there if there is some bug or better solution. ...
1
vote
1answer
62 views

Converting url data to base 64

I've a piece of code down below that I'm really unsure about. Basically an user can type the url (urlStr param of the method) he wants. From this url I need to : get the data as Base64 so I can ...
5
votes
0answers
58 views

Router to match URL to Controller Method

I wrote a router class which accepts a URL and calls the appropriate controller method based on it. I'm a little worried about the amount of dependencies it has (eg ...
3
votes
2answers
53 views

str_replace vs array_map & trim on URL segments

Are there any advantages on using array_map & trim vs using simple str_replace? The ...
3
votes
1answer
53 views

Construct a URL given an Enum

I have a below code which constructs the URL given a FlowType enum. ...
4
votes
3answers
561 views

Generating a URL

I have a function that generates a URL using a stringbuilder: ...
3
votes
1answer
128 views

Downloading HTML documents from the web

In this project I'm working on, I need to extract articles text from their original HTML document. This class, HtmlConnection, receives the URL of the article, and ...
0
votes
0answers
69 views

Adding a link on page with current URL (including hash) in a querystring

I'm trying to add a link to a page. The link should contain the current URL in a querystring (to be used as a ReturnUrl) and it can contain a hash. ...
1
vote
3answers
129 views

URL Query params builder

My goal is to create a URL query params from std::map<std::string, std::string>. For example, we call ...
8
votes
1answer
203 views

Read and replace URL from PDF file

This is a code I wrote to find all URL within a PDF file and replace the one that matches the ID that I passed as a parameter. It works as intended, but as I am a beginner on Java, I am sure there ...
8
votes
2answers
82 views

Opening all the links

I am looking to improve my code structure. In this code it is opening all the links with ?pid= in the url. However, the structure of the code can be improved. ...
7
votes
2answers
344 views

Efficient URL Escape (Percent-Encoding)

Here I have a simple algorithm to percent-encode any string. (Specification from Wikipedia; note that this is not compatible with URLEncoder.encode()) Is this an ...
4
votes
1answer
379 views

Short hash generator

I am working on some code that will generate a link with a relativly unique 10 character hash. I am not worried to much about colisions as long as they are rare enough that I could have a couple ...
3
votes
0answers
46 views

Item purchasing using urllib

I have this function that gets an item passed from another function, together with the subtotal and the fee of the item. The function has to act as fast as possible, as other people also want the ...
3
votes
2answers
158 views

Extracting and normalizing URLs in an HTML document

I have written code to get all urls on a webpage & put them in a set, and would like tips on simple changes I can make to increase its performance. ...
4
votes
1answer
74 views
2
votes
2answers
67 views

Prettifying URLs for a PHP-based club website

I have a website for my car enthusiast club ("example.org") whose content can be divided into three main sections: Startseite (the "front page" of the site), Mitglieder (membership directory), and ...
4
votes
1answer
63 views

Adding proper validations on all the parameters coming from the URL in Rest Service

I am working on a RestService in which my URL will take lot of parameters. Below are the parameters my URL will take: UserId: ...
5
votes
3answers
376 views

Getting 6 possible URL parameters

I am in the midst of writing a simple job board and I have the URL's filtering and working how I want, everything works - I just want to know if I can improve it, if there are any security concerns, ...
1
vote
2answers
106 views

Manipulating URL parameters

I am new in JS, I am writing some extra filters on the Interface. So extra filter needs to add or update the parameter in the URL. Option 1. No parameter in existing URL: url = ...
2
votes
2answers
362 views

Return the first word in the image name

I just want to return the first word in the image name (before the dash, dog in my example). Now I use it like this but believe it can be done in a simpler way ...
4
votes
2answers
242 views

Multi-threaded domain status checking in Java

I'm tinkering with the idea of crafting a search engine in my spare time. More of a learning experience than anything at this point, but still a project. A key aspect of this system is checking ...
3
votes
1answer
349 views

URL link SEO and security using Laravel

I'm trying to figure out what the best way to do this is. I have a part on my website where people can search for a particular card based on multiple different factors. Like the name of the card, ...
2
votes
1answer
147 views

Generating URL and status for an S3 bucket

The following program generates the S3 URL and response (status code?) for the key, provided the bucket name and if the S3 URL is a mess (wrong url), then it generates empty string as URL and error as ...
2
votes
1answer
108 views

Intercept URL containing values or not

I need to intercept a URL and go outside the WebView if the URL contains MAPS or DOCUMENTS ...
11
votes
3answers
3k views

Constructing a query string using StringBuilder

I speedily wrote a bunch of crappy checks, to check whether strings are empty, in order to build a query string. ...
6
votes
2answers
485 views

Routing for a Laravel 5 e-commerce site

I am new here and learning Laravel 5 on my own. I want to get reviewed on the following routes.php code. My question are: Have I made any mistakes by doing this? If yes, then what could be the ...
2
votes
3answers
254 views

Object to query string

An object (POJO) holds query arguments and has two-binding to a form using some MVC framework. later the object needs to be converted to a query string that will be appended to an HTTP request. ...
5
votes
2answers
88 views

Parsing a URL from a document and matching it from an array

I need help in improving this script that I have written to parse a URL and check it from an array. This is what I have done till now: (fiddle) This is working fine. Was this done correctly? What ...
2
votes
1answer
333 views

Simple, functional URL parsing library in Clojure

I recently wrote some code to handle parsing of URLs, even if those URLs might not be one hundred percent perfectly well-formed. (This constraint made using Java's ...
1
vote
1answer
120 views

Generate URLs for images hosted on Google Drive

The brief is to be able to generate links to artwork files and PDFs easily and quickly without having to use a browser. I have added an image box which shows the user the image upon clicking one. The ...
2
votes
1answer
69 views

Dynamic building of URLs

I'm teaching myself Python and wanted to share this problem as my current solution feels inelegant but I'm not sure of the best way to refactor. If this sort of question isn't appropriate, leave a ...
3
votes
2answers
46 views

Registering endpoints and HTTP method for exemption of authentication

I have a set of API endpoints where the URL is not standardized, so I could either get "api/auth" or "api/auth/" (may or may not end with "/"). I'm 'registering' the endpoint, plus the HTTP Method ...
0
votes
2answers
414 views

Match all youtube links in a string of text

I'm looking to pull all the youtube links from a string of text and was wondering how does this look? ...
4
votes
2answers
210 views

Extracting a number from provided URLs inside a text file

I need to extract a ID (int number) from a Url. Example: http://www.example.com/foo/bar/12345 For this I wrote 4 methods where the first one ...
6
votes
1answer
80 views

Getting a value from a query string

I have a URL in this format: http://localhost:57279/AssociateCaseDetails?UId=176948&caseID=1123 I need the values of UId ...
3
votes
1answer
909 views

Java class that generates a short URL string for an input string

Help me find out if the approach I took to generate random strings here is correct to be able to return the appropriate short URLs. ...
6
votes
2answers
66 views

Extracting information from a URI

I'm completely new to C and my first project is to create a simple cURL-like HTTP request client... but first, I need to create a function that can parse a URL. I've created this function, and it ...
3
votes
2answers
5k views

Update URL with new parameter value

I needed a way to update a parameter in the URL, or add it if it doesn't exist, but keep any other variables the same value. I built this function to do the task, and while it works, I feel like it's ...
1
vote
1answer
81 views

Hash read/write/delete functions

Here is my JavaScript function to manipulate the hash: ...