Questions tagged [url]

The web boasts the existence of a Universal Resource Locator (URL), which serves as an all-encompassing identifier. Essentially, a URL acts as a pointer directing towards a particular spot on the vast web and facilitating convenient access to the desired resource located there.

Updating URL parameters with an AJAX request in Rails 3 is a great way to dynamically

I am working with a filter and a list of products that have an id, name, and creation date. The filtering can be done by id, name, or creation date. When I make an AJAX request to update the content div, the URL stays the same. How can I add parameters t ...

Seeking information from JSON data using an internet address

Currently, I am utilizing the following URL to access my JSON data: myapp/laravelRoute/jsondata By entering this in the address bar, the JSON array below will be shown: [{"A":"B"},{"B":1},{"C","http"}] However, when I input the URL as follows: myapp/l ...

Encoding a string for use in a URL

After receiving a JSON data object, I extract a string from it using the following code: NSDictionary *jsonDictionary = [NSJSONSerialization JSONObjectWithData:data options:0 ...

Implementing JSON Parsing to dynamically add markers on Google Maps by passing a tag in the URL

There is a URL where I need to parse some information, including latitude and longitude, and display them on a map. Parsing and adding markers to the map seem to work fine. However, the markers are not being displayed, only the map itself. Initially, I tho ...

Running a JavaScript function through a URL: A simple guide

If you click on a div within the left-side menu, a specific file from the 'chapters' folder will be loaded into a div on the right side. <div id="menuLeft"> <div id="file01">File 01</div> <div id="file02">File 02</div& ...

Utilizing one URL to post parameters and retrieving JSON data from a different URL

Currently I am working with jQueryMobile and PhoneGap, but encountering an issue. I am trying to retrieve details in JSON format by posting parameters to one URL (URL1) and receiving the JSON response from another URL (URL2). However, I am unable to access ...

Attempting to extract the host and protocol using node.js url.parse results in both values returning as

I'm just starting my journey with node.js. I read on that url_parts should contain the keys host and protocol. However, both are returning null for me. Any idea why? Here is how I am calling the server: http://localhost:8181/test/?var=vartest http.creat ...

Serializing Laravel Query Builder allows you to convert the query

I am interested in creating a Laravel query that can be serialized into a URL string. This would enable me to generate routes that can unserialize the query builder, execute the query, and display the results from the database. For instance, let's sa ...

Analyzing URL parameters in Java

It is important to note that the following two URLs should be considered equivalent: http://localhost?asdf=1&qwer=2 http://localhost?qwer=2&asdf=1 However, when using the 'equals()' method from the URL class, they are identified as different. How ...

Guide on using .htaccess to redirect all extensions to files with .php after the .php extension

Google Webmaster Tools has flagged several crawl errors related to unconventional URL extensions being added to my existing pages. For example, this page appears normal: However, unexpectedly, there are these strange URLs generated from the original link ...

Is there a way to eliminate a variable name from a URL using htaccess?

Essentially, I am looking to allow users to access my website using a URL like /45678, as opposed to the traditional /?p=45678. The goal is to eliminate the variable name from the URL. I attempted to achieve this by utilizing mod_rewrite, but it appears th ...

What is the best way to combine a hyperlink with a string in an Angular form?

Currently I am in the process of learning angular and experimenting with creating a list of websites that can be clicked on, similar to what you would find in a bookmark app. This is based on a todo example. https://github.com/LightYear9/ToDoList In orde ...

Tips for deleting part of the URL at the end of all hyperlinks on a webpage

I have a large number of links on the same page that I would like to clean up by removing everything from specific characters until the end of the URL. Currently, there are too many links like this scattered throughout my page. The string "$amp;rs" or "&a ...

Utilizing the $_GET method with dynamic URLs

My issue involves working with dynamic URLs, where I have created a structure like this: http://www.example.com/index.php?page=test The problem arises when I try to send values via GET. Due to the URL structure being as follows: http://www.example.com/i ...

Guide to implementing onhashchange with dynamic elements

Hey there! I've encountered a problem with two select boxes on my webpage, each in different anchors (one on the page, the other in an iframe). What I'm trying to achieve is for the code to recognize which anchor it's in and then pass the selected value fr ...

Locate a specific keyword within a URL and store the URL in the first element of an array

I need assistance with PHP code to extract URLs containing the word artifact. I want to store these URLs in an array after using regex pregmatch to search for the desired keyword. PHP is the programming language being utilized for this task. Below are th ...

Navigating dynamic URLs with various URI segments in cPanel

<a href="www.mysite.com/index.php?information/adminpanel/<?php echo $id;?>" name="approve" id="approve" ">Approve >></a> After redirecting to the specified URL, the correct ID is displayed in the address bar but unfortunately, ...

Wordpress Ajax deeplinking leads to a 404 error page

Hey there, This is my first time posting here, and I want to say thank you for all the help I've already received by reading through previous posts. I'm currently working on a WordPress project, but I seem to be struggling to get a clear overview of my p ...

Guide on utilizing the retrieved information from a URL to choose specific JSON data in Django

Suppose I have a GET request with URL domain/search/?value=123 and the following JSON data: [ { "id": 1, "value": 123, "value2": 123123 }, { "id": 2, "value": 1, "value2": 214 } ] I want to retrieve data where value = 123. ...

Using CSS background-image URL in .NET MVC tutorials

What is the correct way to route to an image in an MVC web application? MVC has default routes, meaning you can access the same page in multiple ways: 1. localhost 2. localhost/home/index However, you can also do it this way, changing the root directory. ...

Error: The reference to the window object cannot be found, occurring when attempting to synchronize the search input state with react instant search

Currently, I am working with Next.js and facing a challenge regarding syncing my search state with URL query parameters. The goal is to maintain the search input state during navigation without losing it. Although Next.js is a server-side language, I am l ...

Ensure that the URL is updated correctly as the client navigates between pages within a Single Page Application

Seeking a solution for maintaining the URL in a Single Page application as the client navigates between pages, with the URL changing in the background. I attempted using @routeProvider but it doesn't seem to be suitable for my situation. Any suggestio ...

Inquiry about Codeigniter URL structure

How can I create user-specific URLs, like www.domain.com/username I understand that a route system may be necessary for this. While I have experience using it for other URL requests, I am unsure if I need to consider my other controller classes when dy ...

What is the best way to obtain the complete URL including the # symbol in PHP?

Currently, I am implementing AngularJS routing alongside php which results in my URLs appearing as http://localhost/admin/home#/categories However, the issue arises when attempting to retrieve the full URL as it only returns /admin/home. I have tried ut ...

The back-end is not receiving the HTTP Get call, even though the URL is functional in the browser. The error message states that the JSON is

The backend function is functioning properly as both Postman and Swagger are able to call it without any issues. I decided to capture the URL string displayed in the error message and pasted it into a browser. Surprisingly, it successfully reached the bac ...

Using slashes to separate URL parameters in Codeigniter

For my project, I need to pass parameters in the URL like this: The goal is to change the URL structure to: I am currently generating URLs dynamically as shown below: <a href="<?php echo base_url()?>controllername/function?id=<?php echo $def ...

Ways to verify and incorporate https:// in a URL for a MEAN Stack application

When extracting the URL from API data, my code looks like this: <div class="row copy-text"> <a href="{{copy.Url}}" target="_blank" style="text-decoration: underline !important;">{{copy.Title}}</a> </div> I am interested in ve ...

The power of relative URLs in AJAX calls

Why does Javascript handle relative URLs differently than standard HTML? Consider the URL provided: http://en.wikipedia.org/wiki/Rome. Launch a Firebug console (or any other Javascript console) and type in the following: var x = new XMLHttpRequest(); x.op ...

What is the method for transmitting a URL API from an ASP.NET Core server to my Angular 2 single application?

Is there a way to securely share the url of the web api, which is hosted on a different server with a different domain, from my asp net core server to my client angular2? Currently, I am storing my settings in a typescript config file within my angular2 ap ...

employing a robotic tool to download a webpage under various file names

I am currently utilizing selenium to develop a robot that automates the process of opening and saving a webpage. Here is the code snippet: WebDriver driver = new FirefoxDriver(); driver.get("http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber= ...

What is the best method to create a URL slug similar to Quora's using the Yii framework?

After using Quora, I started to question how they create their unique identifiers known as slugs such as quora.com/topics-slugs, quora.com/questions-slug, or quora.com/usernames-slug. I am currently working on an application using the yii framework and I ...

Prioritizing Tabs in Selenium Web Scraping: Which Tab Takes Precedence?

Task at hand: capturing the URLs/titles from Code snippet for testing purposes (fetching 3 pages and printing, not saving): from selenium import webdriver from selenium.webdriver.common.keys import Keys from selenium.webdriver.support.ui import WebDriverW ...

Instructions on utilizing the CSSStyleSheet.insertRule() method for modifying a :root attribute

Is it possible to dynamically set the background color of the :root CSS property in an HTML file based on a hash present in the URL? The code provided does change the background color, but unfortunately, the hash value doesn't persist as users navigat ...

Optimal method for parsing URLs using ES6

There have been many remarkable inquiries regarding this topic, such as: how to parse a url. However, as time has gone by, the answers I come across are outdated. I am looking for a more modern and flexible method to parse URLs, without relying on regular ...

Incorporate a website link into a text string using Python

Is it possible to assign a URL to a specific portion of a string in Python? For example: StrVar = "This is my test string" I would like to link the word "test" to a URL such as "www.stackoverflow.com" Can this be done? If ...

Scouring the web of URLs for each request utilizing Scrapy

Currently, I am facing a challenge in storing the trail of URLs that my Spider visits whenever it accesses the target page. The issue lies in reading the starting URL and ending URL for each request. Despite going through the documentation thoroughly, I fi ...

Adding a question mark to the URL in Django: A complete guide

I have the following urlpatterns: urlpatterns = [ url(r'^tools(?:/tool_one=(?P<tool_one>w+))?/?$', views.ToolsViews.as_view(), name='tools'), ] This results in a URL like this: tools/tool_one=bags I want to add a question mark to the U ...

Learn how to properly convert a string into a valid URL using the Next JS router when pushing pages

I'm dealing with a string that looks like this: /dashboard/products/:id. My goal is to utilize Next Js's router to navigate to that URL and replace the placeholder :id with an actual id. Here's the code I've written: {products.map(prod ...

Is there a way to modify the id parameter in the URL using Angular 2's ActivatedRoute?

How can I modify a parameter in the URL without altering the overall address? https://i.stack.imgur.com/LOd4T.png This is the TypeScript code that I currently have: onRowClicked(event: any) { let currentIdPerson = event.data.IdPerson; } I am trying ...

Steps for launching a hyperlink in a browser on Vue Native

I'm having trouble finding information on how to properly use the Linking component in react-native. The resources available are limited, and I'm not sure if I am implementing it correctly... Below is what I have in my template: <nb-button :o ...

Concealing the presence of filename.php within the URL

Currently, I'm facing difficulties with hiding the URL. Specifically, I want to change it from http://example.com/products/product.php to either http://example.com/products/ or http://example.com/products/product/. I attempted to resolve this issue by usi ...

Updating a URL with the current date using Python: A step-by-step guide

I'm having an issue with my code that is meant to replace the today's date in a URL, but it ends up printing the today's date three times instead of just once. import re today = (date.today().strftime("%d_%m_%Y")) print(today) url = 'https://demo ...

What is the best way to perform a partial match query in Elasticsearch?

Can anyone provide me with a solution for extracting the word "google" from a link like http://drive.google.com? Currently, I am using the following search query: query: { bool : { must: { match: { text: 'google'} ...

Is there a way to send URL variables to express.js similar to how it's done in PHP?

Currently in the process of converting my PHP website to Express.js. There are numerous scripts on my frontend that generate links in the format page.php?id=10&something=anything. Is there a way in Express.js to capture variables from URLs structured ...

Exploring Angular: Utilizing URL Parameters for Multiple States

I am curious to know if it is achievable using angular 1.x. The requirement is to create a responsive application that works well on both mobile and desktop devices. Each page of the application should have a ui-view element that shows the regular content ...

Tips for updating a URL using data obtained from a JSON response

As I loop through an array from JSON, I extract all the necessary information. For example, if I have cards for blog posts that include the title, short description, published date, and URL. When clicking on a card, it redirects to a corresponding page ba ...

What is the safest way to convert a local file path to a file:// URL in Node.js?

In my node.js application, I am faced with the task of converting local file paths into file:// urls. After some research, I came across the File URI scheme on Wikipedia and I believe that there must be a solution out there or perhaps even an npm module t ...

Adding to a webpage's URL with PHP prior to rendering the content

Currently, I am investigating how to add a random query string at the end of a URL when someone visits my page for the first time. Let's say an individual goes to my website at www.example.com. If everything proceeds as planned, they will land on my index. ...

Basic Android Picture Parsing

I'm having trouble parsing image URLs and displaying the images in a ListView. I keep getting a ProtocolNotFound Exception/JSON Exception No value for null error. I believe I am close to converting the image URLs into bitmaps, but I seem to be missing ...

Looking for a regular expression to verify if the URL inputted is valid in TypeScript

After conducting thorough research, I discovered that none of the suggested URLs met my criteria, prompting me to raise a new query. Here are my specific requirements: * The URL may or may not include 'http' or 'https' * The URL can consist solely of an I ...

Angular: Enhancing URL links

Recently, I discovered a function in my code that allows me to cycle through different pictures and change the URL accordingly. The initial URL is obtained using angular routes, where the "domain" parameter consists of the domain.id and the domain.category ...

Setting a backgroundImage URL using props in React is a useful feature that allows for

Trying to create a React component that changes its background image based on the props received. Any suggestions on how to achieve this functionality? The props object includes a property called synmain, which is a string linking to an image "../image.p ...

Access a webpage whose URL has been dynamically assigned using JavaScript

I have a website that consists of a single page and features four tabs. Whenever a tab is clicked, it displays the corresponding content in a div while hiding the other three divs along with their respective content. To ensure a smooth user experience, I u ...

Why is it that the image is not showing up even though I have correctly input the full pathway into the database?

view image here Any issues with the path for the image? If so, how can a valid image path be written in a MySQL database using PHP? Please note that the image shown above contains the column for images with paths such as C:/wamp/www/phpT/images/products/m ...

What is the best way to include a string in an Ajax GET request as a query parameter without it being encoded?

I've encountered an issue while trying to pass a list of subject IDs as query params in an Ajax get-request. The API expects the subjectId param to be either a single number or a string of numbers separated by commas. I have made sure that what I am sendin ...

How to retrieve the filename from a URL using Node.js

In my Node.js script, I have the following type of link: 148414929_307508464041827_8013797938118488137_n.mp4.m4a?_nc_ht=scontent-mxp1-1.cdninstagram.com&_nc_ohc=_--i1eVUUXoAX9lJQ-u&ccb=7-4&oe=60835C8D&oh=61973532a48cb4fb62ac6711e7eba82f& ...

Regular valid URLs are the only thing that the PHP Regex in question matches

I need help finding a regex pattern that will only match valid URLs that are online. For example, it should match URLs like: exmaple.com http://exmaple.com https://exmaple.com www.exmaple.com http://www.example.com https://www.example.com It should al ...

Retrieving Browser URL using Node.js

Currently, I am trying to extract the browser URL from a user who has integrated my external JavaScript file into their website. The process involves them including the JS file, which triggers an Ajax call using jQuery to communicate with my Node server. ...

React.js reusable component fails to update when a dependency library used in useEffect() undergoes a change

One of the components I've created in Next.js is a custom routing link that appends the locale before the pathname when clicked and applies a custom style for the active link. Below is the code snippet for this component: "use client"; imp ...

What is the best way to eliminate the # symbol in angular 5 URLs?

Currently, I am working on a project in Angular 5 and I need to remove the hash symbol (#) from my URL. The current URL looks like this: http://localhost:4200/#/product/add. While it works fine after being published on my domain, I encounter a 404 error ...

How to use PHP code to decode Instagram URLs and return Null values

Can anyone help with an issue regarding json_decode from Instagram URL? When using the following URL , it returns Null in PHP. $newwul = "http://www.instagram.com/username/?__a=1"; $xo = connect($newwul); $xx = json_decode($xo,tru ...

What's the deal with Angular query parameters and parentheses?

My Angular application has a routing structure that includes a query parameter. Here is an example: const routes: Routes = [{ path: '', component: DefaultComponent }, { path: ':uname', component: ProductDisplayComponent }]; When I try to access th ...

Using the jQuery AJAX function to modify the URL query string

I currently find myself on a webpage Is there a way to add a URL query string without reloading the page? For example, when I click a button, can the URL change to using jQuery ajax functions? ...

Adjust the value of an option within a select input using URL parameters

With regards to this page: I am in the process of developing a script that can extract a parameter from the URL to dynamically modify the select option, thus changing which vehicle is showcased alongside the Honda on the chart. I experimented with the fo ...

The utilization of the $.ajax() function to retrieve data from a remote URL

My task involves reading this remote XML file: , in an HTML file using Ajax! This is the code I have written: <script type="text/javascript"> getReadXmlFile(); function getReadXmlFile(){ alert("Searching for file"); $.ajax({ typ ...

React component will be visible regardless of the URL provided

Currently, I am working through a tutorial using the react-router-dom React library. One issue I am facing is that my navigation header continues to display no matter what URL I enter after localhost:3000. For example, even if I type localhost:3000/dflkjf ...

How can I set a header to be automatically included in every "render" response in Node.js/Express?

One of the challenges I face involves implementing "controllers" in my code: app.get('/',function(req,res){ var stuff = { 'title': 'blah' }; res.render('mytemplate',stuff); }); In particular, I'm worki ...

What is the best way to extract the #jumper part from a URL using CodeIgniter?

Here is the URL: http://www.example.com/segment_one/segment_two/segment_three#jumper How can I extract the #jumper section from the current URL? ...

Forward the jsp to the servlet before navigating to the following page

Issue: After submitting the JSP form on Page1, it redirects to a server-side JSP page but appears as a blank page in the browser. Instead, I want it to redirect to Page2 which includes a list box that highlights the newly created item. Seeking help with t ...

Ways to extract a link from an image tag

$image = '<img src="http://some-img-link" alt="some-img-alt"/>'; $source = preg_match('/<img src="(.*?)">/', $image); echo $source; Can someone help me retrieve the src value from the img tag as well as possibly the alt value? ...

What is the best way to create user profiles using the URL domain.com/username rather than domain.com/profile.php?user=username?

Recently, I developed a website that features profiles for each member. The user data is stored in a MySQL database while their profile pictures are saved in a folder named "pictures" with the username as the filename. Each member's username is unique. O ...

URLs not being gathered by the web scraping tool

Currently involved in scraping data from this specific website to compile a database. Previously, I had functioning Python code available on GitHub that successfully accomplished this task. However, due to a major overhaul in the HTML structure of the site ...

Steps to create a personalized value for a column in a MySQL query

During the exam, I am dealing with 2 tables. 1) Post - and its columns : pid : uid : title : content : created date : ... 2) URL alias aid : sou_url : des_url : The purpose of the second table is to store URL aliases for all pages on my website. I have ...

What is the best way to modify part of a URL and refresh the page with the updated changes?

Good evening, everyone. This is my inaugural post on this platform, so I hope I am following the norms correctly. I have scoured various sources, including this site, in search of a solution to a problem I am facing, but I have not come across anything t ...

Is there a way to efficiently download a large number of images (70,000) from URLs while adhering to restrictions on simultaneous downloads

I'm feeling a bit lost here. I have this csv file containing two columns: name and picture URL. My goal is to bulk download the 70k images from the file and save them in a folder, renaming each image with the corresponding name from the first column. In ca ...