Is there any way to get nearest public IPs by entering zip code - ip

I have a landing page and I want to get the closest IP address to a zipcode whenever I type in the customer's zipcode.
Jornaya is integrated into the landing page which captures whenever customer lands on the page and once the form is submitted. And IP address will generated, and I want that IP to be closes to that zip code.
Can anyone help me in this regard as to what I have to do to get this done?

Related

To verify the email address on thank you page using cypress

I am trying to automate the following:
I want to verify the email address on a thank you page by writing cypress commands.
Also, how can I have this email I’d in a constant or variable so that I needed not every time hardcode it and this email address entered on question page, I want to verify it on the thank you page.

How to find emailID of user who visits URL received by user in mail

I am working on an asp.net project where user receives email from webserver.
User is given a url to visit.
Note: Obviously that url has a unqiue user identification pin
I want to know if this url is visited by same user who received mail or someone else. (In case someone tries to change unique pin and try access the web)
Is there anyway to achieve this?
Thanks.
You can't tell whether the visitor is the user or not. To the eyes of your application the one having the URL is the user. So if the PIN can be changed you'll have to encode a unique user identifier moreover the PIN in the URL sent for direct access.
You can also do some basic degree of fraud detection easily.
Using Request.UserHostAddress log the IP address of the first person clicking on the URL and collect his agent with Request.UserAgent
Then log each next visit in the same way.
If the second visit comes from the same IP and User-Agent then probably the user just revisited the email and clicked again.
Otherwise he probably forwarded the email to someone else or the email was stolen.
If you see lots of visits from different IPs and user agents then probably there has been a PIN sharing.

Prevent varnish caching for a specific widget / plugin?

I have a weather widget on our homepage that uses the users IP to display current local weather. The issue is that the first person to land on the homepage sees the correct weather but then all other users see the first users weather.
Obviously the homepage gets a lot of traffic so turning the cache off on the page is not an option.
What steps do i need to take to not cache just that widget/plugin on the homepage? Since it is a widget that might some day appear on other pages it would be great if the whole thing could be exempt but I don't even have a clue how to start?
As an additional note, the widget makes an api request to a 3rd party service with the IP address as one of the parameters.
Thanks in advance.
If the IP address of the user is included in the homepage as it is returned to the user, you will not be able cache the page without the side-effect you are having.
My suggestion would be to try and get that IP address info to the widget in a separate request. You would need to load the homepage first, without the users IP included, and them make a 2nd request from your Javascript (You could use Ajax/Websockets etc) that gets the ip address from the server, updates the HTML for the widget and makes it display the weather.
It's more work, and the exact implementation will depend on how the widget works.
Hopefully this sends you in the right direction :)

Generating an email with a QR code

I am trying to generate QR codes for each of my customers. Each QR code would create an email to me. I've researched and I am pretty sure that I understand how to best create emails with a specific subject and body filled in.
Create the mailto code/script/line that would create the email.
mailto:test#gmail.com?subject=Test%20Subject&body=This%20is%20a%20test.
Create a tinyurl out of the script, to create a more reliable QR code.
http://tinyurl.com/nry2xud
Make a QR code out of it with any standard website. I used http://www.mobile-barcodes.com/qr-code-generator.
This is all fine, but I want the QR codes to mask the sender's email address. I do not want to get an email from a personal email account that the customer has on their phone. I want to replace their email address with the company address that the specific customer works for.
Is this possible? Thank you for any help you can give.
By definition, mailto uses whatever mail client is configured in the user's browser, and sends from their own email address. (From the spec: "Originator fields like From ... when present in the URI, MUST be ignored.")
If you have a web server somewhere, a better solution would be to avoid mailto entirely. Instead, have the QR code direct the user to a page on your server. The server script for that page (written in, say, PHP) would send you the email. Then, it would also serve up a confirmation message to the user.

Detect email client or website

I am interested to detect the email client or website a new user of my site is redirected from. For instance, if he was redirected from Gmail.com (by clicking a link in one of his email there) I would like to track that.
If I need to manipulate the links leading to my website somehow I can do that.
I know there is a way to do that cause I have seen many sites and services doing it but I would like to find out how. I can track the user agent but this tells me nothing about the site or email client.
You must use QueryStrings for this purpose. For example the link that sends the user to your site must be like this www.yourwebsite.com/default.aspx?sender="googleMail"
You can get this using the code shown below when your default.aspx page loads
if(Request.QueryString["sender"]!=null)
{
string Sender=Request.QueryString["sender"].ToString();
}
You can set different Querystrings like
www.yourwebsite.com/default.aspx?sender="googleMail"
www.yourwebsite.com/default.aspx?sender="YahooMail"
www.yourwebsite.com/default.aspx?sender="googleAdsense"
There are methods to trace the users Browser, IP address etc. But to trace this you must adopt the above method.

Resources