We have multiple URL's, wanted to compare
https://securepubads.g.doubleclick.net/gampad/ads?ssp%3D0
if you can see in below URL ssp=0 can be present anywhere. I want a wildcard code that can be replace ssp%3D0.
https://securepubads.g.doubleclick.net/gampad/ads?pvsid%3D326202298883096&correlator%3D3063969260360993&output%3Dldjh&gdfp_req%3D0&vrg%3D2022030600&ptt%3D08&impl%3Dfifs&iu_parts%3D3302333,profpromo,medscpnewsdesktop&enc_prev_ius%3D/0/0/2,/0/0/2,/0/0/2,/0/0/2,/0/0/2,/0/0/2,/0/0/2&prev_iu_szs%3D320x90|828x90|980x90|980x290,320x90|300x290|300x600|300x390,320x90|0x2,0x2,320x90|2x9,320x90|2x9,320x90|828x90|828x90&fluid%3Dheight,height,height,0,height,height,height&ifi%3D0&adks%3D838338968,2333289989,3296303628,0699999960,3982038306,3982003000,883988630&sfv%3D0-0-38&ecs%3D20220323&fsapi%3Dfalse&prev_scp%3Dpos%3D003&ad_slot%3Dads-pos-003&mnetPageID%3D9&mnetCC%3DIN&mnetCV%3D0&mnetUGD%3D3&mnetCID%3D8CU9I96G3&hb_abt%3Dhb&mnetDNB%3D0|pos%3D022&ad_slot%3Dads-pos-022&mnetPageID%3D3&mnetCC%3DIN&mnetCV%3D0&mnetUGD%3D3&mnetCID%3D8CU9I96G3&hb_abt%3Dhb&mnetDNB%3D0|pos%3D900&ad_slot%3Dads-pos-900|pos%3D009&ad_slot%3Dads-pos-009|pos%3D622&ad_slot%3Dads-pos-622|pos%3D822&ad_slot%3Dads-pos-822|pos%3D030&ad_slot%3Dads-pos-030&mnetPageID%3D0&mnetCC%3DIN&mnetCV%3D0&mnetUGD%3D3&mnetCID%3D8CU9I96G3&hb_abt%3Dhb&mnetDNB%3D0&eri%3D0&cust_params%3Dlif%3D0&val%3D0&vit%3D&pbs%3D&st%3D0&tar%3D0&actid%3D0&occ%3D0&sa%3D0&tc%3D0&ct%3D0&pb%3D0&usp%3D0&pf%3D0&masid%3D0&gd%3D0&pbp%3D&ssp%3D08&ac%3D0&art%3D0&as%3D0&cg%3D0&ssp%3D0&scg%3D0&ck%3D0&pub%3D0&pc%3Dhp&auth%3D0&spon%3D08&env%3D0&envp%3Dprod&ep%3D0&
Sorry for bit confused question
Related
Say I have a website that accepts URLs of the form:
http://mywebsite.com/viewdata?content=aggregated&format=circular
Where the content is modified by a parameter (content) and the format is modified by a parameter (format).
What is the term for this sort of URL? How do you refer to the URLs of a "dynamic" website? Is there a difference in terms for parameters that change the content vs the presentation?
This is similar to this question, but I'm trying to figure out what to call the entire URL and the process of using the URL to dynamically change page content.
Sorry if the question is a bit unclear: it's hard to ask when you don't even know what words to use.
you got to learn this tutorial
http://w3schools.com/php/ or http://w3schools.com/asp programming or .... langs
I have some easy to read URLs for finding data that belongs to a collection of record IDs that are using a comma as a delimiter.
Example:
http://www.example.com/find:1%2C2%2C3%2C4%2C5
I want to know if I change the delimiter from a comma to a period. Since periods are not a special character in a URL. That means it won't have to be encoded.
Example:
http://www.example.com/find:1.2.3.4.5
Are there any browsers (Firefox, Chrome, IE, etc) that will have a problem with that URL?
There are some related questions here on SO, but none that specific say it's a good or bad practice.
To me, that looks like a resource with an odd query string format.
If I understand correctly this would be equal to something like:
http://www.example.com/find?id=1&id=2&id=3&id=4&id=5
Since your filter is acting like a multi-select (IDs instead of search fields), that would be my guess at a standard equivalent.
Browsers should not have any issues with it, as long as the application's route mechanism handles it properly. And as long as you are not building that query-like thing with an HTML form (in which case you would need JS or some rewrites, ew!).
May I ask why not use a more standard URL and querystring? Perhaps something that includes element class (/reports/search?name=...), just to know what is being queried by find. Just curious, I knows sometimes standards don't apply.
I'm currently re-working an application and want to add in a version number to the application URL paths. For example:
http://mydomain/app/VERSION-ID/resource/...
My question is, what is the correct or standard format to add a version id to a URL string? Is there any disadvantage to just having it numeric (1.1 or 1-1):
Example: https://api.twitter.com/1.1/account/verify_credentials.json
Or is it better to have a non numeric identifier to be more intuitive as the url is public facing?
Thanks.
Do not use dots in a URL unless you're defining domain spaces. Use either dashes or other truncated versions (that don't use disallowed characters in the URL).
EXAMPLE:
Example: https://api.twitter.com/v1-1/account/verify_credentials.json
UPDATE: Here is some more information in another thread. My preference is not to use dots if at all possible, but it is apparently OK to do.
Can urls contain dots in the path part?
If an extra character (like a period, comma or a bracket or even alphabets) gets accidentally added to URL on the stackoverflow.com domain, a 404 error page is not thrown. Instead, URLs self correct themselves & the user is led to the relevant webpage.
For instance, the extra 4 letters I added to the end of a valid SO URL to demonstrate this would be automatically removed when you access the below URL -
https://stackoverflow.com/questions/194812/list-of-freely-available-programming-booksasdf
I guess this has something to do with ASP.NET MVC Routing. How is this feature implemented?
Well, this is quite simple to explain I guess, even without knowing the code behind it:
The text is just candy for search engines and people reading the URL:
This URL will work as well, with the complete text removed!
The only part really important is the question ID that's also embedded in the "path".
This is because EVERYTHING after http://stackoverflow.com/questions/194812 is ignored. It is just there to make the link, if posted somewhere, if more speaking.
Internally the URL is mapped to a handler, e.g., by a rewrite, that transforms into something like: http://stackoverflow.com/questions.php?id=194812 (just an example, don't know the correct internal URL)
This also makes the URL search engine friendly, besides being more readable to humans.
I have a news section where the pages resolve to urls like
newsArticle.php?id=210
What I would like to do is use the title from the database to create seo friendly titles like
newsArticle/joe-goes-to-town
Any ideas how I can achieve this?
Thanks,
R.
I suggest you actually include the ID in the URL, before the title part, and ignore the title itself when routing. So your URL might become
/news/210/joe-goes-to-town
That's exactly what Stack Overflow does, and it works well. It means that the title can change without links breaking.
Obviously the exact details will depend on what platform you're using - you haven't specified - but the basic steps will be:
When generating a link, take the article title and convert it into something URL-friendly; you probably want to remove all punctuation, and you should consider accented characters etc. Bear in mind that the title won't need to be unique, because you've got the ID as well
When handling a request to anything starting with /news, take the next part of the path, parse it as an integer and load the appropriate article.
Assuming you are using PHP and can alter your source code (this is quite mandatory to get the article's title), I'd do the following:
First, you'll need to have a function (or maybe a method in an object-oriented architecture) to generate the URLs for you in your code. You'd supply the function with the article object or the article ID and it returns the friendly URL with the ID and the friendly title.
Basically function url(Article $article) => URL.
You will also need some URL rewriting rules to remove the PHP script from the URL. For Apache, refer to the mod_rewrite documentation for details (RewriteEngine, RewriteRule, RewriteCond).